华为RIP实验

 

 

 

华为RIP实验

 

华为RIP实验

-------------------------AR1 配置-------------------------------------------------------------

<Huawei>system-view       --进入特权模式

system-view

Enter system view, return user view with Ctrl+Z.

[Huawei]

[Huawei]sysname r1        --命名为r1

sysname r1

[r1]int loopback1          --定义环回口loopback1

int loopback1

[r1-LoopBack1]

[r1-LoopBack1]ip add 11.1.1.1 24      --设置环回口IP地址  11.1.1.1.

ip add 11.1.1.1 24

[r1-LoopBack1]

[r1-LoopBack1]quit

Quit

[r1]int s1/0/0           --定义s1/0/0 端口

int s1/0/0

[r1-Serial1/0/0]

[r1-Serial1/0/0]ip add 12.0.0.1 24--设置s1/0/0端口IP地址为12.0.0.1 子网掩码 255.255.255.0

ip add 12.0.0.1 24

[r1-Serial1/0/0]

[r1-Serial1/0/0]undo shutdown

undo shutdown

Info: Interface Serial1/0/0 is not shutdown.

[r1-Serial1/0/0]

[r1-Serial1/0/0]quit          --退出

quit

[r1]

[r1]rip 1      --定义rip进程为1

rip 1

[r1-rip-1]

[r1-rip-1]version 2       --定义rip 版本2

version 2

[r1-rip-1]undo summary   --关闭自动汇总

undo summary

[r1-rip-1]

[r1-rip-1]network 12.0.0.0   ----主类宣告12.0.0.0网段

network 12.0.0.0

[r1-rip-1]

[r1-rip-1]

[r1-rip-1]network 11.0.0.0   ----主类宣告11.0.0.0网段

network 11.0.0.0

[r1-rip-1]

[r1-rip-1]quit   --退出

quit

[r1]

 

----------------------------------------------------------配置AR2-----------------

<Huawei>system-view              --进入特权模式

system-view

Enter system view, return user view with Ctrl+Z.

[Huawei]

[Huawei]sysname r2      --命名为r2

sysname r2

[r2]

[r2]int loopback2       --定义环回口loopback2

int loopback2

[r2-LoopBack2]

[r2-LoopBack2]ip add 22.1.1.1 24   --设置环回口loopback2 IP地址为22.1.1.1

ip add 22.1.1.1 24

[r2-LoopBack2]

[r2-LoopBack2]

[r2-LoopBack2]

Dec 15 2019 08:25:19-08:00 r2 %%01PPP/4/PHYSICALDOWN(l)[0]:On the interface Serial1/0/1, PPP link was closed because the status of the physical layer was Down.

[r2-LoopBack2]

Dec 15 2019 08:25:19-08:00 r2 %%01IFNET/4/LINK_STATE(l)[1]:The line protocol PPP on the interface Serial1/0/1 has entered the DOWN state.

[r2-LoopBack2]

Dec 15 2019 08:25:19-08:00 r2 %%01IFPDT/4/IF_STATE(l)[2]:Interface Serial1/0/1 has turned into DOWN state.

[r2-LoopBack2]

Dec 15 2019 08:26:35-08:00 r2 %%01IFPDT/4/IF_STATE(l)[3]:Interface Serial1/0/1 has turned into UP state.

[r2-LoopBack2]

Dec 15 2019 08:26:37-08:00 r2 %%01IFNET/4/LINK_STATE(l)[4]:The line protocol PPP on the interface Serial1/0/1 has entered the UP state.

[r2-LoopBack2]

 

  Please check whether system data has been changed, and save data in time

 

  Configuration console time out, please press any key to log on

 

 

[r2]

[r2]rip 1          --限定路由传递区域1

rip 1

[r2-rip-1]

[r2-rip-1]version 2       rip版本号为2

version 2

[r2-rip-1]

[r2-rip-1]network 12.0.0.0      ---主类宣告网段12.0.0.0

network 12.0.0.0

[r2-rip-1]

[r2-rip-1]network 22.0.0.0    --主类宣告网段 22.0.0.0

network 22.0.0.0

[r2-rip-1]

