- 相關(guān)推薦
H3C路由器基本配置命令
H3C路由器基本配置要怎么設(shè)置,下面yjbys小編為大家分享的是路由器的基本配置命令,希望對同學(xué)們學(xué)習(xí)H3C路由器配置的基礎(chǔ)知識有幫助!
H3C路由器基本配置命令
[Quidway]displayversion 顯示版本信息
[Quidway]displaycurrent-configuration 顯示當(dāng)前配置
[Quidway]displayinterfaces 顯示接口信息
[Quidway]displayip route 顯示路由信息
[Quidway]sysnameaabbcc 更改主機(jī)名
[Quidway]superpasswrod 123456 設(shè)置口令
[Quidway]interfaceserial0 進(jìn)入接口
[Quidway-serial0]ipaddress
[Quidway-serial0]undoshutdown 激活端口
[Quidway]link-protocolhdlc 綁定hdlc協(xié)議
[Quidway]user-interfacevty 0 4
[Quidway-ui-vty0-4]authentication-modepassword
[Quidway-ui-vty0-4]setauthentication-mode password simple 222
[Quidway-ui-vty0-4]userprivilege level 3
[Quidway-ui-vty0-4]quit
[Quidway]debugginghdlc all serial0 顯示所有信息
[Quidway]debugginghdlc event serial0 調(diào)試事件信息
[Quidway]debugginghdlc packet serial0 顯示包的信息
靜態(tài)路由:
[Quidway]iproute-static
例如:
[Quidway]iproute-static 129.1.0.0 16 10.0.0.2
[Quidway]iproute-static 129.1.0.0 255.255.0.0 10.0.0.2
[Quidway]iproute-static 129.1.0.0 16 Serial 2
[Quidway]iproute-static 0.0.0.0 0.0.0.0 10.0.0.2
動態(tài)路由:
[Quidway]rip
[Quidway]rip work
[Quidway]rip input
[Quidway]ripoutput
[Quidway-rip]network1.0.0.0 ;可以all
[Quidway-rip]network2.0.0.0
[Quidway-rip]peerip-address
[Quidway-rip]summary
[Quidway]ripversion 1
[Quidway]ripversion 2 multicast
[Quidway-Ethernet0]ripsplit-horizon ;水平分隔
[Quidway]router idA.B.C.D 配置路由器的ID
[Quidway]ospfenable 啟動OSPF協(xié)議
[Quidway-ospf]import-routedirect 引入直聯(lián)路由
[Quidway-Serial0]ospfenable area
標(biāo)準(zhǔn)訪問列表命令格式如下:
acl
rule[normal|special]{permit|deny} [source source-addr source-wildcard|any]
例:
[Quidway]acl 10
[Quidway-acl-10]rulenormal permit source 10.0.0.0 0.0.0.255
[Quidway-acl-10]rulenormal deny source any
擴(kuò)展訪問控制列表配置命令
配置TCP/UDP協(xié)議的擴(kuò)展訪問列表:
rule{normal|special}{permit|deny}{tcp|udp}source {
[operate]
配置ICMP協(xié)議的擴(kuò)展訪問列表:
rule{normal|special}{permit|deny}icmp source {
[icmp-code][logging]
擴(kuò)展訪問控制列表操作符的含義
equalportnumber 等于
greater-thanportnumber 大于
less-thanportnumber 小于
not-equalportnumber 不等
range portnumber1portnumber2 區(qū)間
擴(kuò)展訪問控制列表舉例
[Quidway]acl 101
[Quidway-acl-101]ruledeny souce any destination any
[Quidway-acl-101]rulepermit icmp source any destination any icmp-type echo
[Quidway-acl-101]rulepermit icmp source any destination any icmp-type echo-reply
[Quidway]acl 102
[Quidway-acl-102]rulepermit ip source 10.0.0.1 0.0.0.0 destination 202.0.0.1 0.0.0.0
[Quidway-acl-102]ruledeny ip source any destination any
[Quidway]acl 103
[Quidway-acl-103]rulepermit tcp source any destination 10.0.0.1 0.0.0.0 destination-port equal ftp
[Quidway-acl-103]rulepermit tcp source any destination 10.0.0.2 0.0.0.0 destination-port equal www
[Quidway]firewallenable
[Quidway]firewalldefault permit|deny
[Quidway]int e0
[Quidway-Ethernet0]firewallpacket-filter 101 inbound|outbound
地址轉(zhuǎn)換配置舉例
[Quidway]firewallenable
[Quidway]firewalldefault permit
[Quidway]acl 101
[Quidway-acl-101]ruledeny ip source any destination any
[Quidway-acl-101]rulepermit ip source 129.38.1.4 0 destination any
[Quidway-acl-101]rulepermit ip source 129.38.1.1 0 destination any
[Quidway-acl-101]rulepermit ip source 129.38.1.2 0 destination any
[Quidway-acl-101]rulepermit ip source 129.38.1.3 0 destination any
[Quidway]acl 102
[Quidway-acl-102]rulepermit tcp source 202.39.2.3 0 destination 202.38.160.1 0
[Quidway-acl-102]rulepermit tcp source any destination 202.38.160.1 0 destination-port great-than
1024
[Quidway-Ethernet0]firewallpacket-filter 101 inbound
[Quidway-Serial0]firewallpacket-filter 102 inbound
[Quidway]nataddress-group 202.38.160.101 202.38.160.103 pool1
[Quidway]acl 1
[Quidway-acl-1]rulepermit source 10.110.10.0 0.0.0.255
[Quidway-acl-1]ruledeny source any
[Quidway-acl-1]intserial 0
[Quidway-Serial0]natoutbound 1 address-group pool1
[Quidway-Serial0]natserver global 202.38.160.101 inside 10.110.10.1 ftp tcp
[Quidway-Serial0]natserver global 202.38.160.102 inside 10.110.10.2 www tcp
[Quidway-Serial0]natserver global 202.38.160.102 8080 inside 10.110.10.3 www tcp
[Quidway-Serial0]natserver global 202.38.160.103 inside 10.110.10.4 smtp udp
PPP驗證:
主驗方:pap|chap
[Quidway]local-useru2 password {simple|cipher} aaa
[Quidway]interfaceserial 0
[Quidway-serial0]pppauthentication-mode {pap|chap}
[Quidway-serial0]pppchap user u1 //pap時,不用此句
pap被驗方:
[Quidway]interfaceserial 0
[Quidway-serial0]ppppap local-user u2 password {simple|cipher} aaa
chap被驗方:
[Quidway]interfaceserial 0
[Quidway-serial0]pppchap user u1
[Quidway-serial0]local-useru2 password {simple|cipher} aaa
【H3C路由器基本配置命令】相關(guān)文章:
H3C路由器配置命令07-19
華為路由器配置命令04-10
Cisco路由器配置命令大全06-12
Cisco路由器安全配置命令03-04
h3c路由器配置01-22
思科與H3C配置命令對比03-03
華為路由器IP性能配置命令03-03
H3C常用查詢配置命令大全01-22