Backup Interfaces
In Theory
A backup interface is an interface that stays inactive as long as the primary interface is in “up/up” state, but becomes active when the primary interface’s protocol status becomes “down”. When the protocol on the primary interface comes back up, the backup interface moves back in a “standby mode”. You should know that if the primary interface is administratively down, the backup interface won’t come up. So to test, you have to do something on the other end. The backup interface can be configured to come up not only when the primary interface is down, but also when it’s utilization reaches a certain threshold:
R(config-if)# backup load {enable_threshold|never} {disable_load|never}To prevent link flapping you can delay the switchover using:
R(config-if)# backup delay {enable_delay|never} {disable_delay|never}In Practice
Here’s an example:
Backup Interface Example
R1 and R2 are connected over Fa0/0 and Seria1/0 interfaces. We will configure Fa0/0 with ip addresses in 12.0.0.0/24 range S1/0 with addresses in 21.0.0.0/24 range. To test connectivity we will enable one loopback on each router and start rip to to advertise the routes from one to another
!On R1:
R1(config)# interface Fa0/0
R1(config-if)# ip address 12.0.0.1 255.255.255.0
R1(config-if)# no shut
R1(config-if)# exit
R1(config)# interface Serial1/0
R1(config-if)# ip address 21.0.0.1 255.255.255.0
! On newer IOS version, no need to specify clock rate on the DCE
R1(config-if)# no shut
R1(config)# interface Lo0
R1(config-if)# ip address 1.1.1.1 255.255.255.255
R1(config-if)# exit
R1(config-if)# router rip
R1(config-router)# network 0.0.0.0
!On R2:
R2(config)# interface Fa0/0
R2(config-if)# ip address 12.0.0.2 255.255.255.0
R2(config-if)# no shut
R2(config-if)# exit
R2(config)# interface Serial1/0
R2(config-if)# ip address 21.0.0.2 255.255.255.0
R2(config-if)# no shut
R2(config)# interface Lo0
R2(config-if)# ip address 2.2.2.2 255.255.255.255
R2(config-if)# exit
R2(config-if)# router rip
R2(config-router)# network 0.0.0.0Shortly, we should be able to ping each router’s loopback interface, from the other one:
Let’s verify the routing tables, also.
Notice the 2 routes installed for the loopback addresses, one for each physical link.
The good interface
Now let’s enable Fa0/0 as backup for S1/0 on R1. Let’s also start debugging on R1:
As soon as we set Fa0/0 as the backup interface of S1/0, the backup interface goes down, in standby mode:
We can see the status with:
Now let’s shut down the serial link on R2:
Now, based on the keepalive mechanism, the serial link on R1 will move the link into an “up/down” state in about 30 seconds (3 missed keepalives) and will move the backup interface in forwarding mode:
The routing protocol converges and we can ping 2.2.2.2 from 1.1.1.1
When we bring back up the serial interface on R2, Serial 1/0 will come up on R1 and Fa0/0 will move to standby mode again:
The bad interface
Things worked as expected when we set a backup for the serial interface. Now let’s try setting the serial interface as the backup for the ethernet interface:
Thinks work as expected, now let’s shut the FastEthernet interface on R2:
And now we wait… When you have waited long enough, you shoud have noticed that the FastEthernet interface on Fa0/0 never went down. The keepalive mechanism on Ethernet links is not used to test connectivity with another host, but to see if the interface can send and receive Ethernet frames. This is because Ethernet links are not considered point-to-point interfaces and they are expected to find more than one neighbor on the link. Since the link will always be up, the backup interface will remain in standby mode and will not be used for forwarding.
The same thing would happen with other Multipoint interfaces, like the Frame Relay physical interface or the multipoing subinterface. A point-to-point subinterface would move the protocol status to down when the DLCI assigned to it si not active.
The solution here is to use a more advanced tracking system, like Enhanced Object Tracking
Last updated
Was this helpful?
