搜档网
当前位置:搜档网 › 华为路由器简单配置命令

华为路由器简单配置命令

Telnet使用:
routerA# terminal monitor <——可以传回在远端主机执行Debug命令的结果——>

routerA# telnet IP-Address [ Router-Name ] <——Telnet到指定的地址或名字的主机——>

routerB# [ exit | logout ] <——退出Telnet——>

routerB# ++<6>再按 <——挂起Telnet——>

routerA# show sessions <——显示当前所有Telnet的信息,包括Connect-Number ——>

routerA# Connect-Number <——返回指定的Telnet连接——>

routerA# disconnect IP-Address [ Router-Name ] <——断开指定地址或名字的主机的连接——>

routerA# show user <——显示Telnet到本机的连接信息——>

routerA# clear line [ 0 | 1 | 2 | 3 | 4 ] <——断开指定Telnet到本机的连接——>

禁止任何Telnet到本机:

router(config)# line vty 0 4

router(config-line)# access-class ACL-Number

router(config)# ^z

设置主机名:

router(config)# hostname Set-Hostname

router(config)# ^z

router(config)# ^z

设置用户模式密码:

router(config)# line console 0

router(config-line)# login

router(config-line)# password Set-Password

router(config-line)# ^z

设置Telnet密码:

router(config)# line vty 0 4

router(config-line)# login

router(config-line)# password Set-Password

router(config-line)# ^z

设置特权模式密码:

router(config)# enable password Set-Password <——不加密的密码,明码——>

router(config)# enable secret Set-Password <——经过加密的密码——>

router(config)# ^z

给所有密码加密:

router(config)# service password-ancryption Set-Password-Here

router(config)# no service password-ancryption <——取消加密——>

router(config)# ^z

设置登录Banner:

router(config)# banner motd 分隔符 Set-Banner-InFORMation-Here 分隔符 <——前后分隔符一定要一致——>

设置接口的描述信息:

router(config-if)# description Set-Port-InFORMation-Here

router(config)# ^z

CDP的控制:

router(config-if)# cdp enable <——在指定端口启用CDP,缺省——>

router(config-if)# no cdp enable <——在指定端口关闭CDP——>

router(config)# cdp run <——使所有端口启用CDP——>

router(config)# no cdp run <——使所有端口关闭CDP——>

Ping的使用:

router# ping IP-Address

router# ping <——扩展Ping命令——>

Protocol [ip]:[ Protocol-Type ] <——选择协议类型——>

Target IP address:IP-Address <——输入测试地址——>

Repeat cou

nt [5]: <——选择发送的ICMP包数量——>

Datagram size [100]: <——选择每个包的大小——>

Timeout in seconds [2]: <——设置每个包的超时时间——>

Extended commands [n]:y <——使用扩展Ping命令——>

Sweep range of sizes [n]:

 Tracke的使用:

router# trace IP-Address [ Host-Name ]

为Cisco 4000路由器指定媒体类型:

router(config-if)# media-type 10baset <——使AUI(默认)失效,改为使用RJ-45——>

router(config-if)# ^z

更改路由器启动顺序:

router(config)# boot system flash IOS-FileName

router(config)# boot system tftp IOS-FileName TFTP-IP-Address

router(config)# boot system rom

router(config)# ^z

修改寄存器数值:

router(config)# config-register value <——Cisco出厂默认value=0x2102,value范围:0x2100(进入ROM监视器),0x2101(使系统从ROM启动),0x2102~0x210F(使系统从NVRAM启动)。0x1=0x2101,从最小位开始改变——>

在ROM监视器中更改寄存器数值:

> o/r value

路由器密码的恢复:

冷关机,然后再开机并在60秒内按< Ctrl>+进入ROM监视器模式

> o/r 0x2142 <--25xx型路由器--> 或 > confreg 0x2142 <--16xx型路由器-->

router> I

router> n

router> enable

router# copy startup-config running-config

router# configure terminal

router(config)# enable secret New-Password

router(config)# config-register 0x2102

router(config)# ^z

router# copy running-config startup-config

router# reload

配置名称-主机入口:

router(config)# ip host Set-Name [ TCP-Port-Number ] IP-Address [ IP-Address 2 ].。。

router(config)# ^z

定义DNS主机:

router(config)# ip name-server Server-Address [ Server-Address 2 ].。。

router(config)# ^z

禁用DNS:

router(config)# no ip domain-lookup

router(config)# ^z配置水平分割:

router(config-if)# ip split-horizon

router(config-if)# no ip split-horizon

router(config-if)# ^z

配置静态路由:

router(config)# ip route IP-Address Subnet-Mask [ Next-Hop-Address | Local-Out-Port ] [Distace ]

<——Distance范围:1~255,相当于优先权,越小越好。RIP=120;DSPF=110;IGRP=100;EIGRP=90——>

