---
title: VRRP Configuration
slug: enterprise-v5p2/_Y79-vrrp-configuration
description: reliability configuration
createdAt: 2025-11-14T03:58:40.850Z
---

### <font color="#1d50a2">show vrrp interface</font>

**\[Command]**
**show vrrp \[** *ID***] \[interface \{vlan&#x20;**&#x20;*vlan\_id***|ethernet&#x20;**&#x20;*interface\_num***|link-aggregation&#x20;**&#x20;*lag\_id***}]**
**show vrrp**

**\[Purpose]**
View detailed information about the VRRP backup group

**\[View]**
System view

**\[Use Cases]**

```plaintext
sonic# show vrrp 1
 Virtual Router ID                  1
 Protocol Version                   3
 Autoconfigured                     No
 Shutdown                           No
 Interface                          Vlan10
 VRRP interface (v4)                vrrp4-1-1
 VRRP interface (v6)                None
 Primary IP (v4)                    10.1.1.1
 Primary IP (v6)                    ::
 Virtual MAC (v4)                   00:00:5e:00:01:01
 Virtual MAC (v6)                   00:00:5e:00:02:01
 Status (v4)                        Master
 Status (v6)                        Initialize
 Priority                           100
 Effective Priority (v4)            100
 Effective Priority (v6)            100
 Preempt Mode                       Yes
 Accept Mode                        Yes
 Advertisement Interval             1500 ms
 Master Advertisement Interval (v4) 1500 ms
 Master Advertisement Interval (v6) 0 ms
 Advertisements Tx (v4)             2546
 Advertisements Tx (v6)             0
 Advertisements Rx (v4)             892
 Advertisements Rx (v6)             0
 Gratuitous ARP Tx (v4)             2
 Neigh. Adverts Tx (v6)             0
 State transitions (v4)             4
 State transitions (v6)             0
 Skew Time (v4)                     910 ms
 Skew Time (v6)                     0 ms
 Master Down Interval (v4)          5410 ms
 Master Down Interval (v6)          0 ms
 IPv4 Addresses                     1
 ..................................  10.1.1.11
 IPv6 Addresses                     0
```

### <font color="#1d50a2">show vrrp summary</font>

**\[Command]**
**show vrrp summary**

**\[Purpose]**
View VRRP backup group information

**\[View]**
System view

**\[Use Cases]**

```plaintext
sonic# show vrrp summary
Interface  VRID  Priority  IPv4  IPv6  State (v4)  State (v6)
 ----------------------------------------------------------------------
 Vlan10      1       150    1     1      Master    Master
 Vlan10      2       30     1     1      Backup    Backup
```

### <font color="#1d50a2">show vrrp default</font>

**\[Command]**
**show vrrp default**

**\[Purpose]**
View default configuration for VRRP backup group

**\[View]**
System view

**\[Use Cases]**

```plaintext
sonic# show vrrp default
advertisement-interval  Preempt mode  Priority  shutdown
 --------------------------------------------------------------
 1000           true      100    false
```

### <font color="#1d50a2">vrrp</font>

**\[Command]**
**vrrp&#x20;**&#x20;*vrrp\_ID* **\[version&#x20;**&#x20;*version\_ID*]&#x20;

**\[Purpose]**
Create a VRRP backup group and specify the VRRP version.

**\[View]**
Interface view

**\[Parameter]**

| **Parameter** | **Description**              |
| ------------- | ---------------------------- |
| *vrrp\_ID*    | The range of value is: 1-255 |
| *version\_ID* | The default value is 3       |

**\[Use Cases]**

```plaintext
sonic(config)# interface ethernet 1
sonic(config-if-1)# vrrp 1 version 2
```

### <font color="#1d50a2">vrrp priority</font>

**\[Command]**
**vrrp&#x20;**&#x20;*ID* **priority&#x20;**&#x20;*value*

**\[Purpose]**
Configure the priority of the device in the VRRP backup group

**\[View]**
Interface view

**\[Parameter]**

| **Parameter** | **Description**                                                                                  |
| ------------- | ------------------------------------------------------------------------------------------------ |
| *value*       | The range of value is: 1-254, the default value is:100. Higher numbers indicate higher priority. |

**\[Use Cases]**

```plaintext
sonic(config)# interface ethernet 1
sonic(config-if-1)# vrrp 1 priority 20
```

### <font color="#1d50a2">vrrp advertisement-interval</font>

**\[Command]**
**vrrp&#x20;**&#x20;*ID* **advertisement-interval&#x20;**&#x20;*value*

**\[Purpose]**
Configure the interval for sending VRRP advertisement packets

**\[View]**
Interface view

**\[Parameter]**

| **Parameter** | **Description**                                                                 |
| ------------- | ------------------------------------------------------------------------------- |
| *value*       | "The range is from 10 to 40950 milliseconds, default value is 1000 milliseconds |

**\[Usage Scenario]**
The master device periodically sends VRRP advertisement packets to the backup devices within the group to notify them of its normal operation. If a backup device does not receive VRRP advertisement packets even after the Master\_Down\_Interval timer expires, a new master will be elected.
When the master device voluntarily relinquishes its master status (such as when it leaves the backup group), it sends an advertisement packet with a priority of 0. This triggers a fast transition of the backup device to become the master, without waiting for the Master\_Down\_Interval timer to expire. The time taken for this transition is known as the Skew time, calculated as (256 - priority of the backup device) / 256, in centiseconds.
When the master device encounters a network failure and cannot send advertisement packets, the backup device cannot immediately determine its working status. Only after the Master\_Down\_Interval timer expires will the backup device consider the master device as unable to function normally and switch its status to master. The Master\_Down\_Interval timer is set to 3×Advertisement\_Interval + Skew\_time, in centiseconds.

**\[Use Cases]**

```plaintext
sonic(config)# interface ethernet 1
sonic(config-if-1)# vrrp 1 advertisement-interval 2500
```

### <font color="#1d50a2">vrrp ip *A.B.C.D*</font>

**\[Command]**
**vrrp ip&#x20;**&#x20;*A.B.C.D*

**\[Purpose]**
Create a VRRP backup group and assign a virtual IP address to the backup group

**\[View]**
Interface view

**\[Usage Scenario]**
VRRP allows multiple devices to form a virtual switch without changing the network topology. By configuring the virtual switch as the gateway, it provides gateway redundancy

**\[Use Cases]**

```plaintext
sonic(config)# interface ethernet 1
sonic(config-if-1)# vrrp 1 ip 192.168.0.1
```

### <font color="#1d50a2">vrrp ip send-gratuitous-arp interval</font>

**\[Command]**
**vrrp ip send-gratuitous-arp interval&#x20;**&#x20;*value*

**\[Purpose]**
Configure the interval for Master to send gratuitous ARP packets

**\[Parameter]**

| **Parameter** | **Description**                      |
| ------------- | ------------------------------------ |
| *value*       | Interval,The range is from 10 to 600 |

**\[View]**
System view

**\[Usage Scenario]**
In a VRRP backup group, to ensure the MAC table entries on downstream switches are correct, the Master device periodically sends gratuitous ARP packets to refresh the MAC address table entries on the downstream switches

**\[Use Cases]**

```plaintext
sonic(config)# vrrp ip send-gratuitous-arp interval 150
```

### <font color="#1d50a2">vrrp preempt</font>

**\[Command]**
**vrrp** *ID* **preempt**

**\[Purpose]**
Configure the switch in VRRP backup group with preempt mode

**\[Parameter]**

| **Parameter** | **Description**            |
| ------------- | -------------------------- |
| *ID*          | The range is from 1 to 255 |

**\[View]**
VLAN view

**\[Usage Scenario]**
In an unstable network, the backup device may not always receive VRRP packets promptly, causing frequent VRRP state changes and network oscillations. To enhance the stability of the active/standby state, the user configures the switch in VRRP backup group with preempt mode

**\[Use Cases]**

```plaintext
sonic(config-vlanif-10)# vrrp 1 preempt
```

### <font color="#1d50a2">vrrp shutdown</font>

**\[Command]**
**vrrp shutdown**

**\[Purpose]**
Configure the criteria for this backup group to withdraw from the VRRP election

**\[View]**
Interface view

**\[Usage Scenario]**
Configure the criteria for this backup group to withdraw from the VRRP election and set the interface's VRRP state to 'initial'.

**\[Use Cases]**

```plaintext
sonic(config)# interface ethernet 1
sonic(config-if-1)# vrrp shutdown
```

### <font color="#1d50a2">vrrp default</font>

**\[Command]**
**vrrp default \{advertisement-interval \*\* *interval***|preempt|priotiry \*\* *value***|shutdown}**

**\[Purpose]**
Configure default values for VRRP parameters

**\[View]**
System configuration view

**\[Usage Scenario]**
In the system configuration view, configure default information for VRRP backup groups. Once configured, all backup groups can use this configuration as default. If a backup group specifies specific parameters, those will take precedence over the default configuration.

**\[Use Cases]**

```plaintext
sonic(config)# vrrp default priotiry 10
```

##

