路由間Rip V2協議的建立,認證以及觸發更新

 
剛剛學了一下Rip協議的使用....現在與大家分享一下經驗
 
我是用小凡摸擬器做出來的3臺3640路由
 
接口情況如下:
 
Router1 S0/0 <----> Router2 S0/0
Router2 S0/1 <----> Router3 S0/1
 
R1 命令:

Router>en
Router#conf t
Router(config)#ho r1
r1(config)#line co 0
r1(config-line)#logg sy
r1(config-line)#exec-timeout 0 0
r1(config-line)#exit
r1(config)#no ip domain-lookup
 
r1(config)#int loopback 0
r1(config-if)#ip ad 1.1.1.1 255.255.255.0
r1(config-if)#exit
 
r1(config)#int s0/0
r1(config-if)#ip ad 192.168.12.1 255.255.255.0
r1(config-if)#no sh
r1(config-if)#exit
 
r1(config)#router rip
r1(config-router)#ver 2
r1(config-router)#no auto-summary
r1(config-router)#network 1.0.0.0
r1(config-router)#network 192.168.12.0
r1(config-router)#exit
 
r1(config)#key chain test
r1(config-keychain)#key 1
r1(config-keychain-key)#key-string cisco
r1(config-keychain-key)#exit
r1(config-keychain)#exit
 
r1(config)#int s0/0
r1(config-if)#ip rip authentication mode md5
r1(config-if)#ip rip authentication key-chain test
r1(config-if)#ip rip triggered
r1(config-if)#end
 
R2 命令:


Router>en
Router#conf t
Router(config)#ho r2
r2(config)#line co 0

r2(config-line)#logg sy

r2(config-line)#exec-timeout 0 0
r2(config-line)#exit

r2(config)#no ip domain-lookup

 

r2(config)#int loopback 0

r2(config-if)#ip ad 2.2.2.2 255.255.255.0

r2(config-if)#exit

 

r2(config)#int s0/0

r2(config-if)#ip ad 192.168.12.2 255.255.255.0

r2(config-if)#no sh

r2(config-if)#exit

 

r2(config)#int s0/1

r2(config-if)#ip ad 192.168.23.2 255.255.255.0

r2(config-if)#no sh

r2(config-if)#exit

 

r2(config)#router rip

r2(config-router)#ver 2

r2(config-router)#no auto-summary

r2(config-router)#network 2.0.0.0

r2(config-router)#network 192.168.12.0

r2(config-router)#network 192.168.23.0

r2(config-router)#exit

 

r2(config)#key chain test

r2(config-keychain)#key 1

r2(config-keychain-key)#key-string cisco

r2(config-keychain-key)#exit

r2(config-keychain)#exit

 

r2(config)#int s0/0

r2(config-if)#ip rip authentication mode md5

r2(config-if)#ip rip authentication key-chain test

r2(config-if)#ip rip triggered

r2(config-if)#exit

 

r2(config)#int s0/1

r2(config-if)#ip rip authentication mode md5

r2(config-if)#ip rip authentication key-chain test

r2(config-if)#ip rip triggered

r2(config-if)#end

 
R3 命令:


Router>en
Router#conf t
Router(config)#ho r3
r3(config)#line co 0

r3(config-line)#logg sy

r3(config-line)#exec-timeout 0 0
r3(config-line)#exit

r3(config)#no ip domain-lookup

 

r3(config)#int loopback 0

r3(config-if)#ip ad 3.3.3.3 255.255.255.0

r3(config-if)#exit

 

r3(config)#int s0/1

r3(config-if)#ip ad 192.168.23.3 255.255.255.0

r3(config-if)#no sh

r3(config-if)#exit

 

r3(config)#router rip

r3(config-router)#ver 2

r3(config-router)#no auto-summary

r3(config-router)#network 3.0.0.0

r3(config-router)#network 192.168.23.0

r3(config-router)#exit

 

r3(config)#key chain test

r3(config-keychain)#key 1

r3(config-keychain-key)#key-string cisco

r3(config-keychain-key)#exit

r3(config-keychain)#exit

 

r3(config)#int s0/1

r3(config-if)#ip rip authentication mode md5

r3(config-if)#ip rip authentication key-chain test

r3(config-if)#ip rip triggered

r3(config-if)#end

 
 
至此配置已經完畢,下面來驗證一下(注:已省略部分提示)
 
驗證R1
 
