How to configure floating routing?

How to configure floating routing?

[[416937]]

Experimental requirements

ISP-1 and ISP-2 use the same loopback port address. By changing the administrative distance of the GW default route, the GW can select the default route with a smaller administrative distance as the primary route and the default route with a larger administrative distance as the backup route, so as to achieve the purpose of selecting the best route for data communication.

IP Address Table

Experimental Configuration

as follows

Configure ISP-1:

  1. ISP-1(config)#interface f0/0
  2. ISP-1(config-if)#ipaddress 192.168.1.1 255.255.255.0 ISP-1(config-if)#noshutdown
  3. ISP-1(config-if)#exit
  4. ISP-1(config)#interface loopback 0
  5. ISP-1(config-if)#ipaddress 123.1.1.1 255.255.255.0 ISP-1(config-if)#exit

Configure ISP-2:

  1. ISP-2(config)#interfacef0/0
  2. ISP-2(config-if)#ipaddress192.168.2.2 255.255.255.0
  3. ISP-2(config-if)#noshutdown
  4. ISP-2(config-if)#exit
  5. ISP-2(config)#interfaceloopback0
  6. ISP-2(config-if)#ipaddress 123.1.1.1 255.255.255.0 ISP-2(config-if)#exit

Configure GW:

  1. GW(config)#interface f1/0
  2. GW(config-if)#ipaddress 192.168.1.2 255.255.255.0
  3. GW(config-if)#noshutdown
  4. GW(config-if)#exit
  5. GW(config)#interface f0/0
  6. GW(config-if)#ipaddress 192.168.2.1 255.255.255.0
  7. GW(config-if)#noshutdown
  8. GW(config-if)#exit
  9. GW(config)#iproute 123.1.1.1 255.255.255.255192.168.1.1 //

The line is the main line, the management distance is changed to 10, and this line is set as the backup line.

GW(config)#iproute 123.1.1.1 255.255.255.255192.168.2.2 10 //Set this line as the default route

Next: show iproute -----à Check the routing table. The GW shows that there are two links to the outgoing address 123.1.1.1, with administrative distances of 1 and 10 respectively.

Experimental Summary

When the administrative distance is not changed, the GW cannot reach the address 123.1.1.1. However, communication is possible by shutting down any interface on the GW.

After the administrative distance is changed, the GW will select the line with the smaller administrative distance as the primary line and communicate with the 123.1.1.1 address from the primary line.

<<:  Foreign media: As of June, South Korea's 5G users have exceeded 16 million

>>:  5G lacks "soul"? Advanced technology is coming

Recommend

Thoroughly understand computer network communication equipment and protocols

【51CTO.com original article】 Table of contents 1....

Net loss of fixed-line broadband users: China Unicom sounds red alert

December 22 news (Yue Ming) Recently, the three m...

TCP three-way handshake and four-way wave and 11 states

[[331585]] Source: 22j.co/buCw Three-way handshak...

How does Baidu Netdisk steal your traffic?

Recently, Baidu has once again been at the center...

A Deep Dive into Data Link Layer Devices

In computer networks, there are multiple layers t...