[r2-rip-1]network 23.0.0.0     --主类宣告网段 23.0.0.0

network 23.0.0.0

[r2-rip-1]

[r2-rip-1]undo summary    --关闭自动汇总

undo summary

[r2-rip-1]

[r2-rip-1]quit

quit

[r2]

[r2]

 

  Please check whether system data has been changed, and save data in time

 

  Configuration console time out, please press any key to log on

 

<r2>system-view

system-view

Enter system view, return user view with Ctrl+Z.

[r2]

[r2]int s1/0/0           定义s1/0/0/0 端口

int s1/0/0

[r2-Serial1/0/0]

[r2-Serial1/0/0]ip add 12.0.0.2 24   --设置IP地址12.0.0.2 子网掩码255.255.255.0

ip add 12.0.0.2 24

[r2-Serial1/0/0]

[r2-Serial1/0/0]

Dec 15 2019 08:37:31-08:00 r2 %%01IFNET/4/LINK_STATE(l)[0]:The line protocol PPP IPCP on the interface Serial1/0/0 has entered the UP state.

[r2-Serial1/0/0]int s1/0/1   --定义s1/0/1 端口IP地址23.0.0.1

int s1/0/1

[r2-Serial1/0/1]

[r2-Serial1/0/1]ip add 23.0.0.1 24

ip add 23.0.0.1 24

[r2-Serial1/0/1]

[r2-Serial1/0/1]undo shutdown

undo shutdown

Info: Interface Serial1/0/1 is not shutdown.

[r2-Serial1/0/1]

[r2-Serial1/0/1]quit

quit

[r2]

[r2]

[r2]quit

quit

 

 

-------------------------配置AR3-----------------------------

<Huawei>system-view       --进入特权模式

system-view

Enter system view, return user view with Ctrl+Z.

[Huawei]

[Huawei]sysname r3          --命名为r3

sysname r3

[r3]

[r3]int loopback3           --定义环回口loopback3

int loopback3

[r3-LoopBack3]

[r3-LoopBack3]ip add 33.1.1.1 24    ---设置环回口3IP地址为33.1.1.1

ip add 33.1.1.1 24

[r3-LoopBack3]

[r3-LoopBack3]quit

quit

[r3]

[r3]int s1/0/0      --定义s1/0/0 端口

int s1/0/0

[r3-Serial1/0/0]

[r3-Serial1/0/0]ip add 23.0.0.2 24   --设置s1/0/0 端口IP为23.0.0.2

ip add 23.0.0.2 24

[r3-Serial1/0/0]

[r3-Serial1/0/0]

Dec 15 2019 08:40:03-08:00 r3 %%01IFNET/4/LINK_STATE(l)[1]:The line protocol PPP IPCP on the interface Serial1/0/0 has entered the UP state.

[r3-Serial1/0/0]undo shutdown

undo shutdown

Info: Interface Serial1/0/0 is not shutdown.

[r3-Serial1/0/0]

[r3-Serial1/0/0]quit

quit

[r3]

[r3]rip 1         --rip进程1

rip 1

[r3-rip-1]

[r3-rip-1]version 2   --rip版本号为2

version 2

[r3-rip-1]

[r3-rip-1]network 33.0.0.0    --主类宣告网段33.0.0.0

network 33.0.0.0

[r3-rip-1]

[r3-rip-1]network 23.0.0.0  --主类宣告23.0.0.0 网段

network 23.0.0.0

[r3-rip-1]

[r3-rip-1]undo summary    --关闭自动汇总

undo summary

[r3-rip-1]

[r3-rip-1]quit   --退出

quit

[r3]

-------------------------------------------------------------------------在r1 查看路由表信息---------

[r1]

Dec 15 2019 08:37:30-08:00 r1 %%01IFNET/4/LINK_STATE(l)[0]:The line protocol PPP IPCP on the interface Serial1/0/0 has entered the UP state.

[r1]display ip routing

display ip routing

Route Flags: R - relay, D - download to fib

------------------------------------------------------------------------------

Routing Tables: Public

         Destinations : 14       Routes : 14       

 

