HSRP experiment summary and analysis

Source: Internet
Author: User

HSRP experiment summary and analysis

I personally think that HSRP is for the terminal network, that is, the last hop of the route. Because there is a dynamic routing protocol between routes, we can find and adjust the actual route lines, hot-Standby Routing is available. The gateway of terminal devices, such as computers, servers, and handheld devices, is single, or is single by default. Therefore, you need to implement hot backup for the gateway IP address.

Introduction:

HSRP (Hot Standby Router Protocol): A private layer-4 protocol for Cisco.

HSRP provides network redundancy for IP networks to ensure immediate and transparent recovery of user traffic.Network border (terminal Network)In a device or access circuitFirst hopFault.

In a LAN, multiple routers form an HSRP group. One of the routers represents the HSRP forwarding data streams in the LAN. All other routers only send HSRP hello to maintain the HSRP group relationship.

An HSRP group shares an IP address and a MAC address. Each router can be addedMultiple groups.

An HSRP group consists of an active router, a standby router, and an other routers.

1> the active router forwards the data stream pointing to the VIP and sends the HSRP Hello packet to all other HSRP members. (Eventually in active state)

2> Standby Router does not forward data streams pointing to the VIP. It sends the HSRP Hello packet to all other HSRP members and monitors the status of the active router. (Eventually in the STANDBY state)

3> the other routers does not forward data streams directed to the VIP. It only monitors the HSRP Hello packet and does not send the packets. They perform the work of common router, and only forward the target to their own group, without forwarding the target to the VIP address. (Eventually in the listen state)

 

How to identify whether there is HSRP Hot Standby: tracert IP addresses of different network segments, if the first hop is not a gateway, it is likely that there is hot standby. In this case, I have always wondered that when ICMP reports TTL timeout, the real IP address of the port is actually fed back, not the VIP address. Maybe it is because the VIP address is retained in the HSRP protocol, but the IP address is in the port settings, HSRP does not run on any device. If it runs, it is not necessarily the active port. Instead, the IP address set on the port is always desirable and reliable, and the IP address is the most reliable.

Lab Note: Packet tracert cannot perform HSRP experiments. Only dynami or gns3 can be used.

The basic topology is as follows:

 

 

Note:

Hot Standby is performed on ports F0/0 of R1 and R2, and no hot standby is performed on the network where C3 is located.

R1, R2, and R3 require starting Routing

HSRP Port Configuration:

R1 (config-If) # interface fastethernet0/0

R1 (config-If) # IP address 192.168.1.2 255.255.255.0

R1 (config-If) # standby 1 ip address 192.168.1.1 this is VIP, that is, virtual IP, and the terminal gateway is this.

R1 (config-If) # standby 1 Priority 120 here indicates the priority. The higher the priority, the higher the 255 maximum.

R1 (config-If) # standby 1 preempt indicates whether to preemptible. A latency can be added later.

R1 (config-If) # standby 1 MAC-address without writing c07.ad01 will automatically generate Mac and write more clearly

 

The R2. configuration is similar. The priority can be reduced.

 

V Mac Generation Principle

A vmac address consists of three parts:

1> vendor ID: the first three bytes of the MAC address

2> HSRP code: 2 bytes, generally 07.ac, indicating that the address is HSRP router.

3> group ID: The last byte of the MAC address, which is the group number of HSRP.

 

 

IfNo Dynamic Routing ProtocolAfter the network topology on the left side changes, R3 still considers R1 as a route. Although R2 obtains the routing permission of 192.168.1.0, R3 does not know that the network segment 192.168.1.0 is now routed by R2, the package is still sent to R1, And the loop route is disconnected here.

Add a switch between R1, R2, and R3, and configure the R1 F0/1 R2 F0/1 and R3 F0/0 in the same network segment, and do the same R1, R2 F0/1 for a new set of Hot Standby, and R1, R2

F0/0

Standby 1 track F0/1 (here you can write down the priority value by 60 by default)

F0/1

Standby 1 track F0/0

This ensures that the priority of F0/1 is decreased by 60 when port F0/0 of R1 is down (by default, the priority can be decreased after the preceding command ), when the F0/0 port of R2 grabs the routing right of 192.168.1.1, the F0/1 of R2 can also obtain the routing right because the F0/1 permission of R1 is reduced, in this case, the network topology on the left side of R3 remains unchanged.

 

Refer:HSRP details

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.