Monday, December 6, 2010

Static Route, Floating Static Route and Default Static Route

Static route is used when one wants to define the routing process manually.

The static route command is as below:

(config)#ip route

On the exit interface of the router part, the interface can be defined as the type of interface (e.g. serial0, fa0/2) or it can be defined as the ip address of the outbound interface of the router. The difference is that when we set it with the type of interface, the route is configured to be directly connected (AD=0), while the option of setting the IP address of the outbound interface will be considered as static route (AD=1)

The example below shows the 2 different configuration, but has actually the same meaning:

(config)#ip route 10.10.10.10 255.255.255.255 172.168.10.10 --> static route AD=1
(config)#ip route 10.10.10.10 255.255.255.255 serial0 --> direct connected AD=0

A floating static route is a route that is used to back up a dynamic protocol. So, the floating static route will take over the routing when the dynamic protocol such as RIP or OSPF goes down for some reason on an interface. The key in setting a floating static route is the same as in configuring a static route, but adding the administrative distance of it. The AD must be higher than the current value of the dynamic protocol. If we use RIP as the protocol we must set the floating route higher than 120. A value lower than 120 will have the opposite effect; the static route will be applied in routing rather than the RIP.

The floating static route can be done with the command:

(config)#ip route

The default static route is used as a gateway of last resort. If the router does not have a routing table of an incoming packet, then the router will send the packet to according to the default static route. If this route is not set, unknown incoming packets will be dropped.


The command for default static route can be shown below:

(config)#ip route 0.0.0.0 0.0.0.0 /

The symbol for default static route will be S* --> AD=0 (directly connected)/1(static)

Sometimes when updating routing policies the routes are not updated directly. A useful way to refresh the changes is to clear the ip route, and let the router discover the table again by applying the command:

RX#clear ip route*


No comments:

Post a Comment