Some quick facts :

Protocol - 112; Multicast address 224.0.0.18; Preemption Enabled(by default);Priority=100 + highest IP; Timers 1/3.6;Only master sends hellos;

  • **During the re-election all members will send multicast packets with same virtual source MAC - switch may see port flapping in that moment. **
  • Can’t advertise less than a 1 second timer - because of 1 byte field which can be 0 or 1, timers needs to be set on each router locally if you want to have a lower than 1 sec.
  • You better set the timers equally otherwise you might have two master scenario

What problem does it solves ? :

-It’s designed to eliminate the single point of failure in a statically routed network.

In a nutshell - we are making one logical router of two physical ones.

VRRP elects a Master router that owns the virtual IP and MAC which hosts on the LAN use as gateway. If the Master fails, a new election takes place and the new Master continues routing. Each virtual router is identified by a VRID, the other routers are Backup routers.

RFC3768 describes this in details, but basically we have one virtual router with virtual ip and hosts which are using that virtual IP as a gateway, in case if one of the routers from VRRP instance will fail other will still be routing the packets.

In VRRP we have a Master/Backup routers, election process is based on highest IP or router priority.

Master router will be actively working on routing the packets while backup router should “keep the silence” and monitor the availability of master router(using keep alive messages).

What Backup router does while its in the Backup state: taken from RFC3768

While in this state, a VRRP router MUST do the following:

- MUST NOT respond to ARP requests for the IP address(s) associated
with the virtual router.

- MUST discard packets with a destination link layer MAC address
equal to the virtual router MAC address.

- MUST NOT accept packets addressed to the IP address(es) associated
with the virtual router.
In case of different events :

If a Shutdown event is received, then:

o Cancel the Master_Down_Timer
o Transition to the {Initialize} state

  • If the Master_Down_Timer fires, then:

o Send an ADVERTISEMENT
o Broadcast a gratuitous ARP request containing the virtual
router MAC address for each IP address associated with the
virtual router
o Set the Adver_Timer to Advertisement_Interval
o Transition to the {Master} state

  • If an ADVERTISEMENT is received, then:

o Set the Master_Down_Timer to Skew_Time

else:

If Preempt_Mode is False, or If the Priority in the
ADVERTISEMENT is greater than or equal to the local
Priority, then:

o Reset the Master_Down_Timer to Master_Down_Interval

else:

o Discard the ADVERTISEMENT
What master router does during :

While in the {Master} state the router functions as the forwarding
router for the IP address(es) associated with the virtual router.

While in this state, a VRRP router MUST do the following:

- MUST respond to ARP requests for the IP address(es) associated
with the virtual router.

- MUST forward packets with a destination link layer MAC address
equal to the virtual router MAC address.

- MUST NOT accept packets addressed to the IP address(es) associated
with the virtual router if it is not the IP address owner.

- MUST accept packets addressed to the IP address(es) associated
with the virtual router if it is the IP address owner.
Here is an example of VRRP config on Dell N-Series switches.

Configuring two instances for different sub-networks in vlan 50.

vrrp_example

On Cisco :

vrrp

In case if you are using Dell Force10 Switches, you can put the VRRP on top of VLT, this would allow you to have both VRRP MAC addresses populated in your LOCAL_DA Switch CAM-Table and allow the active-active routing instead of active-passive as it’s described in RFC.To check that MACs are being populated on both VLT peers you can use a command : **show cam mac stack-unit 0 port-set 0 | grep **vrrp_virtual_mac

Nice article about this can be found under this link.