linux配置rip动态路由实验

一、网络拓扑

linux配置rip动态路由实验

二、Rip协议配置

1.PC1 rip协议配置

ripd# conf t

ripd(config)# router rip

ripd(config-router)# version 2

ripd(config-router)# network 192.168.80.0/24

ripd(config-router)# write

ripd(config-router)# exit

ripd(config)# quit

2.PC2 rip协议配置

ripd# conf t

ripd(config)# router rip

ripd(config-router)# version 2

ripd(config-router)# network 192.168.80.0/24

ripd(config-router)# network 192.168.90.0/24

ripd(config-router)# write

Configuration saved to /usr/local/etc/ripd.conf

查看PC1的rip信息

ripd# sh ip protocols

Routing Protocol is "rip"

Sending updates every 30 seconds with +/-50%, next due in 10 seconds Timeout after 180 seconds, garbage collect after 120 seconds

Outgoing update filter list for all interface is not set

Incoming update filter list for all interface is not set

Default redistribution metric is 1

Redistributing:

Default version control: send version 2, receive version 2

Interface Send Recv Key-chain

eth0 2 2

Routing for Networks:

192.168.80.0/24

Routing Information Sources:

Gateway BadPackets BadRoutes Distance Last Update

192.168.80.184 0 0 120 00:00:08

Distance: (default is 120)

查看PC2的rip信息

ripd# sh ip protocols

Routing Protocol is "rip"

Sending updates every 30 seconds with +/-50%, next due in 36 seconds

Timeout after 180 seconds, garbage collect after 120 seconds

Outgoing update filter list for all interface is not set

Incoming update filter list for all interface is not set

Default redistribution metric is 1

Redistributing:

Default version control: send version 2, receive version 2

Interface Send Recv Key-chain

eth1 2 2

eth2 2 2

Routing for Networks:

192.168.80.0/24

192.168.90.0/24

Routing Information Sources:

Gateway BadPackets BadRoutes Distance Last Update

Distance: (default is 120)

3.在PC1中添加一条动态路由,在PC2上查看其rip信息及

其路由的变化

在PC1添加一条动态路由

ripd# conf t

ripd(config)# router rip

ripd(config-router)# version 2

ripd(config-router)# network 192.168.100.0/24

ripd(config-router)# write

Configuration saved to /usr/local/etc/ripd.conf

ripd(config-router)#

查看PC2的rip信息及路由变化

ripd# sh ip protocols

Routing Protocol is "rip"

Sending updates every 30 seconds with +/-50%, next due in 5 seconds

Timeout after 180 seconds, garbage collect after 120 seconds

Outgoing update filter list for all interface is not set

Incoming update filter list for all interface is not set

Default redistribution metric is 1

Redistributing:

Default version control: send version 2, receive version 2

Interface Send Recv Key-chain

eth1 2 2

eth2 2 2

Routing for Networks:

192.168.80.0/24

192.168.90.0/24

Routing Information Sources:

Gateway BadPackets BadRoutes Distance Last Update

192.168.80.171 0 0 120 00:00:09 Distance: (default is 120)

ripd# sh ip rip

Codes: R - RIP, C - connected, O - OSPF, B - BGP

(n) - normal, (s) - static, (d) - default, (r) - redistribute,

(i) - interface

Network Next Hop Metric From Time C(i) 192.168.80.0/24 0.0.0.0 1 self

C(i) 192.168.90.0/24 0.0.0.0 1 self

R(n) 192.168.100.0/24 192.168.80.171 2 192.168.80.171 02:27 ripd#

相关推荐
相关主题
热门推荐