RIP conditional route advertisement

From: Joseph Brunner (joe@affirmedsystems.com)
Date: Sun Nov 11 2007 - 01:38:53 ART


From my own personal lab testing of the doc cd;

 

Task:

 

Router6 should advertise a rip default route ONLY to Switch1 and ONLY if
either 150.1.1.0/24 or 150.1.3.0/24 exist in the routing table.

 

 

rack1r6#sh run | b router rip

router rip

 version 2

 network 1.0.0.0

 network 150.1.0.0

 default-information originate route-map BBNETSCHECK

 no auto-summary

 

route-map BBNETSCHECK permit 10

 match ip address 10

 set interface FastEthernet0/0

!

route-map BBNETSCHECK permit 20

 match ip address 20

 set interface FastEthernet0/0

 

access-list 10 permit 150.1.1.0 0.0.0.255

access-list 20 permit 150.1.3.0 0.0.0.255

 

Verification;

 

(see if the route is now on sw1)

 

rack1sw1#sh ip route 0.0.0.0

Routing entry for 0.0.0.0/0, supernet

  Known via "rip", distance 120, metric 1, candidate default path

  Redistributing via ospf 1, rip

  Last update from 1.1.16.6 on GigabitEthernet0/6, 00:00:02 ago

  Routing Descriptor Blocks:

  * 1.1.16.6, from 1.1.16.6, 00:00:02 ago, via GigabitEthernet0/6

      Route metric is 1, traffic share count is 1

 

Verification

rack1r6(config)#int f0/1

rack1r6(config-if)#shut

rack1r6#sh ip route 150.1.1.0

% Subnet not in table

 

(back on sw1, wait more than 30 seconds to be safe)

 

rack1sw1#sh ip route 0.0.0.0

Routing entry for 0.0.0.0/0, supernet

  Known via "rip", distance 120, metric 1, candidate default path

  Redistributing via ospf 1, rip

  Last update from 1.1.16.6 on GigabitEthernet0/6, 00:00:18 ago

  Routing Descriptor Blocks:

  * 1.1.16.6, from 1.1.16.6, 00:00:18 ago, via GigabitEthernet0/6

      Route metric is 1, traffic share count is 1

 

(now shutdown the last interface towards BB3, 150.1.3.0/24 on router 6)

rack1r6(config)#int s0/0

rack1r6(config-if)#shut

rack1r6(config-if)#^Z

rack1r6#sh ip route 150.1.3.0

% Network not in table

 

(Check on switch1; wait a while, past invalid then flush timer)

 

rack1sw1#sh ip route 0.0.0.0

Routing entry for 0.0.0.0/0, supernet

  Known via "rip", distance 120, metric 1, candidate default path

  Redistributing via ospf 1, rip

  Last update from 1.1.16.6 on GigabitEthernet0/6, 00:02:58 ago

  Routing Descriptor Blocks:

  * 1.1.16.6, from 1.1.16.6, 00:02:58 ago, via GigabitEthernet0/6

      Route metric is 1, traffic share count is 1

 

rack1sw1#sh ip route 0.0.0.0

Routing entry for 0.0.0.0/0, supernet

  Known via "rip", distance 120, metric 4294967295 (inaccessible), candidate
default path

  Redistributing via ospf 1, rip

  Last update from 1.1.16.6 on GigabitEthernet0/6, 00:03:02 ago

  Hold down timer expires in 0 secs

 

(Gone)

 

 

rack1sw1#sh ip route 0.0.0.0

% Network not in table



This archive was generated by hypermail 2.1.4 : Sat Dec 01 2007 - 06:37:29 ART