r1#sh ip route
Gateway of last resort is not set
C    192.168.12.0/24 is directly connected, Serial0/0
     1.0.0.0/24 is subnetted, 1 subnets
C       1.1.1.0 is directly connected, Loopback0
     2.0.0.0/24 is subnetted, 1 subnets
R       2.2.2.0 [120/1] via 192.168.12.2, 01:27:47, Serial0/0
     3.0.0.0/24 is subnetted, 1 subnets
R       3.3.3.0 [120/2] via 192.168.12.2, 01:27:47, Serial0/0
R    192.168.23.0/24 [120/1] via 192.168.12.2, 01:27:47, Serial0/0

 

r1#sh ip protocols
Routing Protocol is "rip"
  Outgoing update filter list for all interfaces is not set
  Incoming update filter list for all interfaces is not set
  Sending updates every 30 seconds, next due in 24 seconds
  Invalid after 180 seconds, hold down 0, flushed after 240
  Redistributing: rip
  Default version control: send version 2, receive version 2
    Interface             Send  Recv  Triggered RIP  Key-chain
    Serial0/0             2     2          Yes       test           
    Loopback0             2     2                                   
  Automatic network summarization is not in effect
  Maximum path: 4
  Routing for Networks:
    1.0.0.0
    192.168.12.0
  Routing Information Sources:
    Gateway         Distance      Last Update
    192.168.12.2         120      01:29:21
  Distance: (default is 120)
 
驗證R2
 
r2#sh ip route
Gateway of last resort is not set

 

C    192.168.12.0/24 is directly connected, Serial0/0
     1.0.0.0/24 is subnetted, 1 subnets
R       1.1.1.0 [120/1] via 192.168.12.1, 01:28:03, Serial0/0
     2.0.0.0/24 is subnetted, 1 subnets
C       2.2.2.0 is directly connected, Loopback0
     3.0.0.0/24 is subnetted, 1 subnets
R       3.3.3.0 [120/1] via 192.168.23.3, 01:29:23, Serial0/1
C    192.168.23.0/24 is directly connected, Serial0/1

 

r2#sh ip protocols
Routing Protocol is "rip"
  Outgoing update filter list for all interfaces is not set
  Incoming update filter list for all interfaces is not set
  Sending updates every 30 seconds, next due in 15 seconds
  Invalid after 180 seconds, hold down 0, flushed after 240
  Redistributing: rip
  Default version control: send version 2, receive version 2
    Interface             Send  Recv  Triggered RIP  Key-chain
    Serial0/0             2     2          Yes       test           
    Serial0/1             2     2          Yes       test           
    Loopback0             2     2                                   
  Automatic network summarization is not in effect
  Maximum path: 4
  Routing for Networks:
    2.0.0.0
    192.168.12.0
    192.168.23.0
  Routing Information Sources:
    Gateway         Distance      Last Update
    192.168.12.1         120      01:29:45
    192.168.23.3         120      01:31:04
  Distance: (default is 120)
 
驗證R3
 
r3#sh ip route
Gateway of last resort is not set

 

R    192.168.12.0/24 [120/1] via 192.168.23.2, 01:29:31, Serial0/1
     1.0.0.0/24 is subnetted, 1 subnets
R       1.1.1.0 [120/2] via 192.168.23.2, 01:29:31, Serial0/1
     2.0.0.0/24 is subnetted, 1 subnets
R       2.2.2.0 [120/1] via 192.168.23.2, 01:29:31, Serial0/1
     3.0.0.0/24 is subnetted, 1 subnets
C       3.3.3.0 is directly connected, Loopback0
C    192.168.23.0/24 is directly connected, Serial0/1

 

r3#sh ip protocol
Routing Protocol is "rip"
  Outgoing update filter list for all interfaces is not set
  Incoming update filter list for all interfaces is not set
  Sending updates every 30 seconds, next due in 17 seconds
  Invalid after 180 seconds, hold down 0, flushed after 240
  Redistributing: rip
  Default version control: send version 2, receive version 2
    Interface             Send  Recv  Triggered RIP  Key-chain
    Serial0/1             2     2          Yes       test           
    Loopback0             2     2                                   
  Automatic network summarization is not in effect
  Maximum path: 4
  Routing for Networks:
    3.0.0.0
    192.168.23.0
  Routing Information Sources:
    Gateway         Distance      Last Update
    192.168.23.2         120      01:31:38
  Distance: (default is 120)
 
 
這裏我沒有設置串口的時鐘....因爲我不知道它的作用是什麼....還望各位大哥告知一
 
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章