📜  HSRP、VRRP、GLBP 协议

📅  最后修改于: 2022-05-13 01:57:02.619000             🧑  作者: Mango

HSRP、VRRP、GLBP 协议

HSRP、VRRP 和 GLBP 都是第一跳冗余协议和网络层协议,用于在网络中提供冗余。它们的主要目的是为 LAN 环境中的默认网关提供冗余。

热备路由器协议 (HSRP)是一种 CISCO 专有协议,它提供了一种机制,旨在为特殊情况下的 IP 流量的无中断故障转移提供支持。在 HSRP 中,两个或更多路由器给人一种虚拟路由器的错觉。 HSRP 允许您一次将两台或多台路由器配置为备用路由器,而一次仅将一台路由器配置为活动路由器。单个 HSRP 组中的每个路由器共享一个 MAC 地址和 IP 地址,为本地网络提供默认网关。活动路由器负责转发流量。如果它发生故障,备用路由器会弥补它承担活动路由器的所有责任并转发流量。

虚拟路由器冗余协议 (VRRP) VRRP 是一种开放标准的 IEEE 协议,它在网络中提供冗余。它消除了静态默认路由环境固有的单点故障。它是一种网络层协议,协议号为 112。组中的路由器数量充当虚拟逻辑路由器,充当所有本地主机的默认网关。如果任何路由器出现故障,其他组成员可以承担转发流量的责任。

网关负载平衡协议 (GLBP) 网关负载平衡协议 (GLBP) 是一种 Cisco 专有协议,它是 FHRP 之一,除了提供与其他协议一样的冗余之外,它还提供负载平衡。它可以使用单个虚拟 IP 地址和多个虚拟 Mac 地址在多个路由器上执行负载平衡等功能。

主要区别之一是 VRRP 是行业标准,而 HSRP 和 GLBP 是 Cisco 专有协议。 VRRP 和 HSRP 将自身分布在单个第 3 层以太网交换机或路由器上,成为组中的活动路由器,而 GLBP 通过配置负载平衡方案可以定位多达四个路由器。

最好的选择实际上取决于您可以使用的设备类型、网络设计的复杂性,或者有时是个人喜好。

以下是 VRRP、HSRP 和 GLBP 之间的比较表:

Basis of Comparison

VRRP

HSRP

GLBP

Standard  Open IEEE StandardCisco’s Proprietary ProtocolCisco’s Proprietary Protocol
First Hop Redundancy Protocol FHRPFHRPFHRP
Timers 

Default Hello – 1 Sec

Hold Time – counted automatically and can’t be configured.

Default Hold/Dead Time – 10 Secs 

Default Hello – 3 Secs

Default Hold/DeadTime – 10 Secs
RFC   57982281No RFC
IPv6No support for IPv6 on the original VRRP, VRRPv3 now supports it.Supports IPv6Supports IPv6
Virtual IPVirtual IP could be the same as physical IPConfigure separate IP for the Virtual.Configure separate IP for the Virtual.
Preemption Enabled by defaultNot enabled by default  It is not enabled by default for AVGs.
Router Roles  It follows the concept of master and backup router  rolesIts router roles are – Active and Standby GLBPRouter roles like – AVG, AVF and AVS
Load Balancing Not Supported – Sharing can be done by configuring  single subnet/Interface of multiple groups.Load Balancing not Supported – Sharing can be done for the cause .Load Balancing Supported -3 Load Balancing Schemes  like Round-Robin (Default), Weighted, and Host-Dependent
Virtual MAC Address  0000.5e00.01xx – here XX is the VRRP group number in hex  0000.0c07.acXX – here XX is the HSRP group number in HEX0007.b4XX.XXYY here XX.XX = 6 zero bits(empty) and 10 bits for the Group number.
Sample Configuration

> ip address ip-address mask

> vrrp group-description text

> standby-[group]-ip {virtual-ip}

> standby-[group]-timers {hello}

> glbp-group-ip [ip-address [secondary]

> glbp-group timers [nsec ]hellotime [nsec ] holdtime