router(config)# ^z

配置缺省路由:

router(config)# ip defoult-network IP-Address <——动态缺省路由——>

router(config)# ip route 0.0.0.0 0.0.0.0 [ Next-Hop-Address | Local-Out-Port ] [Distace ] <——静态缺省路由——>

router(config)# ^z

其它命令:

 

 router# show version

router# show running-config

router# show startup-config

router# show flash

router# show interface [ Type Port ]

router# show buffers

router# show protocol

router# show mem

router# show stacks

router# show processes

router# show cdp entry [ Device-Name ] <——显示指定邻居三层信息——>

router# show cdp neighbors

router# show cdp neighbors detail <——显示所有邻居三层信息->

router# show ip router

router# show ipx router

router# show host

router# show ip protocol

router# show ip interface Type Port

router# show ipx interface Type Port

router# show ipx servers

router# show ipx traffic

router# show access-lists [ ACL-Number ]

router# show isdn status

router# show dialer <——查看ISDN拨号信息——>

router# show isdn active

router# show frame-relay pvc

router# show frame-relay map

router# show frame-relay lmi

router# erase startup-config

router# reload

router# setup

router# copy running-config startup-config

router# copy startup-config running-config

router# copy tftp running-config

router# copy running-config tftp

router# debug ipx routing activity

router# debug ipx sap

router# debug isdn q921

router# debug isdn q931

router# debug dialer

router# debug ip rip

router# clear interface bri
一、普通用户模式

(1)help 系统帮助简述;

(2)telnet 远程登录功能;

(3)language 语言模式切换;

(4)ping 检查网络主机连接及主机是否可达;

(5)show 显示系统运行信息;

(6)tracert 跟踪到目的地经过了哪些路由器 ;

(7)exit 退出配置。

二、特权用户模式

(1)enable 转入特权用户模式;

(2)telnet 远程登录功能;

(3)clear 清除各项统计信息;

(4)ping 检查网络主机连接及主机是否可达;

(5)no 关闭调试开关

(6)erase 擦除FLASH中的配置;

(7)first-config 设置或清除初次配置标志;

(8)clock 管理系统时钟;

(9)debug 开启调试开关;

(10)disable 返回普通用户模式;

(11)download 下载新版本软件和配置文件;

(12)exec-timeout 打开EXEC超时退出开关;

(13)monitor 打开用户屏幕调试信息输出开关;

(14)setup 配置路由器参数;

(15)show 显示系统运行信息;

(16)tracert 跟踪到目的地经过了哪些路由器;

(17)unmonitor 关闭用户屏幕调试信息输出开关;

(18)write 将当前配置参数保存至FLASH MEM中;

(19)reboot 路由器重启;

(20)exit 退出配置。

 

 三、全局配置模式

(1)configure 进入全局配置模式;

(2)arp 设置静态ARP人口;

(3)aaa-enable 使能配置AAA(认证,授权和计费);

(4)access-list 配置标准访问表;

(5)ip 全局IP配置命令子集;

(6)ipx 全局IPX配置命令子集;

(7)chat-script 生成一个用在modem上的执行脚本;

(8)custom-list 创建定制队列列表;

(9)dialer-list 创建dialer-list;

(10)dram-wait 设置DRAM等待状态;

(11)enable 修改ENABLE口令;

(12)firewall 配置防火墙状态;

(13)flow-interval 设置流量控制时间间隔;

(14)frame-relay 帧中继全局配置命令集;

(15)ftp-server FTP 服务器;

(16)help 系统帮助命令简述;

(17)host 添加主机名称和其IP地址;

(18)vpdn 设置VPDN;

(19)vpdn-group 设置VPDN组;

(20)hostname 修改主机名;

(21)ifquelen 更改接口队列长度;

(22)interface 选择配置接口;

(23)loghost 设置日志主机IP地址;

(24)logic-channel 配置逻辑通道;

(25)login 启动EXEC登录验证;

(26)modem-timeout 设置modem 超时时间;

(27)multilink 配置multilink 用户使用的接口;

(28)multilink-user 配置multilink 用户使用的接口;

(29)natserver 设置FTP,TELNET,WWW服务的IP地址;

(30)no 关闭某些参数开关;

(31)priority-list 创建优先级队列列表;

(32)router 启动路由处理;

(33)settr 设置时间范围;

(34)snmp-server 修改SNMP参数;

(35)tcp 配置全局TCP参数;

(36)timerange 启动或关闭时间区域;

(37)user 为PPP验证向系统中加入用户;

(38)exit 退出全局配置模式。

综上所述,华为路由器的配置命令就是这些,希望对广大网管们有所帮助。

原文出自【比特网】,转载请保留原文链接:https://www.sodocs.net/doc/a44035636.html,/121/12304121.shtml

相关主题