Destination/Mask    Proto   Pre  Cost      Flags NextHop         Interface

 

       11.1.1.0/24  Direct  0    0           D   11.1.1.1        LoopBack1

       11.1.1.1/32  Direct  0    0           D   127.0.0.1       LoopBack1

     11.1.1.255/32  Direct  0    0           D   127.0.0.1       LoopBack1

       12.0.0.0/24  Direct  0    0           D   12.0.0.1        Serial1/0/0

       12.0.0.1/32  Direct  0    0           D   127.0.0.1       Serial1/0/0

       12.0.0.2/32  Direct  0    0           D   12.0.0.2        Serial1/0/0

     12.0.0.255/32  Direct  0    0           D   127.0.0.1       Serial1/0/0

       22.1.1.0/24  RIP     100  1           D   12.0.0.2        Serial1/0/0

       23.0.0.0/24  RIP     100  1           D   12.0.0.2        Serial1/0/0

       33.1.1.0/24  RIP     100  2           D   12.0.0.2        Serial1/0/0

      127.0.0.0/8   Direct  0    0           D   127.0.0.1       InLoopBack0

      127.0.0.1/32  Direct  0    0           D   127.0.0.1       InLoopBack0

127.255.255.255/32  Direct  0    0           D   127.0.0.1       InLoopBack0

255.255.255.255/32  Direct  0    0           D   127.0.0.1       InLoopBack0

 

[r1]

[r1]ping 33.1.1.1

ping 33.1.1.1

  PING 33.1.1.1: 56  data bytes, press CTRL_C to break

    Reply from 33.1.1.1: bytes=56 Sequence=1 ttl=254 time=210 ms

    Reply from 33.1.1.1: bytes=56 Sequence=2 ttl=254 time=20 ms

    Reply from 33.1.1.1: bytes=56 Sequence=3 ttl=254 time=30 ms

    Reply from 33.1.1.1: bytes=56 Sequence=4 ttl=254 time=50 ms

    Reply from 33.1.1.1: bytes=56 Sequence=5 ttl=254 time=40 ms

 

  --- 33.1.1.1 ping statistics ---

    5 packet(s) transmitted

    5 packet(s) received

    0.00% packet loss

    round-trip min/avg/max = 20/70/210 ms

 

[r1]ping -a 11.1.1.1 33.1.1.1      ---环回口1 ping通环回口3

ping -a 11.1.1.1 33.1.1.1

  PING 33.1.1.1: 56  data bytes, press CTRL_C to break

    Reply from 33.1.1.1: bytes=56 Sequence=1 ttl=254 time=30 ms

    Reply from 33.1.1.1: bytes=56 Sequence=2 ttl=254 time=30 ms

    Reply from 33.1.1.1: bytes=56 Sequence=3 ttl=254 time=20 ms

    Reply from 33.1.1.1: bytes=56 Sequence=4 ttl=254 time=20 ms

    Reply from 33.1.1.1: bytes=56 Sequence=5 ttl=254 time=40 ms

 

  --- 33.1.1.1 ping statistics ---

    5 packet(s) transmitted

    5 packet(s) received

    0.00% packet loss

    round-trip min/avg/max = 20/28/40 ms

 

[r1]quit

quit

--------------------------------------AR3  ping  AR1-------------------------------

[r3]ping 11.1.1.1

ping 11.1.1.1

  PING 11.1.1.1: 56  data bytes, press CTRL_C to break

    Reply from 11.1.1.1: bytes=56 Sequence=1 ttl=254 time=60 ms

    Reply from 11.1.1.1: bytes=56 Sequence=2 ttl=254 time=30 ms

    Reply from 11.1.1.1: bytes=56 Sequence=3 ttl=254 time=30 ms

    Reply from 11.1.1.1: bytes=56 Sequence=4 ttl=254 time=40 ms

    Reply from 11.1.1.1: bytes=56 Sequence=5 ttl=254 time=40 ms

 

  --- 11.1.1.1 ping statistics ---

    5 packet(s) transmitted

    5 packet(s) received

    0.00% packet loss

    round-trip min/avg/max = 30/40/60 ms

 

[r3]quit