Explanation:

  • vrrp_instance: a virtual router
  • state: master or backup
  • priority: higher priority means that router gets chosen more often
  • authentication:
    • auth_type: can integrate with other ticket based authentication protocols
    • auth_pass: IPv4 sub 8 character passwords, IPv6 allows for longer passwords
  • virtual_ipaddress: the shared IP ranges for the virtual router (can be more than one)

Setup Examples

  • Manager:
vrrp_instance VI_1 {
        state MASTER
        interface eth0
        virtual_router_id 51
        priority 10
        advert_int 1
        authentication {
                auth_type AH
                auth_pass adguard
        }
        virtual_ipaddress {
                10.133.7.11/24
        }
}
vrrp_instance VI_2 {
        state MASTER
        interface eth0
        virtual_router_id 52
        priority 10
        advert_int 1
        authentication {
                auth_type PASS
                auth_pass adgaurdhome
        }
        virtual_ipaddress {
	       fd48:fb0a:cb3a:b8d4::1234/64
        }
}
  • Backup:
vrrp_instance VI_1 {
	state BACKUP
	interface eth0
     virtual_router_id 51
     priority 1
     advert_int 1
     authentication {
         auth_type AH
         auth_pass adguard
     }
     virtual_ipaddress {
         10.133.7.11/24
     }
}
 vrrp_instance VI_2 {
     state BACKUP
     interface eth0
     virtual_router_id 52
     priority 1
     advert_int 1
     authentication {
         auth_type PASS
         auth_pass adgaurdhome
     }       
     virtual_ipaddress {
         fd48:fb0a:cb3a:b8d4::1234/64
     }
}

Notes:

  • Separate setup for IPv4 and IPv6 addresses
  • Can have multiple setup for different interfaces

References: