The Virtual Router Redundancy Protocol (VRRP) is a computer
networking protocol that provides for automatic assignment of available
Internet Protocol
The Internet Protocol (IP) is the network layer communications protocol in the Internet protocol suite for relaying datagrams across network boundaries. Its routing function enables internetworking, and essentially establishes the Internet.
IP ...
(IP) routers to participating
hosts. This increases the availability and reliability of
routing
Routing is the process of selecting a path for traffic in a Network theory, network or between or across multiple networks. Broadly, routing is performed in many types of networks, including circuit-switched networks, such as the public switched ...
paths via automatic
default gateway
A default gateway is the node in a computer network using the Internet protocol suite that serves as the forwarding host ( router) to other networks when no other route specification matches the destination IP address of a packet.
Role
A gatew ...
selections on an IP
subnetwork
A subnet, or subnetwork, is a logical subdivision of an IP network. Updated by RFC 6918. The practice of dividing a network into two or more networks is called subnetting.
Computers that belong to the same subnet are addressed with an identic ...
.
The protocol achieves this by the creation of virtual routers, which are an abstract representation of multiple routers, i.e. primary/active and secondary/Standby
routers, acting as a group. The virtual router is assigned to act as a default gateway of participating hosts, instead of a physical router. If the physical router that is routing packets on behalf of the virtual router fails, another physical router is selected to automatically replace it. The physical router that is forwarding
packets at any given time is called the primary/active router.
VRRP provides information on the state of a router, not the routes processed and exchanged by that router. Each VRRP instance is limited, in scope, to a single subnet. It does not advertise IP routes beyond that subnet or affect the routing table in any way. VRRP can be used in
Ethernet
Ethernet ( ) is a family of wired computer networking technologies commonly used in local area networks (LAN), metropolitan area networks (MAN) and wide area networks (WAN). It was commercially introduced in 1980 and first standardized in 198 ...
,
MPLS and
Token Ring networks with
Internet Protocol Version 4 (IPv4), as well as
IPv6
Internet Protocol version 6 (IPv6) is the most recent version of the Internet Protocol (IP), the communication protocol, communications protocol that provides an identification and location system for computers on networks and routes traffic ...
.
Implementation
A virtual router must use as its
media access control
In IEEE 802 LAN/MAN standards, the medium access control (MAC), also called media access control, is the layer that controls the hardware responsible for interaction with the wired (electrical or optical) or wireless transmission medium. Th ...
(MAC) address. The last byte of the address (XX) is the virtual router identifier (VRID), which is different for each virtual router in the network. This address is used by only one physical router at a time, and it will reply with this
MAC address when an
ARP request is sent for the virtual router's IP address.
Physical routers within the virtual router must communicate within themselves using packets with
multicast IP address and
IP protocol number 112 for IPv4, or and IP protocol number 112 for IPv6.
Routers backing up a virtual router have a priority between 1 and 254, and the router with the highest priority will become the primary/active. The default priority is 100; for the MAC address owner, the priority is always 255.
Elections of primary/active routers
A failure to receive a multicast packet from the primary/active router for a period longer than three times the advertisement timer causes the secondary/standby routers to assume that the primary/active router is dead. The virtual router then transitions into an unsteady state and an election process is initiated to select the next primary/active router from the secondary/standby routers. This is fulfilled through the use of multicast packets.
Secondary/standby router(s) are only supposed to send multicast packets during an election process. One exception to this rule is when a physical router is configured with a higher priority than the current primary/active, which means that on connection to the network it will pre-empt the primary/active status. This allows a system administrator to force a physical router to the primary/active state immediately after
booting
In computing, booting is the process of starting a computer as initiated via Computer hardware, hardware such as a physical button on the computer or by a software command. After it is switched on, a computer's central processing unit (CPU) h ...
, for example when that particular router is more powerful than others within the virtual router. The secondary/standby router with the highest priority becomes the primary/active router by raising its priority above that of the current primary/active. It will then take responsibility for routing packets sent to the virtual gateway's MAC address. In cases where secondary/standby routers all have the same priority, the secondary/standby router with the highest IP address becomes the primary/active router.
All physical routers acting as a virtual router must be in the same
local area network
A local area network (LAN) is a computer network that interconnects computers within a limited area such as a residence, campus, or building, and has its network equipment and interconnects locally managed. LANs facilitate the distribution of da ...
(LAN) segment. Communication within the virtual router takes place periodically. This period can be adjusted by changing advertisement interval timers. The shorter the advertisement interval, the shorter the
black hole
A black hole is a massive, compact astronomical object so dense that its gravity prevents anything from escaping, even light. Albert Einstein's theory of general relativity predicts that a sufficiently compact mass will form a black hole. Th ...
period, though at the expense of more traffic in the network. Security is achieved by responding only to first
hop packets, though other mechanisms are provided to reinforce this, particularly against local attacks. The election process is made orderly through the use of
skew time, derived from a router's priority, and used to reduce the chance of the
thundering herd problem occurring during the election. The skew time is given by the formula (expressed in milliseconds).
Secondary/standby router utilization can be improved by load sharing.
History
Work on VRRP started in 1997 with a first draft published by the
Internet Engineering Task Force
The Internet Engineering Task Force (IETF) is a standards organization for the Internet standard, Internet and is responsible for the technical standards that make up the Internet protocol suite (TCP/IP). It has no formal membership roster ...
(IETF). In 1998, the protocol was officially defined.
VRRP is an open standard, but
Cisco
Cisco Systems, Inc. (using the trademark Cisco) is an American multinational digital communications technology conglomerate corporation headquartered in San Jose, California. Cisco develops, manufactures, and sells networking hardware, s ...
claimed that their
Hot Standby Router Protocol, a similar but
proprietary protocol with essentially the same facility, is patented and licensed.
However, in 2001, in reply to a direct request, Robert Barr of Cisco replied that they will not assert any patent claims unless someone tried to assert a claim against Cisco.
IBM
International Business Machines Corporation (using the trademark IBM), nicknamed Big Blue, is an American Multinational corporation, multinational technology company headquartered in Armonk, New York, and present in over 175 countries. It is ...
also claims covering patents and their statement is readable on the IETF webpage.
All patents in question have expired.
The protocol was refined in 2004 as version 2. VRRP version 3, the current version, was published in 2010.
Derivatives
Mellanox offers MAGP, a proprietary protocol based on VRRP that allows active-active operation.
Foundry Networks developed VRRP-E(Extended), a proprietary version of VRRP that avoids a few limitations of RFC 3768
See also
* Common Address Redundancy Protocol (CARP) – a non-proprietary, patent-free, and unrestricted alternative to HSRP and VRRP
* Gateway Load Balancing Protocol – a Cisco Systems
Cisco Systems, Inc. (using the trademark Cisco) is an American multinational corporation, multinational digital communications technology conglomerate (company), conglomerate corporation headquartered in San Jose, California. Cisco develops, m ...
proprietary router redundancy protocol providing load balancing
* Hot Standby Routing Protocol – a Cisco Systems proprietary router redundancy protocol
* First Hop Redundancy Protocols – Lists of default gateway redundancy protocols
* RSMLT
References
External links
* {{cite web , url = http://www.ietf.org/mail-archive/web/vrrp/current/maillist.html , title = The IETF VRRP mailing list archive
Internet protocols
Routing protocols
First-hop redundancy protocols