零基础华为认证HCNA配置命令Word文件下载.docx
- 文档编号:22471558
- 上传时间:2023-02-04
- 格式:DOCX
- 页数:31
- 大小:23.03KB
零基础华为认证HCNA配置命令Word文件下载.docx
《零基础华为认证HCNA配置命令Word文件下载.docx》由会员分享,可在线阅读,更多相关《零基础华为认证HCNA配置命令Word文件下载.docx(31页珍藏版)》请在冰豆网上搜索。
[R1-Vlanif1]undoipaddress
删除特定地址
[R1-Vlanif1]undoipaddress192.168.8.25224sub
关闭端口
[R1-Vlanif1]shutdown
启用接口
[R1-Vlanif1]undoshutdown
登录路由器的提示语
[R1]headerlogininformation"
ThisisofficelRouter"
进去路由器的提示语
[R1]headershellinformation"
WelcometoHuaweirouterVRPlab"
配置Console口登录认证方式
[R1]user-interfaceconsole?
[R1]user-interfaceconsole0
[R1-ui-console0]authentication-modepassword
Pleaseconfiguretheloginpassword(maximumlength6):
huawei
重设密码
[R1-ui-console0]setauthenticationpasswordcipher91xueit
设置登录超时的时间
[R1-ui-console0]idle-timeout20
[R1-ui-console0]displaythis
设置用户级别为3
[R1-ui-console0]userprivilegelevel3
配置路由器允许telnet远程管理
[R1]user-interfacevty0?
[R1]user-interfacevty04
[R1-ui-vty0-4]authentication-modepassword
Pleaseconfiguretheloginpassword(maximumlength16):
51cto
[R1-ui-vty0-4]idle-timeout10
设置telnet用户级别为2
[R1-ui-vty0-4]userprivilegelevel2
查看连接过来的用户
[R1]displayusers
查看全部用户接口
[R1]displayuser-interface
命令分级
0级网络诊断命令pingtracerttelnet等
1级系统维护命令displaycurrent-configuration
2级配置命令sysnameR1
3级设计系统基本运行的命令文件系统FTP配置文件切换用户管理命令
连接到路由器的用户分级
0-15级
0级别用户执行0级别命令
1级别用户执行0、1级别命令
2级别用户执行0、1、2级别命令
3-15级别用户执行0、1、2、3级别的命令
通过console口用户级别是3级
通过telnet接口用户级别是0级
恢复telnet默认用户级别
[R11-ui-vty0-4]undouserprivilegelevel
使用用户名和密码验证用户AAA身份验证
AAA是验证、授权和记账(Authentication、Authorization、Accounting)三个英文单词
han用户级别1
admin用户级别3
创建用户的命令
[R11]aaa
[R11-aaa]local-useradminpasswordcipherprivilegelevel3
[R11-aaa]local-useradminservice-typetelnet
创建一个用户级别是1的用户
[R11-aaa]local-userhanpasswordcipher
[R11-aaa]local-userhanprivilegelevel1
[R11-aaa]local-userhanservice-typetelnet
创建一个用户允许console连接
[R11-aaa]local-useradmin1passwordcipher91xueit@comprivilegelevel3
[R11-aaa]local-useradminservice-typeterminal
显示创建的用户
[R11-aaa]displaylocal-user
显示aaa的配置
[R11-aaa]displaythis
更改telnet接口身份验证模式为aaa
[R11]user-interfacevty04
[R11-ui-vty0-4]authentication-modeaaa
设置
文件管理
列出当前目录中的文件和文件夹
RA>
dir
创建文件夹
dirflash:
/backup/
拷贝文件到backup目录
copyvrpcfg.zipflash:
/backup/vrpcfgbackup.zip
将vrp1.zip移动到backup目录
movevrp1.zipflash:
/backup/vrp1.zip
切换到backup目录
cdbackup/
查看所在的目录
pwd
flash:
/backup
使用move在同一个目录下相当于重命名
movevrp1.zipvrp2.zip
重命名的命令
renamevrp2.zipvrp3.zip
删除文件,实质上放到回收站
deletevrp2.zip
还可以加参数看到删除的文件,带中括号的就是删除的文件
dir/all
Directoryofflash:
/backup/
IdxAttrSize(Byte)DateTime(LMT)FileName
0-rw-787Jan09201823:
01:
21vrpcfgbackup.zip
1-rw-783Jan09201823:
14:
32[vrp2.zip]
恢复删除的文件
undeletevrp2.zip
彻底删除且不带提示不能恢复了
delete/unreserved/forcevrp2.zip
清空回收站
resetrecycle-bin
把flash中的文件备份到计算机TFTP服务
UDP69端口不可靠传输
把flash中的文件上传到TFTP
tftp192.168.80.1putflash:
/vrpcfg.zipvrpcfg.zip
把TFTP服务器上的文件下载到flash的backup目录
tftp192.168.80.1getvrpcfg2.zipflash:
/backup/vrpcfg2.zip
把flash中的文件拷贝到FTP
TCP的21端口
支持身份验证可靠传输TCP
ftp192.168.80.1
User(192.168.80.1:
(none)):
hanlg
从FTP下载
[RA-ftp]getworklog.txtflash:
/backup/worklog2.txt
上传到FTP
[RA-ftp]putvrpcfg.zipvrpcfg.zip
设置系统启动文件
startupsystem-softwaredivicesoft.cc
指定保存配置的文件
startupsaved-configurationvrpcfg1.zip
查看下次启动使用的系统文件和配置文件以及当前使用的系统文件和配置文件
displaystartup
重启路由器
reboot
实验1:
静态路由
AR1>
displayiprouting-table
[AR2]iproute-static192.168.1.024172.16.1.2
跟踪数据包路径
tracert192.168.1.2
显示全部路由
[AR2]displayiprouting-table
只显示静态路由
[AR2]displayiprouting-tableprotocolstatic
添加路由下一跳可以写到达目标网络的沿途中的地址
删除路由
[AR1]undoiproute-static192.168.1.024
[AR1]undoiproute-static192.168.1.024172.16.1.1
[AR1]iproute-static192.168.1.024172.16.1.2
点到点链路静态路由下一跳可以写出口
AR1]iproute-static192.168.1.024Serial2/0/0
路由器上两张表
路由表和转发表
显示转发表
[AR1]displayfib
添加到某个主机的静态路由
[AR1]iproute-static192.168.1.332Serial2/0/0
网络规划和路由汇总
CIDR可以汇总2个4个8个连续的子网
全球最大的网段
0.0.0.00.0.0.0
0.0.0.0/0
默认路由
[R1]iproute-static0.0.0.00.0.0.010.0.0.2
[R1]iproute-static0.0.0.0010.0.0.2
添加静态路由
[AR1]iproute-static172.16.1.024172.16.0.2
[AR1]iproute-static172.16.1.0255.255.255.0172.16.0.2
[AR1]displayiprouting-table
[AR1]displayiprouting-tableprotocolstatic
删除静态路由
[AR1]undoiproute-static172.16.1.024
静态路由缺点
网络中增加网段删除网段修改网段不会自动更新路由
配置RIP协议
[AR1]rip?
[AR1]rip1
[AR1-rip-1]network192.168.0.0
[AR1-rip-1]network10.0.0.0
显示RIP协议学到的路由
displayiprouting-tableprotocolrip
AR4>
displayrip1route
显示运行RIP协议的接口
displayrip1interface
查看RIP协议活动
terminalmonitor
terminaldebugging
显示所有接口发送和接收的RIP包
debuggingrip1packet
只显示G0/0/0接口发送和接收的RIP包
debuggingrip1packetGigabitEthernet0/0/0
关闭所有诊断输出
undodebuggingall
创建不连续子网实验环境
删除配置文件
deletevrpcfg.zip
重启路由
n
y
[Huawei]sysnameAR1
[AR1]vlan2
[AR1-vlan2]quit
[AR1]port-groupvlan2ports
[AR1-port-group-vlan2ports]group-memberEthernet0/0/4toEthernet0/0/7
[AR1-port-group-vlan2ports]portlink-typeaccess
[AR1-port-group-vlan2ports]portdefaultvlan2
[AR1]interfaceVlanif2
[AR1-Vlanif2]ipaddress192.168.10.6526
[AR1-GigabitEthernet0/0/0]ipaddress172.16.0.130
[AR1]rip
[AR1-rip-1]version2
[AR1-rip-1]network192.168.10.0
[AR1-rip-1]network172.16.0.0
默认时在有类网络的边界自动汇总,但可以关闭汇总。
undosummary关闭汇总。
如果接口启用水平分割、毒性发转,则不进行汇总,除非使用“summaryalways”命令。
[AR1-GigabitEthernet0/0/0]undoripsplit-horizon
关闭自动汇总支持不连续子网
[AR1-rip-1]undosummary
人工汇总
[AR1-GigabitEthernet0/0/0]ripsummary-address192.168.10.0255.255.255.128
OSPF
显示邻居
[R1]displayospfpeer
查看链路状态数据库
displayospflsdb
查看链路状态数据库详细信息
displayospflsdbrouter
查看路由表
displayiprouting-table
查看运行OSPF协议的接口
displayospfinterface
显示OSPF学到的路由
displayospf1routing
displayiprouting-tableprotocolospf
启用RIP协议
显示RIP协议配置
[AR1-rip-1]displaythis
[V200R003C00]
#
rip1
network192.168.0.0
network10.0.0.0
return
查看RIP协议学到的路由
验证RIP协议健壮性
显示RIP协议数据库
displayrip1database
---------------------------------------------------
AdvertisementState:
[A]-Advertised
[I]-NotAdvertised/Withdraw
10.0.0.0/8,cost0,ClassfulSumm
10.0.0.0/8,cost1,[A],nexthop10.0.2.1
10.0.1.0/24,cost1,[A],nexthop10.0.2.1
10.0.2.0/24,cost0,[A],Rip-interface
10.0.3.0/24,cost1,[A],nexthop10.0.2.1
10.0.4.0/24,cost2,[A],nexthop10.0.2.1
10.0.5.0/24,cost3,[A],nexthop10.0.2.1
192.168.0.0/24,cost3,ClassfulSumm
192.168.0.0/24,cost3,[A],nexthop10.0.2.1
192.168.1.0/24,cost0,ClassfulSumm
192.168.1.0/24,cost0,[A],Rip-interface
显示RIP1的配置
displayrip1
如果接口启用水平分割、毒性发转,则不进行汇总,除非使用[AR1-rip-1]summaryalways命令
配置RIPv2简单验证
[AR3-GigabitEthernet0/0/0]ripauthentication-modesimplehuawei
RouterID配置
全局配置
[R1]displayrouteid
更改全局routerID
[R1]routerid2.2.2.1
使之生效
resetospfprocess
配置OSPF协议指定的routerid优先被使用,如果配置OSPF没有指定routerid使用全局的routerID
Network
可以跟接口所在网段
[R1-ospf-1-area-0.0.0.1]network172.16.0.160.0.0.3
接口的地址
[R1-ospf-1-area-0.0.0.0]network172.16.0.170.0.0.0
如果接口在同一个区域area,并且能够合并
[R1-ospf-1-area-0.0.0.1]network172.16.0.00.0.255.255
配置被动接口
[R1]ospf1
[R1-ospf-1]silent-interfaceVlanif1
[R1-ospf-1]undosilent-interfaceVlanif1
如果被动接口多,可以先将所有接口设置成被动接口
[R1-ospf-1]silent-interfaceall
在开放特定端口
[R1-ospf-1]undosilent-interfaceSerial2/0/0
设置以太网接口Hello报发送周期Timer时间
[R1-Vlanif1]ospftimerhello20
[R1-Vlanif1]ospftimerdead80
displayospfinterfaceVlanif1
更改路由器接口的默认开销
默认开销以太网是1广域网是48
[R1]interfaceSerial2/0/0
[R1-Serial2/0/0]ospfcost500
指定接口DR优先级
[R3-GigabitEthernet0/0/0]ospfdr-priority100
在区域边界路由器对某区域进行路由汇总
[R3-ospf-1-area-0.0.0.0]abr-summary192.168.0.0255.255.255.0cost10
R3>
resetospfprocess
可以将静态路由引入到动态路由
将RIP引入到OSPF
将
- 配套讲稿:
如PPT文件的首页显示word图标,表示该PPT已包含配套word讲稿。双击word图标可打开word文档。
- 特殊限制:
部分文档作品中含有的国旗、国徽等图片,仅作为作品整体效果示例展示,禁止商用。设计者仅对作品中独创性部分享有著作权。
- 关 键 词:
- 基础 华为 认证 HCNA 配置 命令
![提示](https://static.bdocx.com/images/bang_tan.gif)