hsrpvrrpglbp
MDstable
NoteSnippetChecklistPlaybook
HSRP, VRRP & GLBP — Redondance passerelle
Configurer FHRP : HSRP v2, VRRP, GLBP pour haute disponibilité des passerelles
snippetintermediate 2025-05-14 3 min read
hsrpvrrpglbpfhrpciscoredundancygatewaysvifailover
HSRP v2 — Hot Standby Router Protocol (Cisco)
text
Variables
{{SVI_OR_INTERFACE}}
{{GROUP}}
{{VIRTUAL_IP}}
{{UPLINK_INTERFACE}}
{{HSRP_KEY}}
interface {{SVI_OR_INTERFACE}}! Groupe HSRP avec IP virtuellestandby {{GROUP}} ip {{VIRTUAL_IP}}! Priorité (défaut 100) — le plus haut devient Activestandby {{GROUP}} priority 110! Reprendre le rôle Active dès que priorité redevient la plus hautestandby {{GROUP}} preemptstandby {{GROUP}} preempt delay minimum 30! Timers : hello 1s, hold 3s (défaut 3s/10s — réduire pour convergence rapide)standby {{GROUP}} timers 1 3! Tracking : si l'interface uplink tombe, décrémenter la prioritéstandby {{GROUP}} track {{UPLINK_INTERFACE}} decrement 20! Authentification MD5standby {{GROUP}} authentication md5 key-string {{HSRP_KEY}}! Version 2 obligatoire (IPv6 + groupes 0-4095)standby version 2
États HSRP
Initial Learn Listen Speak Standby Active
Initial processus HSRP dmarrantLearn en attente de lIP virtuelle pas encore reueListen connat lIP virtuelle ni Active ni StandbySpeak envoie des Hello participe llectionStandby backup surveille lActive prt prendre le relaiActive rpond lIP/MAC virtuelle achemine le trafic
Vérification HSRP
text
Variables
{{VLAN_ID}}
show standbyshow standby briefshow standby vlan {{VLAN_ID}}debug standby events
VRRP — Virtual Router Redundancy Protocol (RFC 5798)
text
Variables
{{SVI_OR_INTERFACE}}
{{GROUP}}
{{VIRTUAL_IP}}
{{VRRP_KEY}}
interface {{SVI_OR_INTERFACE}}vrrp {{GROUP}} ip {{VIRTUAL_IP}}vrrp {{GROUP}} priority 110vrrp {{GROUP}} preempt! Timer advertise en secondes (défaut 1s)vrrp {{GROUP}} timers advertise 1! Authentication (VRRP v3 ne supporte plus l'auth — utiliser IPSec si besoin)vrrp {{GROUP}} authentication {{VRRP_KEY}}
Vérification VRRP
text
Variables
{{INTERFACE}}
show vrrpshow vrrp briefshow vrrp interface {{INTERFACE}}
GLBP — Gateway Load Balancing Protocol (Cisco, actif-actif)
text
Variables
{{SVI_OR_INTERFACE}}
{{GROUP}}
{{VIRTUAL_IP}}
interface {{SVI_OR_INTERFACE}}glbp {{GROUP}} ip {{VIRTUAL_IP}}glbp {{GROUP}} priority 110glbp {{GROUP}} preempt! Algorithmes de load balancingglbp {{GROUP}} load-balancing round-robin! Alternatives : weighted | host-dependent! Weighting pour load balancing pondéréglbp {{GROUP}} weighting 110 lower 90 upper 105glbp {{GROUP}} weighting track 1 decrement 20! Timersglbp {{GROUP}} timers 1 3
Vérification GLBP
text
show glbpshow glbp briefshow glbp detail
Comparaison HSRP / VRRP / GLBP
Critre HSRP v2 VRRP RFC 5798 GLBPStandard Propritaire Cisco RFC 5798 ouvert Propritaire CiscoActif-actif Non 1 Active Non 1 Master Oui plusieurs AVFGroupes supports 0 4095 0 255 0 1023IPv6 Oui v2 Oui v3 OuiInteroprabilit Cisco uniquement Multi-vendor Cisco uniquementMAC virtuelle 0000fXXX 0000 0007b4XXXXYYRles Active Standby Master Backup AVG AVFCas dusage Standard Cisco Infra multi-vendor Max utilisation liens
💡 Tip —
Utiliser HSRP v2 et non v1 : la version 2 supporte IPv6, les groupes de 0 à 4095 (contre 0-255 en v1), et une meilleure précision des timers en millisecondes. Pour migrer sans interruption : configurer standby version 2 — les deux versions ne sont pas compatibles dans le même groupe, donc synchroniser les deux switchs simultanément.
OPS·BRAIN v1.027 notes · Networklocal