Saturday, March 1, 2014

IP Default Gateway / IP Default Network


Lessons learned:

IP Default- Gateway

-Only when IP routing is off

Note: Normally used for Layer 2 switches that don’t support IP Routing.

Note: If you’re doing dynamic routing and you do want to advertise a default route, and not advertise the 0.0.0.0 prefix. You can use the feature “IP Default-Network”.  This must be a classful network for ex, if it’s a Class B network it must be a /16. So when / if you’re learning a router dynamically whether from RIP or EIGRP, you can tag the network as the candidate default. This will then be propagates throughout the rest of the routing domain as if it were the default gateway on a hop-by-hop basis.

This feature was originally for RIP version 1 and IGRP. This is because the IGRP did not support the prefix 0.0.0.0

Routing table before “IP Default-Network” setup:

Gateway of last resort is not set – Note: the default network is not set.

     34.0.0.0/24 is subnetted, 1 subnets

D       34.0.0.0 [90/284160] via 23.0.0.3, 00:07:01, FastEthernet0/1

                 [90/284160] via 14.0.0.4, 00:07:01, FastEthernet0/0

     23.0.0.0/8 is variably subnetted, 2 subnets, 2 masks

C       23.0.0.0/24 is directly connected, FastEthernet0/1

D       23.0.0.0/8 is a summary, 00:07:01, Null0

     12.0.0.0/24 is subnetted, 1 subnets

D       12.0.0.0 [90/30720] via 14.0.0.1, 00:02:05, FastEthernet0/0

     14.0.0.0/8 is variably subnetted, 2 subnets, 2 masks

C       14.0.0.0/24 is directly connected, FastEthernet0/0

D       14.0.0.0/8 is a summary, 00:07:02, Null0

R5#

IP Default-Network:
(or candidate default route)

-Network flagged as default in routing advertisements

-Must be a classful network that is not directly connected

Let’s configure a def-network:

R5(config)#ip default-network 12.0.0.0

Now let’s view the routing table after the network statement is applied.
Gateway of last resort is 14.0.0.1 to network 12.0.0.0 – Notice we not have a Def-Network set


     34.0.0.0/24 is subnetted, 1 subnets

D       34.0.0.0 [90/284160] via 23.0.0.3, 00:10:46, FastEthernet0/1

                 [90/284160] via 14.0.0.4, 00:10:46, FastEthernet0/0

     23.0.0.0/8 is variably subnetted, 2 subnets, 2 masks

C       23.0.0.0/24 is directly connected, FastEthernet0/1

D       23.0.0.0/8 is a summary, 00:10:46, Null0

 *   12.0.0.0/24 is subnetted, 1 subnets – Notice the asterisk for the candidate Def-Route.

D*      12.0.0.0 [90/30720] via 14.0.0.1, 00:05:50, FastEthernet0/0

     14.0.0.0/8 is variably subnetted, 2 subnets, 2 masks

C       14.0.0.0/24 is directly connected, FastEthernet0/0

D       14.0.0.0/8 is a summary, 00:10:47, Null0

R5#

Note: the route with the Asterisk next to it – means that it is not the candidate default network. This also means that the default-network is going to change on a hop-by-hop basis.

No comments:

Post a Comment