3 namespace "http://frrouting.org/yang/vrrpd";
6 import ietf-inet-types {
10 import ietf-yang-types {
14 import frr-interface {
21 "FRR Users List: <mailto:frog@lists.frrouting.org>
22 FRR Development List: <mailto:dev@lists.frrouting.org>";
24 "This module defines a model for managing FRR vrrpd daemon.
26 Copyright 2020 FRRouting
28 Redistribution and use in source and binary forms, with or without
29 modification, are permitted provided that the following conditions
32 1. Redistributions of source code must retain the above copyright notice,
33 this list of conditions and the following disclaimer.
35 2. Redistributions in binary form must reproduce the above copyright
36 notice, this list of conditions and the following disclaimer in the
37 documentation and/or other materials provided with the distribution.
39 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
40 \"AS IS\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
41 LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
42 A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
43 HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
44 SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
45 LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
46 DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
47 THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
48 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
49 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.";
56 grouping ip-vrrp-config {
58 "Configuration data for VRRP on IP interfaces";
59 leaf virtual-router-id {
64 "Set the virtual router id for use by the VRRP group. This
65 usually also determines the virtual MAC address that is
66 generated for the VRRP group";
91 "Specifies the sending VRRP interface's priority
92 for the virtual router. Higher values equal higher
100 "When set to true, enables preemption by a higher
101 priority backup router of a lower priority master router";
108 "Configure whether packets destined for
109 virtual addresses are accepted even when the virtual
110 address is not owned by the router interface";
113 leaf advertisement-interval {
117 units "centiseconds";
120 "Sets the interval between successive VRRP
121 advertisements -- RFC 5798 defines this as a 12-bit
122 value expressed as 0.1 seconds, with default 100, i.e.,
123 1 second. Several implementation express this in units of
131 "Administrative shutdown for this VRRP group.";
135 grouping ip-vrrp-state {
137 "Grouping for operational state data for a virtual router";
138 leaf current-priority {
142 "Operational value of the priority for the
143 interface in the VRRP group.";
146 leaf vrrp-interface {
147 type frr-interface:interface-ref;
150 "The interface used to transmit VRRP traffic.";
153 leaf source-address {
154 type inet:ip-address;
157 "The source IP address used for VRRP advertisements.";
164 "State when virtual router is waiting for a Startup event.";
168 "State when virtual router is functioning as the forwarding router
169 for the virtual addresses.";
173 "State when virtual router is monitoring the availability and state
174 of the Master router.";
180 leaf master-advertisement-interval {
184 units "centiseconds";
187 "Advertisement interval contained in advertisements received from the Master.";
192 units "centiseconds";
195 "Time to skew Master_Down_Interval.";
200 leaf state-transition {
201 type yang:zero-based-counter32;
203 "Number of state transitions the virtual router has experienced.";
208 type yang:zero-based-counter32;
210 "Number of sent VRRP advertisements.";
216 type yang:zero-based-counter32;
218 "Number of received VRRP advertisements.";
224 grouping ip-vrrp-top {
226 "Top-level grouping for Virtual Router Redundancy Protocol";
229 "Enclosing container for VRRP groups handled by this
232 "RFC 5798 - Virtual Router Redundancy Protocol
233 (VRRP) Version 3 for IPv4 and IPv6";
235 key "virtual-router-id";
237 "List of VRRP groups, keyed by virtual router id";
241 leaf-list virtual-address {
242 type inet:ipv4-address;
244 "Configure one or more IPv4 virtual addresses for the
249 augment "./counter/tx" {
250 leaf gratuitous-arp {
251 type yang:zero-based-counter32;
253 "Number of sent gratuitous ARP requests.";
260 when "../version = 3";
261 leaf-list virtual-address {
262 type inet:ipv6-address;
264 "Configure one or more IPv6 virtual addresses for the
269 augment "./counter/tx" {
270 leaf neighbor-advertisement {
271 type yang:zero-based-counter32;
273 "Number of sent unsolicited Neighbor Advertisements.";
282 augment "/frr-interface:lib/frr-interface:interface" {