How to:
Automatic backup using dynamic routing
Use the display backup method to enter the backup
Use floating static routing method for backup
Method 1 is to contain multiple redundant lines in the network, and the router learns the working conditions of all lines through dynamic routing. According to the routing algorithm, the optimal path is selected as the main line. Once a main line fails, the router will automatically delete the path through the line after a period of time, re-perform the optimal path calculation, and re-select an optimal path through a certain redundant line. All these processes are automatically completed by the dynamic routing protocol without any other settings.
Method 2 Display backup method
This method shows which main line is specified and which is the backup line. If the main line fails, the backup line will work instead of the main line within the specified time. If the main line returns to normal, after the specified time, the main line backup line will be automatically switched back to the main line and is in the backup state again.
After setting to display backup, the router will monitor the CD signal. Once the CD signal disappears, the router will consider that the line has failed. If the CD signal always exists, the router considers the backbone to be working properly.
This preparation method is suitable for the situation where the DDN dedicated line is used as the main line. Because for DDN dedicated lines, if the line is broken, the CD signals of the routers on both sides will disappear, and this method is not suitable for X.25 lines, because when there is a failure on the X.25 line, virtual circuits cannot be established in most cases, and CD signals often exist. Moreover, if the X.25 line at one end fails, and the X.25 line at the other end is often normal. In this way, if the router at the normal end has data transmitted to the abnormal end, the router believes that the X.25 line is working normally. Therefore, there will be no backup line at all.
Display backup method configuration steps
1. Correctly configure the main line to communicate normally
2. Then correctly configure the backup line to communicate normally
3. Displays the port connected to the main line indicating which line is the backup line
backup interface backup line port number
4. Specifies how long does the backup line be enabled after the main line fails and how long does the main line return to normal after the main line returns to normal. Restore the backup line to backup status
backup delay time parameter 1 (seconds) time parameter word 2 (seconds)
Time parameter 1 specifies how long does the backup line need to be enabled after the main line fails, and Time parameter 2 specifies how long does the main line return to the main line after the main line is restored to normal, and the backup line will be restored to the backup state.
The routing of the backup line can be routed in any way, but the backup line generally has a lower bandwidth than the backbone line, and there will be additional costs if dynamic routing is started. Therefore, static routing is generally used on backup lines.
In global settings mode
ip route destination subnet address subnet mask adjacent router’s adjacent port address
In principle, the backup line can be any line. However, lines with relatively low bandwidth and low cost are generally used as backup lines.
Generally, X.25 or PSTN can be used as backup of DDN lines.
The following example is a dial-up backup of the simulated DDN dedicated line using the Cisco2501 AUX port.
Example:
Cisco 2501-above configuration
Current configuration:
!
version 11.2
no service udp-small-servers
no service tcp-small-servers
!
hostname above
!
enable secret 5 $1$O1aq$Kxgp1A0Eulqug8SbCm6rdl
enable password cisco
!
username down password 7 095C5E19
chat-script lab ABORT ERROR ABORT BUSY ABORT "NO ANSWER" "" "AT H" OK "ATDT \T"
TIMEOUT 60 CONNECT \c
!
interface Ethernet0
ip address 192.192.193.1 255.255.255.0
!
interface Serial0
ip address 192.192.192.1 255.255.255.0
bandwidth 64
clockrate 64000
!
interface Serial1no ip address
shutdown
!
interface Async1
ip address 166.71.70.1 255.255.255.0
encapsulation ppp
async dynamic address
async dynamic routing
async mode dedicated
dialer in-band
dialer map ip 167.71.70.2 name down moden-script lab broadcast 3631
dialer-group 1
no cdp enable
ppp authentication chap
!
router rip
network l92.192.192.0
nctwork 192.192.193.0
!
no ip classless
ip route 0.0.0.0 0.0.0.0 166.71.70.2
ip routc 192.192.191.0 255.255.255.0 166.71.70.2
dialer-list 1 protocol ip permit
!
line con 0
line aux 0
modem InOut
modem autoconfigure discovery
stopbits 1
rxspeed 38400
txspeed 38400
flowcontrol hardware
line vty 0 4
no login
!
end
!Cisco 2501 named down configurationCisco 2501-down ConfigurationCurrent configuration:
!
version 11.2
no service udp-small-servers
no servicc tcp-small-servers
!
hostname down
!
enable secret 5 $1$m8S4$lnrkhnJDtCVtSvTpXO8v/0
enable password cisco
!
username above password 7 095C5E19
chat-script lab ABORT ERROR ABORT BUSY ABORT "NO ANSWER" "" "AT H" OK "ATDT \T" TIMEOUT 60 CONNECT \C
!
interface Ethernet 0
ip address 192.192.191.1 255.255.255.0
!
interface Serial0
backup delay 10 10
backup interface Async1
ip address 192.192.192.3 255.255.255.0
!
interface Seriall
no ip address
shutdown
!
interface Async1
ip address 166.71.70.2 255.255.255.0
encapsulation ppp
async dynamic address
async dynamic routing
async mode dedicated
dialer in-band
dialer map ip 166.71.70.1 name above modem-script lab broadcast 3621
dialer-group 1
no cdp enable
ppp authentication chap
!
router rip
net work 192.192.192.0
net work 192.192.191.0
!
no ip classless
ip route 0.0.0.0 0.0.0.0 166.71.70.1
ip route 192.192.193.0 255.255.255.0 166.71.70.1
dialer-list 1 protocol ip permit
!
line con 0
line aux 0
modem InOut
modem autoconfigure discovery
stopbits 1
rxspeed 38400
txspeed 38400
flowcontrol hardware
line vty 0 4
no login
!
Method 3: Floating static routes for backup.
By default, the order in which the Cisco router selects routes is static routes, dynamic routes, and default routes, which are determined by the weights of various routes.
The weight size of the static route can be manually changed so that it can become a floating static route after the dynamic route is routed. If the corresponding route cannot be found in the dynamic routing table, the floating static route can be selected to transmit data.
Generally, it is particularly suitable for X.25 lines to use floating static routes for dialing backup. However, using floating static routes can back up any other route with any route.
Note: When using floating static routes to backup X.25 lines, the X.25 lines must be dynamically routed, otherwise two-way backup cannot be achieved.
Floating static routing configuration steps:
1. Correctly configure the main line to ensure that it can communicate normally
2. Configure dynamic routing of main lines
3. Correctly configure the backup line to ensure that it can communicate normally
4. Configure floating static routes through backup lines
ip route destination subnet address subnet mask adjacent router’s adjacent port address weight
Among them, the higher the weight value, the lower the routing priority, the weight range is between 1-255.
Example:
COSCO 2501-above configuration
Current confignration:!version 11.2no service udp-small-servers
no service tcp-small-servers
!
hostname above
!
enable secret 5 $1$O1aq$KxgpIA0Eulqug8SbCm6rd1
enable password cisco
!
username down password 7 095C5E19
chat-scrip lab ABORT ERROR ABORT BUSY ABORT "NO ANSWER" "" "AT H" OK "ATDT \T" TIMEOUT 60 CONNECT \c
!
interface Ethernet0
ip address 192.192.193.1 255.255.255.0
!interface Serial0
iu address 192.192.192.1 255.255.255.0
bandwidth 64
clockrate 64000
!
interface Scrial1
no ip address
shutdown
interface Asyncl
ip address 166.71.70.1 255.255.255.0
encapsulation pppasync dynamic address
async dynamic routing
async mode dedicated
dialer in-banddialer ip 166.71.70.2 name down modem-script lab broadcast 3631
dialer-group 1
no cdp enableppp authentication chap!router ripnetwork 192.192.192.0network 192.192.193.0
!
no ip classless
ip route 0.0.0.0 0.0.0.0 166.71.70.2 150
ip route 192.192.191.0 255.255.255.0 166.71.70.2 150dialer-list 1 protocol ip permit!line con 0line aux 0
modem InOutmodem autoconfigure discoverystopbits 1rxspeed 38400txspeed 38400flowcontrol hardwareline vty 0 4
no login
!
end
Cisco 2501-down configuration Current configuration:
!
version 11.2no service udp-small-serversno service tep-small-servers!hostname down!enable secret 5 $1$m8S4$InrkhnJDtCVtSvTpXO8v/0enable password cisco
!
username above password 7 095C5E19
chat-script lab ABORT ERROR ABORT BUSY ABORT "NO ANSWER" "" "AT H" OK "ATDT \T" TIMEOUT 60 CONNECT \c
!
interface Ethernet0
ip address 192.192.191.1 255.255.255.0
!
interface Serial0
ip address 192.192.192.3 255.255.255.0
!
interface Serial1
no ip address
shutdown
!
interface Asyncl
ip address 166.71.70.2 255.255.255.0encapsulation pppasync dynamic addressasync dynamic routingasync mode dedicateddialer in-banddialer map ip 166.71.70.1 name above modem-script lab broadcast 3621
dialer-group 1
no cdp enable
ppp authentication chap
!
router rip network 192.192.192.0
network 192.192.191.0
!
no ip classless
ip route 0.0.0.0 0.0.0.0 166.71.70.1 150
ip route 192.192.193.0 255.255.255.0 166.71.70.1 150
dialer-list 1 protocol ip permit
!
line con 0
line aux 0
modem InOutmodem autoconfigure discovery
stopbits 1
rxspeed 38400
txspeed 38400
flowcontrol hardware
line vty 0 4
no login
Automatic backup using dynamic routing
Use the display backup method to enter the backup
Use floating static routing method for backup
Method 1 is to contain multiple redundant lines in the network, and the router learns the working conditions of all lines through dynamic routing. According to the routing algorithm, the optimal path is selected as the main line. Once a main line fails, the router will automatically delete the path through the line after a period of time, re-perform the optimal path calculation, and re-select an optimal path through a certain redundant line. All these processes are automatically completed by the dynamic routing protocol without any other settings.
Method 2 Display backup method
This method shows which main line is specified and which is the backup line. If the main line fails, the backup line will work instead of the main line within the specified time. If the main line returns to normal, after the specified time, the main line backup line will be automatically switched back to the main line and is in the backup state again.
After setting to display backup, the router will monitor the CD signal. Once the CD signal disappears, the router will consider that the line has failed. If the CD signal always exists, the router considers the backbone to be working properly.
This preparation method is suitable for the situation where the DDN dedicated line is used as the main line. Because for DDN dedicated lines, if the line is broken, the CD signals of the routers on both sides will disappear, and this method is not suitable for X.25 lines, because when there is a failure on the X.25 line, virtual circuits cannot be established in most cases, and CD signals often exist. Moreover, if the X.25 line at one end fails, and the X.25 line at the other end is often normal. In this way, if the router at the normal end has data transmitted to the abnormal end, the router believes that the X.25 line is working normally. Therefore, there will be no backup line at all.
Display backup method configuration steps
1. Correctly configure the main line to communicate normally
2. Then correctly configure the backup line to communicate normally
3. Displays the port connected to the main line indicating which line is the backup line
backup interface backup line port number
4. Specifies how long does the backup line be enabled after the main line fails and how long does the main line return to normal after the main line returns to normal. Restore the backup line to backup status
backup delay time parameter 1 (seconds) time parameter word 2 (seconds)
Time parameter 1 specifies how long does the backup line need to be enabled after the main line fails, and Time parameter 2 specifies how long does the main line return to the main line after the main line is restored to normal, and the backup line will be restored to the backup state.
The routing of the backup line can be routed in any way, but the backup line generally has a lower bandwidth than the backbone line, and there will be additional costs if dynamic routing is started. Therefore, static routing is generally used on backup lines.
In global settings mode
ip route destination subnet address subnet mask adjacent router’s adjacent port address
In principle, the backup line can be any line. However, lines with relatively low bandwidth and low cost are generally used as backup lines.
Generally, X.25 or PSTN can be used as backup of DDN lines.
The following example is a dial-up backup of the simulated DDN dedicated line using the Cisco2501 AUX port.
Example:
Cisco 2501-above configuration
Current configuration:
!
version 11.2
no service udp-small-servers
no service tcp-small-servers
!
hostname above
!
enable secret 5 $1$O1aq$Kxgp1A0Eulqug8SbCm6rdl
enable password cisco
!
username down password 7 095C5E19
chat-script lab ABORT ERROR ABORT BUSY ABORT "NO ANSWER" "" "AT H" OK "ATDT \T"
TIMEOUT 60 CONNECT \c
!
interface Ethernet0
ip address 192.192.193.1 255.255.255.0
!
interface Serial0
ip address 192.192.192.1 255.255.255.0
bandwidth 64
clockrate 64000
!
interface Serial1no ip address
shutdown
!
interface Async1
ip address 166.71.70.1 255.255.255.0
encapsulation ppp
async dynamic address
async dynamic routing
async mode dedicated
dialer in-band
dialer map ip 167.71.70.2 name down moden-script lab broadcast 3631
dialer-group 1
no cdp enable
ppp authentication chap
!
router rip
network l92.192.192.0
nctwork 192.192.193.0
!
no ip classless
ip route 0.0.0.0 0.0.0.0 166.71.70.2
ip routc 192.192.191.0 255.255.255.0 166.71.70.2
dialer-list 1 protocol ip permit
!
line con 0
line aux 0
modem InOut
modem autoconfigure discovery
stopbits 1
rxspeed 38400
txspeed 38400
flowcontrol hardware
line vty 0 4
no login
!
end
!Cisco 2501 named down configurationCisco 2501-down ConfigurationCurrent configuration:
!
version 11.2
no service udp-small-servers
no servicc tcp-small-servers
!
hostname down
!
enable secret 5 $1$m8S4$lnrkhnJDtCVtSvTpXO8v/0
enable password cisco
!
username above password 7 095C5E19
chat-script lab ABORT ERROR ABORT BUSY ABORT "NO ANSWER" "" "AT H" OK "ATDT \T" TIMEOUT 60 CONNECT \C
!
interface Ethernet 0
ip address 192.192.191.1 255.255.255.0
!
interface Serial0
backup delay 10 10
backup interface Async1
ip address 192.192.192.3 255.255.255.0
!
interface Seriall
no ip address
shutdown
!
interface Async1
ip address 166.71.70.2 255.255.255.0
encapsulation ppp
async dynamic address
async dynamic routing
async mode dedicated
dialer in-band
dialer map ip 166.71.70.1 name above modem-script lab broadcast 3621
dialer-group 1
no cdp enable
ppp authentication chap
!
router rip
net work 192.192.192.0
net work 192.192.191.0
!
no ip classless
ip route 0.0.0.0 0.0.0.0 166.71.70.1
ip route 192.192.193.0 255.255.255.0 166.71.70.1
dialer-list 1 protocol ip permit
!
line con 0
line aux 0
modem InOut
modem autoconfigure discovery
stopbits 1
rxspeed 38400
txspeed 38400
flowcontrol hardware
line vty 0 4
no login
!
Method 3: Floating static routes for backup.
By default, the order in which the Cisco router selects routes is static routes, dynamic routes, and default routes, which are determined by the weights of various routes.
The weight size of the static route can be manually changed so that it can become a floating static route after the dynamic route is routed. If the corresponding route cannot be found in the dynamic routing table, the floating static route can be selected to transmit data.
Generally, it is particularly suitable for X.25 lines to use floating static routes for dialing backup. However, using floating static routes can back up any other route with any route.
Note: When using floating static routes to backup X.25 lines, the X.25 lines must be dynamically routed, otherwise two-way backup cannot be achieved.
Floating static routing configuration steps:
1. Correctly configure the main line to ensure that it can communicate normally
2. Configure dynamic routing of main lines
3. Correctly configure the backup line to ensure that it can communicate normally
4. Configure floating static routes through backup lines
ip route destination subnet address subnet mask adjacent router’s adjacent port address weight
Among them, the higher the weight value, the lower the routing priority, the weight range is between 1-255.
Example:
COSCO 2501-above configuration
Current confignration:!version 11.2no service udp-small-servers
no service tcp-small-servers
!
hostname above
!
enable secret 5 $1$O1aq$KxgpIA0Eulqug8SbCm6rd1
enable password cisco
!
username down password 7 095C5E19
chat-scrip lab ABORT ERROR ABORT BUSY ABORT "NO ANSWER" "" "AT H" OK "ATDT \T" TIMEOUT 60 CONNECT \c
!
interface Ethernet0
ip address 192.192.193.1 255.255.255.0
!interface Serial0
iu address 192.192.192.1 255.255.255.0
bandwidth 64
clockrate 64000
!
interface Scrial1
no ip address
shutdown
interface Asyncl
ip address 166.71.70.1 255.255.255.0
encapsulation pppasync dynamic address
async dynamic routing
async mode dedicated
dialer in-banddialer ip 166.71.70.2 name down modem-script lab broadcast 3631
dialer-group 1
no cdp enableppp authentication chap!router ripnetwork 192.192.192.0network 192.192.193.0
!
no ip classless
ip route 0.0.0.0 0.0.0.0 166.71.70.2 150
ip route 192.192.191.0 255.255.255.0 166.71.70.2 150dialer-list 1 protocol ip permit!line con 0line aux 0
modem InOutmodem autoconfigure discoverystopbits 1rxspeed 38400txspeed 38400flowcontrol hardwareline vty 0 4
no login
!
end
Cisco 2501-down configuration Current configuration:
!
version 11.2no service udp-small-serversno service tep-small-servers!hostname down!enable secret 5 $1$m8S4$InrkhnJDtCVtSvTpXO8v/0enable password cisco
!
username above password 7 095C5E19
chat-script lab ABORT ERROR ABORT BUSY ABORT "NO ANSWER" "" "AT H" OK "ATDT \T" TIMEOUT 60 CONNECT \c
!
interface Ethernet0
ip address 192.192.191.1 255.255.255.0
!
interface Serial0
ip address 192.192.192.3 255.255.255.0
!
interface Serial1
no ip address
shutdown
!
interface Asyncl
ip address 166.71.70.2 255.255.255.0encapsulation pppasync dynamic addressasync dynamic routingasync mode dedicateddialer in-banddialer map ip 166.71.70.1 name above modem-script lab broadcast 3621
dialer-group 1
no cdp enable
ppp authentication chap
!
router rip network 192.192.192.0
network 192.192.191.0
!
no ip classless
ip route 0.0.0.0 0.0.0.0 166.71.70.1 150
ip route 192.192.193.0 255.255.255.0 166.71.70.1 150
dialer-list 1 protocol ip permit
!
line con 0
line aux 0
modem InOutmodem autoconfigure discovery
stopbits 1
rxspeed 38400
txspeed 38400
flowcontrol hardware
line vty 0 4
no login