draft-ietf-rtgwg-yang-vrrp-01.txt   draft-ietf-rtgwg-yang-vrrp-02.txt 
Network Working Group X. Liu, Editor
Internet-Draft A. Kyparlis
Intended status: Standards Track Kuatro Technologies
Expires: June 1, 2017 R. Parikh
VMware
A. Lindem
Cisco Systems
M. Zhang
Huawei Technologies
December 1, 2016
A YANG Data Model for Virtual Router Redundancy Protocol (VRRP) Network Working Group X. Liu, Ed.
draft-ietf-rtgwg-yang-vrrp-01 Internet-Draft A. Kyparlis
Intended status: Standards Track Jabil
Expires: September 11, 2017 R. Parikh
VMware
A. Lindem
Cisco Systems
M. Zhang
Huawei Technologies
March 10, 2017
A YANG Data Model for Virtual Router Redundancy Protocol (VRRP)
draft-ietf-rtgwg-yang-vrrp-02
Abstract Abstract
This document describes a data model for Virtual Router Redundancy This document describes a data model for Virtual Router Redundancy
Protocol (VRRP). Both version 2 and version 3 of VRRP are covered. Protocol (VRRP). Both version 2 and version 3 of VRRP are covered.
Status of this Memo Status of This Memo
This Internet-Draft is submitted in full conformance with the This Internet-Draft is submitted in full conformance with the
provisions of BCP 78 and BCP 79. provisions of BCP 78 and BCP 79.
Internet-Drafts are working documents of the Internet Engineering Internet-Drafts are working documents of the Internet Engineering
Task Force (IETF), its areas, and its working groups. Note that Task Force (IETF). Note that other groups may also distribute
other groups may also distribute working documents as Internet- working documents as Internet-Drafts. The list of current Internet-
Drafts. Drafts is at http://datatracker.ietf.org/drafts/current/.
Internet-Drafts are draft documents valid for a maximum of six months Internet-Drafts are draft documents valid for a maximum of six months
and may be updated, replaced, or obsoleted by other documents at any and may be updated, replaced, or obsoleted by other documents at any
time. It is inappropriate to use Internet-Drafts as reference time. It is inappropriate to use Internet-Drafts as reference
material or to cite them other than as "work in progress." material or to cite them other than as "work in progress."
The list of current Internet-Drafts can be accessed at This Internet-Draft will expire on September 11, 2017.
http://www.ietf.org/ietf/1id-abstracts.txt
The list of Internet-Draft Shadow Directories can be accessed at
http://www.ietf.org/shadow.html
This Internet-Draft will expire on June 1, 2017.
Copyright Notice Copyright Notice
Copyright (c) 2016 IETF Trust and the persons identified as the Copyright (c) 2017 IETF Trust and the persons identified as the
document authors. All rights reserved. document authors. All rights reserved.
This document is subject to BCP 78 and the IETF Trust's Legal This document is subject to BCP 78 and the IETF Trust's Legal
Provisions Relating to IETF Documents Provisions Relating to IETF Documents
(http://trustee.ietf.org/license-info) in effect on the date of (http://trustee.ietf.org/license-info) in effect on the date of
publication of this document. Please review these documents publication of this document. Please review these documents
carefully, as they describe your rights and restrictions with respect carefully, as they describe your rights and restrictions with respect
to this document. Code Components extracted from this document must to this document. Code Components extracted from this document must
include Simplified BSD License text as described in Section 4.e of include Simplified BSD License text as described in Section 4.e of
the Trust Legal Provisions and are provided without warranty as the Trust Legal Provisions and are provided without warranty as
described in the Simplified BSD License. described in the Simplified BSD License.
Table of Contents Table of Contents
1. Introduction...................................................2 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2
1.1. Terminology...............................................2 1.1. Terminology . . . . . . . . . . . . . . . . . . . . . . . 2
2. VRRP YANG model overview.......................................3 1.2. Tree Diagrams . . . . . . . . . . . . . . . . . . . . . . 3
3. VRRP YANG module...............................................7 1.3. Prefixes in Data Node Names . . . . . . . . . . . . . . . 3
4. IANA Considerations...........................................29 2. Design of the Data Model . . . . . . . . . . . . . . . . . . 4
5. Security Considerations.......................................29 2.1. Scope of the Model . . . . . . . . . . . . . . . . . . . 4
6. References....................................................30 2.2. Relations with Interface Model and IP Model . . . . . . . 4
6.1. Normative References.....................................30 2.3. Protocol Configuration . . . . . . . . . . . . . . . . . 5
6.2. Informative References...................................30 2.4. Protocol States . . . . . . . . . . . . . . . . . . . . . 6
2.5. Notifications . . . . . . . . . . . . . . . . . . . . . . 7
3. Tree Structure . . . . . . . . . . . . . . . . . . . . . . . 8
4. YANG Module . . . . . . . . . . . . . . . . . . . . . . . . . 11
5. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 33
6. Security Considerations . . . . . . . . . . . . . . . . . . . 34
7. References . . . . . . . . . . . . . . . . . . . . . . . . . 34
7.1. Normative References . . . . . . . . . . . . . . . . . . 34
7.2. Informative References . . . . . . . . . . . . . . . . . 35
Appendix A. Data Tree Example . . . . . . . . . . . . . . . . . 37
Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 39
1. Introduction 1. Introduction
This document introduces a YANG [RFC6020] data model for Virtual This document introduces a YANG [RFC6020][RFC7950] data model for
Router Redundancy Protocol (VRRP) [RFC3768][RFC5798]. VRRP provides Virtual Router Redundancy Protocol (VRRP) [RFC3768][RFC5798]. VRRP
higher resiliency by specifying an election protocol that dynamically provides higher resiliency by specifying an election protocol that
assigns responsibility for a virtual router to one of the VRRP dynamically assigns responsibility for a virtual router to one of the
routers on a LAN. VRRP routers on a LAN.
This YANG model supports both version 2 and version 3 of VRRP. VRRP This YANG model supports both version 2 and version 3 of VRRP. VRRP
version 2 defined in [RFC3768] supports IPv4. VRRP version 3 defined version 2 defined in [RFC3768] supports IPv4. VRRP version 3 defined
in [RFC5798] supports both IPv4 and IPv6. in [RFC5798] supports both IPv4 and IPv6.
1.1. Terminology 1.1. Terminology
The keywords "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", The keywords "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and
"OPTIONAL" in this document are to be interpreted as described in BCP "OPTIONAL" in this document are to be interpreted as described in BCP
14, [RFC2119]. 14, [RFC2119].
The following terms are defined in [RFC6020] and are not redefined The following terms are defined in [RFC7950] and are not redefined
here: here:
o augment o augment
o data model o data model
o data node o data node
2. VRRP YANG model overview 1.2. Tree Diagrams
A simplified graphical representation of the data model is used in
this document. The meaning of the symbols in these diagrams is as
follows:
o Brackets "[" and "]" enclose list keys.
o Curly braces "{" and "}" contain names of optional features that
make the corresponding node conditional.
o Abbreviations before data node names: "rw" means configuration
(read-write), and "ro" means state data (read-only).
o Symbols after data node names: "?" means an optional node, "!"
means a presence container, and "*" denotes a list and leaf-list.
o Parentheses enclose choice and case nodes, and case nodes are also
marked with a colon (":").
o Ellipsis ("...") stands for contents of subtrees that are not
shown.
1.3. Prefixes in Data Node Names
In this document, names of data nodes, actions, and other data model
objects are often used without a prefix, as long as it is clear from
the context in which YANG module each name is defined. Otherwise,
names are prefixed using the standard prefix associated with the
corresponding YANG module, as shown in Table 1.
+--------+-----------------+-----------+
| Prefix | YANG module | Reference |
+--------+-----------------+-----------+
| yang | ietf-yang-types | [RFC6991] |
| inet | ietf-inet-types | [RFC6991] |
| if | ietf-interfaces | [RFC7223] |
| ip | ietf-ip | [RFC7277] |
+--------+-----------------+-----------+
Table 1: Prefixes and Corresponding YANG Modules
2. Design of the Data Model
2.1. Scope of the Model
The model covers VRRP version 2 [RFC3768] and VRRP version 3
[RFC5798] protocols. The model is designed to be implemented on a
device where VRRP version 2 or version 3 is implemented. With the
help of a proper management protocol, the defined model can be used
to:
o Configure the VRRP version 2 or version 3 protocol.
o Manage the protocol operational behavior.
o Retrieve the protocol operational status.
o Receive the protocol notifications.
2.2. Relations with Interface Model and IP Model
This model augments the interface data model "ietf-interfaces"
[RFC7223] and IP management model "ietf-ip" [RFC7277]. The
augmentation relations are shown as follows:
ietf-interfaces ietf-ip ietf-vrrp
=========================================================
+--rw interfaces
| +--rw interface*
| +--------------rw ipv4
| | +---------------rw vrrp
| | +--rw vrrp-instance*
| +--------------rw ipv6
| +---------------rw vrrp
| +--rw vrrp-instance*
+--ro interfaces-state
+--ro interface*
| +--------------ro ipv4
| | +---------------ro vrrp
| | +--ro vrrp-instance*
| +--------------ro ipv6
| +---------------ro vrrp
| +--ro vrrp-instance*
+---------------------------------ro vrrp-global
The "vrrp" container contains a list of vrrp-instance nodes, which
are instantiated under an interface for a specified address family
(IPv4 or IPv6).
2.3. Protocol Configuration
The model structure for the protocol configuration is as shown below:
augment /if:interfaces/if:interface/ip:ipv4:
+--rw vrrp
+--rw vrrp-instance* [vrid]
+--rw vrid uint8
| ...
+--rw track
| +--rw interfaces
| | +--rw interface* [interface]
| | +--rw interface if:interface-ref
| | ...
| +--rw networks
| +--rw network* [prefix]
| +--rw prefix inet:ipv4-prefix
| ...
+--rw virtual-ipv4-addresses
+--rw virtual-ipv4-address* [ipv4-address]
+--rw ipv4-address inet:ipv4-address
augment /if:interfaces/if:interface/ip:ipv6:
+--rw vrrp
+--rw vrrp-instance* [vrid]
+--rw vrid uint8
| ...
+--rw track
| +--rw interfaces
| | +--rw interface* [interface]
| | +--rw interface if:interface-ref
| | ...
| +--rw networks
| +--rw network* [prefix]
| +--rw prefix inet:ipv6-prefix
| ...
+--rw virtual-ipv6-addresses
+--rw virtual-ipv6-address* [ipv6-address]
+--rw ipv6-address inet:ipv6-address
The model allows to configure the following protocol entities:
o VRRP instance (version 2 or version 3).
o Virtual IPv4 or IPv6 address.
o Tracking interface.
o Tracking network.
2.4. Protocol States
The model structure for the protocol states is as shown below:
augment /if:interfaces-state/if:interface/ip:ipv4:
+--ro vrrp
+--ro vrrp-instance* [vrid]
+--ro vrid uint8
| ...
+--ro track
| +--ro interfaces
| | +--ro interface* [interface]
| | +--ro interface if:interface-ref
| | ...
| +--ro networks
| +--ro network* [prefix]
| +--ro prefix inet:ipv4-prefix
| ...
+--ro virtual-ipv4-addresses
| +--ro virtual-ipv4-address* [ipv4-address]
| +--ro ipv4-address inet:ipv4-address
|
+--ro <per instance operational states>
+--ro statistics
+--ro <per instance statistics>
augment /if:interfaces-state/if:interface/ip:ipv6:
+--ro vrrp
+--ro vrrp-instance* [vrid]
+--ro vrid uint8
+ ...
+--ro track
| +--ro interfaces
| | +--ro interface* [interface]
| | +--ro interface if:interface-ref
| | ...
| +--ro networks
| +--ro network* [prefix]
| +--ro prefix inet:ipv6-prefix
| ...
+--ro virtual-ipv6-addresses
| +--ro virtual-ipv6-address* [ipv6-address]
| +--ro ipv6-address inet:ipv6-address
|
+--ro <per instance operational states>
+--ro statistics
+--ro <per instance statistics>
augment /if:interfaces-state:
+--ro vrrp-global
+--ro <global operational states>
+--ro statistics
+--ro <global statistics>
The model allows to retrieve protocol states at the following levels:
o VRRP instance (version 2 or version 3).
o Virtual IPv4 or IPv6 address.
o Tracking interface.
o Tracking network.
o Global states and statistics summarizing all instances.
2.5. Notifications
This model defines the following VRRP specific notifications:
o VRRP new master event.
o VRRP protocol error event for a message that fails to reach a VRRP
instance to be processed.
o VRRP virtual router error event for a message processed on a VRRP
instance.
In addition to the notifications specified above, the mechanism
defined in [I-D.ietf-netconf-yang-push] and
[I-D.ietf-netconf-rfc5277bis] can be used for other general
notifications. This mechanism currently allows the user to:
o Subscribe notifications on a per client basis.
o Specify subtree filters or xpath filters so that only interested
contents will be sent.
o Specify either periodic or on-demand notifications.
3. Tree Structure
This document defines the YANG module "ietf-vrrp", which has the This document defines the YANG module "ietf-vrrp", which has the
following structure: following tree structure:
module: ietf-vrrp module: ietf-vrrp
augment /if:interfaces/if:interface/ip:ipv4: augment /if:interfaces/if:interface/ip:ipv4:
+--rw vrrp +--rw vrrp
+--rw vrrp-instance* [vrid] +--rw vrrp-instance* [vrid]
+--rw vrid uint8 +--rw vrid uint8
+--rw version? enumeration +--rw version identityref
+--rw log-state-change? boolean +--rw log-state-change? boolean
+--rw preempt! +--rw preempt
| +--rw enabled? boolean
| +--rw hold-time? uint16 | +--rw hold-time? uint16
+--rw priority? uint8 +--rw priority? uint8
+--rw accept-mode? boolean +--rw accept-mode? boolean
+--rw (advertise-interval-choice)? +--rw (advertise-interval-choice)?
| +--:(v2) | +--:(v2)
| | +--rw advertise-interval-sec? uint8 | | +--rw advertise-interval-sec? uint8
| +--:(v3) | +--:(v3)
| +--rw advertise-interval-centi-sec? uint16 | +--rw advertise-interval-centi-sec? uint16
+--rw track +--rw track
| +--rw interfaces | +--rw interfaces
| | +--rw interface* [interface] | | +--rw interface* [interface]
| | +--rw interface if:interface-ref | | +--rw interface if:interface-ref
| | +--rw priority-decrement? uint8 | | +--rw priority-decrement? uint8
| +--rw networks | +--rw networks
| +--rw network* [network] | +--rw network* [prefix]
| +--rw network inet:ipv4-prefix | +--rw prefix inet:ipv4-prefix
| +--rw priority-decrement? uint8 | +--rw priority-decrement? uint8
+--rw virtual-ipv4-addresses +--rw virtual-ipv4-addresses
+--rw virtual-ipv4-address* [ipv4-address] +--rw virtual-ipv4-address* [ipv4-address]
+--rw ipv4-address inet:ipv4-address +--rw ipv4-address inet:ipv4-address
augment /if:interfaces/if:interface/ip:ipv6: augment /if:interfaces/if:interface/ip:ipv6:
+--rw vrrp +--rw vrrp
+--rw vrrp-instance* [vrid] +--rw vrrp-instance* [vrid]
+--rw vrid uint8 +--rw vrid uint8
+--rw version? enumeration +--rw version identityref
+--rw log-state-change? boolean +--rw log-state-change? boolean
+--rw preempt! +--rw preempt
| +--rw enabled? boolean
| +--rw hold-time? uint16 | +--rw hold-time? uint16
+--rw priority? uint8 +--rw priority? uint8
+--rw accept-mode? boolean +--rw accept-mode? boolean
+--rw advertise-interval-centi-sec? uint16 +--rw advertise-interval-centi-sec? uint16
+--rw track +--rw track
| +--rw interfaces | +--rw interfaces
| | +--rw interface* [interface] | | +--rw interface* [interface]
| | +--rw interface if:interface-ref | | +--rw interface if:interface-ref
| | +--rw priority-decrement? uint8 | | +--rw priority-decrement? uint8
| +--rw networks | +--rw networks
| +--rw network* [network] | +--rw network* [prefix]
| +--rw network inet:ipv6-prefix | +--rw prefix inet:ipv6-prefix
| +--rw priority-decrement? uint8 | +--rw priority-decrement? uint8
+--rw virtual-ipv6-addresses +--rw virtual-ipv6-addresses
+--rw virtual-ipv6-address* [ipv6-address] +--rw virtual-ipv6-address* [ipv6-address]
+--rw ipv6-address inet:ipv6-address +--rw ipv6-address inet:ipv6-address
augment /if:interfaces-state/if:interface/ip:ipv4: augment /if:interfaces-state/if:interface/ip:ipv4:
+--ro vrrp +--ro vrrp
+--ro vrrp-instance* [vrid] +--ro vrrp-instance* [vrid]
+--ro vrid uint8 +--ro vrid uint8
+--ro version? enumeration +--ro version identityref
+--ro log-state-change? boolean +--ro log-state-change? boolean
+--ro preempt! +--ro preempt
| +--ro enabled? boolean
| +--ro hold-time? uint16 | +--ro hold-time? uint16
+--ro priority? uint8 +--ro priority? uint8
+--ro accept-mode? boolean +--ro accept-mode? boolean
+--ro (advertise-interval-choice)? +--ro (advertise-interval-choice)?
| +--:(v2) | +--:(v2)
| | +--ro advertise-interval-sec? uint8 | | +--ro advertise-interval-sec? uint8
| +--:(v3) | +--:(v3)
| +--ro advertise-interval-centi-sec? uint16 | +--ro advertise-interval-centi-sec? uint16
+--ro track +--ro track
| +--ro interfaces | +--ro interfaces
| | +--ro interface* [interface] | | +--ro interface* [interface]
| | +--ro interface if:interface-ref | | +--ro interface if:interface-ref
| | +--ro priority-decrement? uint8 | | +--ro priority-decrement? uint8
| +--ro networks | +--ro networks
| +--ro network* [network] | +--ro network* [prefix]
| +--ro network inet:ipv4-prefix | +--ro prefix inet:ipv4-prefix
| +--ro priority-decrement? uint8 | +--ro priority-decrement? uint8
+--ro virtual-ipv4-addresses +--ro virtual-ipv4-addresses
| +--ro virtual-ipv4-address* [ipv4-address] | +--ro virtual-ipv4-address* [ipv4-address]
| +--ro ipv4-address inet:ipv4-address | +--ro ipv4-address inet:ipv4-address
+--ro state? identityref +--ro state? identityref
+--ro is-owner? boolean +--ro is-owner? boolean
+--ro last-adv-source? inet:ip-address +--ro last-adv-source? inet:ip-address
+--ro up-time? yang:date-and-time +--ro up-datetime? yang:date-and-time
+--ro master-down-interval? uint32 +--ro master-down-interval? uint32
+--ro skew-time? uint32 +--ro skew-time? uint32
+--ro last-event? string +--ro last-event? identityref
+--ro new-master-reason? new-master-reason-type +--ro new-master-reason? new-master-reason-type
+--ro statistics +--ro statistics
+--ro discontinuity-time? yang:date-and-time +--ro discontinuity-datetime? yang:date-and-time
+--ro master-transitions? yang:counter32 +--ro master-transitions? yang:counter32
+--ro advertisement-recv? yang:counter64 +--ro advertisement-recv? yang:counter64
+--ro advertisement-sent? yang:counter64 +--ro advertisement-sent? yang:counter64
+--ro interval-errors? yang:counter64 +--ro interval-errors? yang:counter64
{validate-interval-errors}? {validate-interval-errors}?
+--ro priority-zero-pkts-rcvd? yang:counter64 +--ro priority-zero-pkts-rcvd? yang:counter64
+--ro priority-zero-pkts-sent? yang:counter64 +--ro priority-zero-pkts-sent? yang:counter64
+--ro invalid-type-pkts-rcvd? yang:counter64 +--ro invalid-type-pkts-rcvd? yang:counter64
+--ro address-list-errors? yang:counter64 +--ro address-list-errors? yang:counter64
{validate-address-list-errors}? {validate-address-list-errors}?
+--ro packet-length-errors? yang:counter64 +--ro packet-length-errors? yang:counter64
augment /if:interfaces-state/if:interface/ip:ipv6: augment /if:interfaces-state/if:interface/ip:ipv6:
+--ro vrrp +--ro vrrp
+--ro vrrp-instance* [vrid] +--ro vrrp-instance* [vrid]
+--ro vrid uint8 +--ro vrid uint8
+--ro version? enumeration +--ro version identityref
+--ro log-state-change? boolean +--ro log-state-change? boolean
+--ro preempt! +--ro preempt
| +--ro enabled? boolean
| +--ro hold-time? uint16 | +--ro hold-time? uint16
+--ro priority? uint8 +--ro priority? uint8
+--ro accept-mode? boolean +--ro accept-mode? boolean
+--ro advertise-interval-centi-sec? uint16 +--ro advertise-interval-centi-sec? uint16
+--ro track +--ro track
| +--ro interfaces | +--ro interfaces
| | +--ro interface* [interface] | | +--ro interface* [interface]
| | +--ro interface if:interface-ref | | +--ro interface if:interface-ref
| | +--ro priority-decrement? uint8 | | +--ro priority-decrement? uint8
| +--ro networks | +--ro networks
| +--ro network* [network] | +--ro network* [prefix]
| +--ro network inet:ipv6-prefix | +--ro prefix inet:ipv6-prefix
| +--ro priority-decrement? uint8 | +--ro priority-decrement? uint8
+--ro virtual-ipv6-addresses +--ro virtual-ipv6-addresses
| +--ro virtual-ipv6-address* [ipv6-address] | +--ro virtual-ipv6-address* [ipv6-address]
| +--ro ipv6-address inet:ipv6-address | +--ro ipv6-address inet:ipv6-address
+--ro state? identityref +--ro state? identityref
+--ro is-owner? boolean +--ro is-owner? boolean
+--ro last-adv-source? inet:ip-address +--ro last-adv-source? inet:ip-address
+--ro up-time? yang:date-and-time +--ro up-datetime? yang:date-and-time
+--ro master-down-interval? uint32 +--ro master-down-interval? uint32
+--ro skew-time? uint32 +--ro skew-time? uint32
+--ro last-event? string +--ro last-event? identityref
+--ro new-master-reason? new-master-reason-type +--ro new-master-reason? new-master-reason-type
+--ro statistics +--ro statistics
+--ro discontinuity-time? yang:date-and-time +--ro discontinuity-datetime? yang:date-and-time
+--ro master-transitions? yang:counter32 +--ro master-transitions? yang:counter32
+--ro advertisement-recv? yang:counter64 +--ro advertisement-recv? yang:counter64
+--ro advertisement-sent? yang:counter64 +--ro advertisement-sent? yang:counter64
+--ro interval-errors? yang:counter64 +--ro interval-errors? yang:counter64
{validate-interval-errors}? {validate-interval-errors}?
+--ro priority-zero-pkts-rcvd? yang:counter64 +--ro priority-zero-pkts-rcvd? yang:counter64
+--ro priority-zero-pkts-sent? yang:counter64 +--ro priority-zero-pkts-sent? yang:counter64
+--ro invalid-type-pkts-rcvd? yang:counter64 +--ro invalid-type-pkts-rcvd? yang:counter64
+--ro address-list-errors? yang:counter64 +--ro address-list-errors? yang:counter64
{validate-address-list-errors}? {validate-address-list-errors}?
+--ro packet-length-errors? yang:counter64 +--ro packet-length-errors? yang:counter64
augment /if:interfaces-state: augment /if:interfaces-state:
+--ro vrrp-global +--ro vrrp-global
+--ro virtual-routers? uint32 +--ro virtual-routers? uint32
+--ro interfaces? uint32 +--ro interfaces? uint32
+--ro checksum-errors? yang:counter64 +--ro statistics
+--ro version-errors? yang:counter64 +--ro discontinuity-datetime? yang:date-and-time
+--ro vrid-errors? yang:counter64 +--ro checksum-errors? yang:counter64
+--ro ip-ttl-errors? yang:counter64 +--ro version-errors? yang:counter64
+--ro global-statistics-discontinuity-time? yang:date-and- +--ro vrid-errors? yang:counter64
time +--ro ip-ttl-errors? yang:counter64
notifications: notifications:
+---n vrrp-new-master-event +---n vrrp-new-master-event
| +--ro master-ipaddr? inet:ipv4-address | +--ro master-ip-address inet:ip-address
| +--ro new-master-reason? new-master-reason-type | +--ro new-master-reason new-master-reason-type
+---n vrrp-protocol-error-event +---n vrrp-protocol-error-event
| +--ro protocol-error-reason? enumeration | +--ro protocol-error-reason identityref
+---n vrrp-virtual-router-error-event +---n vrrp-virtual-router-error-event
+--ro interface? if:interface-ref +--ro interface if:interface-ref
+--ro ip-version? enumeration +--ro ip-version enumeration
+--ro vrid-v4? leafref +--ro vrid-v4? leafref
+--ro vrid-v6? leafref +--ro vrid-v6? leafref
+--ro virtual-router-error-reason? enumeration +--ro virtual-router-error-reason identityref
3. VRRP YANG module 4. YANG Module
<CODE BEGINS> file "ietf-vrrp@2016-12-01.yang" <CODE BEGINS> file "ietf-vrrp@2017-02-21.yang"
module ietf-vrrp { module ietf-vrrp {
yang-version 1.1;
namespace "urn:ietf:params:xml:ns:yang:ietf-vrrp"; namespace "urn:ietf:params:xml:ns:yang:ietf-vrrp";
prefix "vrrp"; prefix "vrrp";
import ietf-inet-types { import ietf-inet-types {
prefix "inet"; prefix "inet";
} }
import ietf-yang-types { import ietf-yang-types {
prefix "yang"; prefix "yang";
} }
import ietf-interfaces { import ietf-interfaces {
prefix "if"; prefix "if";
} }
skipping to change at page 8, line 14 skipping to change at page 12, line 32
"WG Web: <https://datatracker.ietf.org/wg/rtgwg/> "WG Web: <https://datatracker.ietf.org/wg/rtgwg/>
WG List: <mailto:rtgwg@ietf.org> WG List: <mailto:rtgwg@ietf.org>
WG Chair: Jeff Tantsura WG Chair: Jeff Tantsura
<mailto:jefftant.ietf@gmail.com> <mailto:jefftant.ietf@gmail.com>
WG Chair: Chris Bowers WG Chair: Chris Bowers
<mailto:cbowers@juniper.net> <mailto:cbowers@juniper.net>
Editor: Xufeng Liu Editor: Xufeng Liu
<mailto:xliu@kuatrotech.com> <mailto:Xufeng_Liu@jabil.com>
Editor: Athanasios Kyparlis Editor: Athanasios Kyparlis
<mailto:akyparlis@kuatrotech.com> <mailto:Athanasios_Kyparlis@jabil.com>
Editor: Ravi Parikh Editor: Ravi Parikh
<mailto:parikhr@vmware.com> <mailto:parikhr@vmware.com>
Editor: Acee Lindem Editor: Acee Lindem
<mailto:acee@cisco.com> <mailto:acee@cisco.com>
Editor: Mingui Zhang Editor: Mingui Zhang
<mailto:zhangmingui@huawei.com>"; <mailto:zhangmingui@huawei.com>";
description description
"This YANG module defines a model for managing Virtual Router "This YANG module defines a model for managing Virtual Router
Redundancy Protocol (VRRP) version 2 and version 3."; Redundancy Protocol (VRRP) version 2 and version 3.";
revision 2016-12-01 { revision 2017-02-21 {
description "Initial revision"; description "Initial revision";
reference reference
"RFC 2787: Definitions of Managed Objects for the Virtual "RFC XXXX: A YANG Data Model for Virtual Router Redundancy
Protocol (VRRP).
RFC 2787: Definitions of Managed Objects for the Virtual
Router Redundancy Protocol. Router Redundancy Protocol.
RFC 3768: Virtual Router Redundancy Protocol (VRRP). RFC 3768: Virtual Router Redundancy Protocol (VRRP).
RFC 5798: Virtual Router Redundancy Protocol (VRRP) Version 3. RFC 5798: Virtual Router Redundancy Protocol (VRRP) Version 3.
RFC 6527: Definitions of Managed Objects for the Virtual RFC 6527: Definitions of Managed Objects for the Virtual
Router Redundancy Protocol Version 3 (VRRPv3)."; Router Redundancy Protocol Version 3 (VRRPv3).";
} }
/* /*
* Features * Features
*/ */
skipping to change at page 9, line 40 skipping to change at page 14, line 4
state,"; state,";
} }
enum priority { enum priority {
description "Priority was higher."; description "Priority was higher.";
} }
enum preempted { enum preempted {
description "The master was preempted."; description "The master was preempted.";
} }
enum master-no-response { enum master-no-response {
description "Previous master did not respond."; description "Previous master did not respond.";
} }
} }
description description
"The reason for the virtual router to transition to master "The reason for the virtual router to transition to master
state."; state.";
} // new-master-reason-type } // new-master-reason-type
/* /*
* Identities * Identities
*/ */
/* vrrp-event-type identity and its derivatives. */
identity vrrp-event-type {
description
"The type to indicate the type of a VRRP protocol event.";
}
identity vrrp-event-none {
base vrrp-event-type;
description
"Indicates a non-meaningful event.";
}
identity vrrp-event-startup {
base vrrp-event-type;
description
"Indicates that a VRRP router has initiated the protocol.";
}
identity vrrp-event-shutdown {
base vrrp-event-type;
description
"Indicates that a VRRP router has closed down the protocol.";
}
identity vrrp-event-higher-priority-backup {
base vrrp-event-type;
description
"Indicates that a backup router has a higher priority than
the current master.";
}
identity vrrp-event-master-timeout {
base vrrp-event-type;
description
"Indicates that the current master has not sent an
advertisement within the limit of master-down-interval.";
}
identity vrrp-event-interface-up {
base vrrp-event-type;
description
"Indicates that the VRRP enabled interface has become
operational up.";
}
identity vrrp-event-interface-down {
base vrrp-event-type;
description
"Indicates that the VRRP enabled interface has become
operational down.";
}
identity vrrp-event-no-primary-ip-address {
base vrrp-event-type;
description
"Indicates that the primary IP address on the VRRP enabled
interface has become unavailable.";
}
identity vrrp-event-primary-ip-address {
base vrrp-event-type;
description
"Indicates that the primary IP address on the VRRP enabled
interface has become available.";
}
identity vrrp-event-no-virtual-ip-addresses {
base vrrp-event-type;
description
"Indicates that there are no virtual IP addresses on the
virtual router.";
}
identity vrrp-event-virtual-ip-addresses {
base vrrp-event-type;
description
"Indicates that there are virtual IP addresses on the
virtual router.";
}
identity vrrp-event-preempt-hold-timeout {
base vrrp-event-type;
description
"Indicates that the configured preemption hold time has
passed.";
}
identity vrrp-event-lower-priority-master {
base vrrp-event-type;
description
"Indicates that there is a lower priority VRRP master.";
}
identity vrrp-event-owner-preempt {
base vrrp-event-type;
description
"Indicates that the owner has preempted another router to
become the master.";
}
/* vrrp-error-global identity and its derivatives. */
identity vrrp-error-global {
description
"The type to indicate the type of a VRRP error that occurs
for a packet before it reaches a VRRP router.";
}
identity checksum-error {
base vrrp-error-global;
description
"A packet has been received with an invalid VRRP checksum
value.";
}
identity ip-ttl-error {
base vrrp-error-global;
description
"A packet has been received with IP TTL (Time-To-Live)
not equal to 255.";
}
identity version-error {
base vrrp-error-global;
description
"A packet has been received with an unknown or unsupported
version number.";
}
identity vrid-error {
base vrrp-error-global;
description
"A packet has been received with a VRID that is not valid
for any virtual router on this router.";
}
/* vrrp-error-virtual-router identity and its derivatives. */
identity vrrp-error-virtual-router {
description
"The type to indicate the type of a VRRP error that occurs
after a packet reaches a VRRP router.";
}
identity address-list-error {
base vrrp-error-virtual-router;
description
"A packet has been received with an address list that
does not match the locally configured address list for
the virtual router.";
}
identity interval-error {
base vrrp-error-virtual-router;
description
"A packet has been received with an advertisement
interval different than the one configured for the local
virtual router";
}
identity packet-length-error {
base vrrp-error-virtual-router;
description
"A packet has been received with a packet length less
than the length of the VRRP header.";
}
/* vrrp-state-type identity and its derivatives. */
identity vrrp-state-type { identity vrrp-state-type {
description description
"The type to indicate the state of a virtual router."; "The type to indicate the state of a virtual router.";
} }
identity initialize { identity initialize {
base vrrp-state-type; base vrrp-state-type;
description description
"Indicates that the virtual router is waiting "Indicates that the virtual router is waiting
for a startup event."; for a startup event.";
} }
skipping to change at page 10, line 35 skipping to change at page 17, line 39
availability of the master router."; availability of the master router.";
} }
identity master { identity master {
base vrrp-state-type; base vrrp-state-type;
description description
"Indicates that the virtual router is forwarding "Indicates that the virtual router is forwarding
packets for IP addresses that are associated with packets for IP addresses that are associated with
this virtual router."; this virtual router.";
} }
/* vrrp-version identity and its derivatives. */
identity vrrp-version {
description
"The version of the VRRP protocol.";
}
identity vrrp-v2 {
base vrrp-version;
description
"Indicates version 2 of the VRRP protocol.";
}
identity vrrp-v3 {
base vrrp-version;
description
"Indicates version 3 of the VRRP protocol.";
}
/* /*
* Groupings * Groupings
*/ */
grouping vrrp-common-attributes { grouping vrrp-common-attributes {
description description
"Group of VRRP attributes common to version 2 and version 3"; "Group of VRRP attributes common to version 2 and version 3";
leaf vrid { leaf vrid {
type uint8 { type uint8 {
skipping to change at page 11, line 4 skipping to change at page 18, line 18
* Groupings * Groupings
*/ */
grouping vrrp-common-attributes { grouping vrrp-common-attributes {
description description
"Group of VRRP attributes common to version 2 and version 3"; "Group of VRRP attributes common to version 2 and version 3";
leaf vrid { leaf vrid {
type uint8 { type uint8 {
range 1..255; range 1..255;
} }
description "Virtual router ID."; description "Virtual router ID.";
} }
leaf version { leaf version {
type enumeration { type identityref {
enum 2 { base vrrp:vrrp-version;
description "VRRP version 2.";
}
enum 3 {
description "VRRP version 3.";
}
} }
mandatory "true";
description "Version 2 or version 3 of VRRP."; description "Version 2 or version 3 of VRRP.";
} }
leaf log-state-change { leaf log-state-change {
type boolean; type boolean;
default "false";
description description
"Generates VRRP state change messages each time the VRRP "Generates VRRP state change messages each time the VRRP
instance changes state (from up to down or down to up)."; instance changes state (from up to down or down to up).";
} }
container preempt { container preempt {
presence "Present if preempt is enabled.";
description description
"Enables a higher priority Virtual Router Redundancy "Enables a higher priority Virtual Router Redundancy
Protocol (VRRP) backup router to preempt a lower priority Protocol (VRRP) backup router to preempt a lower priority
VRRP master."; VRRP master.";
leaf enabled {
type boolean;
default "true";
description
"'true' if preemption is enabled.";
}
leaf hold-time { leaf hold-time {
type uint16; type uint16;
units seconds;
default 0;
description description
"Hold time, in seconds, for which a higher priority VRRP "Hold time, in seconds, for which a higher priority VRRP
backup router must wait before preempting a lower priority backup router must wait before preempting a lower priority
VRRP master."; VRRP master.";
} }
} }
leaf priority { leaf priority {
type uint8 { type uint8 {
range 1..254; range 1..254;
skipping to change at page 12, line 4 skipping to change at page 19, line 15
description description
"Hold time, in seconds, for which a higher priority VRRP "Hold time, in seconds, for which a higher priority VRRP
backup router must wait before preempting a lower priority backup router must wait before preempting a lower priority
VRRP master."; VRRP master.";
} }
} }
leaf priority { leaf priority {
type uint8 { type uint8 {
range 1..254; range 1..254;
} }
default 100; default 100;
description description
"Configures the Virtual Router Redundancy Protocol (VRRP) "Configures the Virtual Router Redundancy Protocol (VRRP)
election priority for the backup virtual router."; election priority for the backup virtual router.";
} }
} // vrrp-common-attributes
grouping vrrp-v3-attributes {
description
"Group of VRRP version 3 attributes.";
leaf accept-mode { leaf accept-mode {
when "derived-from-or-self(current()/../version, 'vrrp-v3')" {
description "Applicable only to version 3.";
}
type boolean; type boolean;
default false; default false;
description description
"Controls whether a virtual router in Master state will "Controls whether a virtual router in Master state will
accept packets addressed to the address owner's IPvX address accept packets addressed to the address owner's IPvX address
as its own if it is not the IPvX address owner. The default as its own if it is not the IPvX address owner. The default
is false. Deployments that rely on, for example, pinging the is false. Deployments that rely on, for example, pinging the
address owner's IPvX address may wish to configure address owner's IPvX address may wish to configure
accept-mode to true. accept-mode to true.
Note: IPv6 Neighbor Solicitations and Neighbor Note: IPv6 Neighbor Solicitations and Neighbor
Advertisements MUST NOT be dropped when accept-mode is Advertisements MUST NOT be dropped when accept-mode is
false."; false.";
} }
} } // vrrp-common-attributes
grouping vrrp-ipv4-attributes { grouping vrrp-ipv4-attributes {
description description
"Group of VRRP attributes for IPv4."; "Group of VRRP attributes for IPv4.";
uses vrrp-common-attributes; uses vrrp-common-attributes;
uses vrrp-v3-attributes {
when "version = 3" {
description "Applicable only to version 3.";
}
}
choice advertise-interval-choice { choice advertise-interval-choice {
description description
"The options for the advertisement interval at which VRRPv2 "The options for the advertisement interval at which VRRPv2
or VRRPv3 advertisements are sent from the specified or VRRPv3 advertisements are sent from the specified
interface."; interface.";
case v2 { case v2 {
when "version = '2'" { when "derived-from-or-self(version, 'vrrp-v2')" {
description "Applicable only to version 2."; description "Applicable only to version 2.";
} }
leaf advertise-interval-sec { leaf advertise-interval-sec {
type uint8 { type uint8 {
range 1..254; range 1..254;
} }
units seconds;
default 1; default 1;
description description
"Configures the interval that Virtual Router "Configures the interval that Virtual Router
Redundancy Protocol Version 2 (VRRPv2) advertisements Redundancy Protocol Version 2 (VRRPv2) advertisements
are sent from the specified interface."; are sent from the specified interface.";
} }
} }
case v3 { case v3 {
when "version = '3'" { when "derived-from-or-self(version, 'vrrp-v3')" {
description "Applicable only to version 3."; description "Applicable only to version 3.";
} }
leaf advertise-interval-centi-sec { leaf advertise-interval-centi-sec {
type uint16 { type uint16 {
range 1..4095; range 1..4095;
} }
units centiseconds; units centiseconds;
default 100; default 100;
description description
"Configures the interval that Virtual Router "Configures the interval that Virtual Router
skipping to change at page 14, line 31 skipping to change at page 21, line 21
description "Interface is IPv4."; description "Interface is IPv4.";
} }
description description
"Interface to track."; "Interface to track.";
} }
leaf priority-decrement { leaf priority-decrement {
type uint8 { type uint8 {
range 1..254; range 1..254;
} }
default 10;
description description
"Specifies how much to decrement the priority of the "Specifies how much to decrement the priority of the
VRRP instance if the interface goes down."; VRRP instance if the interface goes down.";
} }
} // track-interface } // interface
} // track-interfaces } // interfaces
container networks { container networks {
description description
"Enables the backup Virtual Router Redundancy Protocol "Enables the backup Virtual Router Redundancy Protocol
version 2 (VRRP) or version 3 (VRRPv3) router to track a version 2 (VRRP) or version 3 (VRRPv3) router to track a
specified network through the IP network prefix of that specified network through the IP network prefix of that
network."; network.";
list network { list network {
key "network"; key "prefix";
description description
"Enables the specified Virtual Router Redundancy "Enables the specified Virtual Router Redundancy
Protocol version 2 (VRRP) or version 3 (VRRPv3) Protocol version 2 (VRRP) or version 3 (VRRPv3)
instance to track an interface."; instance to track an IP network.";
leaf network { leaf prefix {
type inet:ipv4-prefix; type inet:ipv4-prefix;
description description
"Network to track."; "The prefix of the network to track.";
} }
leaf priority-decrement { leaf priority-decrement {
type uint8 { type uint8 {
range 1..254; range 1..254;
} }
default 10; default 10;
description description
"Specifies how much to decrement the priority of the "Specifies how much to decrement the priority of the
backup VRRP router if there is a failure in the IP backup VRRP router if there is a failure in the IP
skipping to change at page 16, line 18 skipping to change at page 22, line 43
} // virtual-ipv4-address } // virtual-ipv4-address
} // virtual-ipv4-addresses } // virtual-ipv4-addresses
} // grouping vrrp-ipv4-attributes } // grouping vrrp-ipv4-attributes
grouping vrrp-ipv6-attributes { grouping vrrp-ipv6-attributes {
description description
"Group of VRRP attributes for IPv6."; "Group of VRRP attributes for IPv6.";
uses vrrp-common-attributes; uses vrrp-common-attributes;
uses vrrp-v3-attributes {
when "version = 3" {
description "Uses VRRP version 3 attributes.";
}
} // uses vrrp-v3-attributes
leaf advertise-interval-centi-sec { leaf advertise-interval-centi-sec {
type uint16 { type uint16 {
range 1..4095; range 1..4095;
} }
units centiseconds; units centiseconds;
default 100; default 100;
description description
"Configures the interval that Virtual Router "Configures the interval that Virtual Router
Redundancy Protocol version 3 (VRRPv3) advertisements Redundancy Protocol version 3 (VRRPv3) advertisements
are sent from the specified interface."; are sent from the specified interface.";
skipping to change at page 17, line 23 skipping to change at page 23, line 34
description "Interface is IPv6."; description "Interface is IPv6.";
} }
description description
"Interface to track."; "Interface to track.";
} }
leaf priority-decrement { leaf priority-decrement {
type uint8 { type uint8 {
range 1..254; range 1..254;
} }
default 10;
description description
"Specifies how much to decrement the priority of the "Specifies how much to decrement the priority of the
VRRP instance if the interface goes down."; VRRP instance if the interface goes down.";
} }
} // track-interface } // interface
} // track-interfaces } // interfaces
container networks { container networks {
description description
"Enables the backup Virtual Router Redundancy Protocol "Enables the backup Virtual Router Redundancy Protocol
version 2 (VRRP) or version 3 (VRRPv3) router to track a version 2 (VRRP) or version 3 (VRRPv3) router to track a
specified network through the IP network prefix of that specified network through the IP network prefix of that
network."; network.";
list network { list network {
key "network"; key "prefix";
description description
"Enables the specified Virtual Router Redundancy "Enables the specified Virtual Router Redundancy
Protocol version 2 (VRRP) or version 3 (VRRPv3) Protocol version 2 (VRRP) or version 3 (VRRPv3)
instance to track an interface."; instance to track an IP network.";
leaf network { leaf prefix {
type inet:ipv6-prefix; type inet:ipv6-prefix;
description description
"Network to track."; "The prefix of the network to track.";
} }
leaf priority-decrement { leaf priority-decrement {
type uint8 { type uint8 {
range 1..254; range 1..254;
} }
default 10; default 10;
description description
"Specifies how much to decrement the priority of the "Specifies how much to decrement the priority of the
backup VRRP router if there is a failure in the IP backup VRRP router if there is a failure in the IP
skipping to change at page 19, line 7 skipping to change at page 25, line 7
} // virtual-ipv6-address } // virtual-ipv6-address
} // virtual-ipv6-addresses } // virtual-ipv6-addresses
} // grouping vrrp-ipv6-attributes } // grouping vrrp-ipv6-attributes
grouping vrrp-state-attributes { grouping vrrp-state-attributes {
description description
"Group of VRRP state attributes."; "Group of VRRP state attributes.";
leaf state { leaf state {
type identityref { type identityref {
base vrrp-state-type; base vrrp:vrrp-state-type;
} }
description description
"Operational state."; "Operational state.";
} }
leaf is-owner { leaf is-owner {
type boolean; type boolean;
description description
"Set to true if this virtual router is owner."; "Set to true if this virtual router is owner.";
} }
leaf last-adv-source { leaf last-adv-source {
type inet:ip-address; type inet:ip-address;
description description
"Last advertised IPv4/IPv6 source address"; "Last advertised IPv4/IPv6 source address";
} }
leaf up-time { leaf up-datetime {
type yang:date-and-time; type yang:date-and-time;
description description
"The time when this virtual router "The date and time when this virtual router
transitioned out of init state."; transitioned out of init state.";
} }
leaf master-down-interval { leaf master-down-interval {
type uint32; type uint32;
units centiseconds; units centiseconds;
description description
"Time interval for backup virtual router to declare "Time interval for backup virtual router to declare
Master down."; Master down.";
} }
leaf skew-time { leaf skew-time {
type uint32; type uint32;
units microseconds; units microseconds;
description description
"Calculated based on the priority and advertisement "Calculated based on the priority and advertisement
interval configuration command parameters. See RFC 3768."; interval configuration command parameters. See RFC 3768.";
} }
leaf last-event { leaf last-event {
type string; type identityref {
base vrrp:vrrp-event-type;
}
description description
"Last reported event."; "Last reported event.";
} }
leaf new-master-reason { leaf new-master-reason {
type new-master-reason-type; type new-master-reason-type;
description description
"Indicates the reason for the virtual router to transition "Indicates the reason for the virtual router to transition
to master state."; to master state.";
} }
container statistics { container statistics {
description description
"VRRP statistics."; "VRRP statistics.";
leaf discontinuity-time { leaf discontinuity-datetime {
type yang:date-and-time; type yang:date-and-time;
description description
"The time on the most recent occasion at which any one or "The time on the most recent occasion at which any one or
more of the VRRP statistic counters suffered a more of the VRRP statistic counters suffered a
discontinuity. If no such discontinuities have occurred discontinuity. If no such discontinuities have occurred
since the last re-initialization of the local management since the last re-initialization of the local management
subsystem, then this node contains the time that the subsystem, then this node contains the time that the
local management subsystem re-initialized itself."; local management subsystem re-initialized itself.";
} }
skipping to change at page 22, line 36 skipping to change at page 28, line 17
leaf virtual-routers { leaf virtual-routers {
type uint32; type uint32;
description "Number of configured virtual routers."; description "Number of configured virtual routers.";
} }
leaf interfaces { leaf interfaces {
type uint32; type uint32;
description "Number of interface with VRRP configured."; description "Number of interface with VRRP configured.";
} }
leaf checksum-errors { container statistics {
type yang:counter64;
description
"The total number of VRRP packets received with an invalid
VRRP checksum value.";
reference "RFC 5798, Section 5.2.8";
}
leaf version-errors {
type yang:counter64;
description
"The total number of VRRP packets received with an unknown
or unsupported version number.";
reference "RFC 5798, Section 5.2.1";
}
leaf vrid-errors {
type yang:counter64;
description
"The total number of VRRP packets received with a VRID that
is not valid for any virtual router on this router.";
reference "RFC 5798, Section 5.2.3";
}
leaf ip-ttl-errors {
type yang:counter64;
description description
"The total number of VRRP packets received by the "VRRP global statistics.";
virtual router with IP TTL (Time-To-Live) not equal
to 255.";
reference "RFC 5798, Sections 5.1.1.3 and 5.1.2.3.";
}
leaf global-statistics-discontinuity-time { leaf discontinuity-datetime {
type yang:date-and-time; type yang:date-and-time;
description description
"The time on the most recent occasion at which one of "The time on the most recent occasion at which one of
router-checksum-errors, router-version-errors, checksum-errors, version-errors, vrid-errors, and
router-vrid-errors, and ip-ttl-errors suffered a ip-ttl-errors suffered a discontinuity.
discontinuity.
If no such discontinuities have occurred since the last If no such discontinuities have occurred since the last
re-initialization of the local management subsystem, re-initialization of the local management subsystem,
then this object will be 0."; then this node contains the time that the local management
} subsystem re-initialized itself.";
}
leaf checksum-errors {
type yang:counter64;
description
"The total number of VRRP packets received with an invalid
VRRP checksum value.";
reference "RFC 5798, Section 5.2.8";
}
leaf version-errors {
type yang:counter64;
description
"The total number of VRRP packets received with an unknown
or unsupported version number.";
reference "RFC 5798, Section 5.2.1";
}
leaf vrid-errors {
type yang:counter64;
description
"The total number of VRRP packets received with a VRID that
is not valid for any virtual router on this router.";
reference "RFC 5798, Section 5.2.3";
}
leaf ip-ttl-errors {
type yang:counter64;
description
"The total number of VRRP packets received by the
virtual router with IP TTL (Time-To-Live) not equal
to 255.";
reference "RFC 5798, Sections 5.1.1.3 and 5.1.2.3.";
}
} // statistics
} // vrrp-global-state-attributes } // vrrp-global-state-attributes
/* /*
* Configuration data nodes * Configuration data nodes
*/ */
augment "/if:interfaces/if:interface/ip:ipv4" { augment "/if:interfaces/if:interface/ip:ipv4" {
description "Augment IPv4 interface."; description "Augment IPv4 interface.";
container vrrp { container vrrp {
skipping to change at page 24, line 34 skipping to change at page 30, line 6
augment "/if:interfaces/if:interface/ip:ipv6" { augment "/if:interfaces/if:interface/ip:ipv6" {
description "Augment IPv6 interface."; description "Augment IPv6 interface.";
container vrrp { container vrrp {
description description
"Configures the Virtual Router Redundancy Protocol (VRRP) "Configures the Virtual Router Redundancy Protocol (VRRP)
version 3 for IPv6."; version 3 for IPv6.";
list vrrp-instance { list vrrp-instance {
must "version = '3'" { must "derived-from-or-self(version, 'vrrp-v3')" {
description description
"IPv6 is only supported by version 3."; "IPv6 is only supported by version 3.";
} }
key vrid; key vrid;
description description
"Defines a virtual router, identified by a virtual router "Defines a virtual router, identified by a virtual router
identifier (VRID), within IPv6 address space."; identifier (VRID), within IPv6 address space.";
uses vrrp-ipv6-attributes; uses vrrp-ipv6-attributes;
} // list vrrp-instance } // list vrrp-instance
skipping to change at page 26, line 30 skipping to change at page 31, line 34
} }
} }
/* /*
* Notifications * Notifications
*/ */
notification vrrp-new-master-event { notification vrrp-new-master-event {
description description
"Notification event for a change of VRRP new master."; "Notification event for a change of VRRP new master.";
leaf master-ipaddr { leaf master-ip-address {
type inet:ipv4-address; type inet:ip-address;
mandatory "true";
description description
"IPv4 or IPv6 address of the new master."; "IPv4 or IPv6 address of the new master.";
} }
leaf new-master-reason { leaf new-master-reason {
type new-master-reason-type; type new-master-reason-type;
mandatory "true";
description description
"Indicates the reason for the virtual router to transition "Indicates the reason for the virtual router to transition
to master state."; to master state.";
} }
} }
notification vrrp-protocol-error-event { notification vrrp-protocol-error-event {
description description
"Notification event for a VRRP protocol error."; "Notification event for a VRRP protocol error.";
leaf protocol-error-reason { leaf protocol-error-reason {
type enumeration { type identityref {
enum checksum-error { base vrrp:vrrp-error-global;
description
"A packet has been received with an invalid VRRP checksum
value.";
}
enum version-error {
description
"A packet has been received with an unknown or
unsupported version number.";
}
enum vrid-error {
description
"A packet has been received with a VRID that is not valid
for any virtual router on this router.";
}
enum ip-ttl-error {
description
"A packet has been received with IP TTL (Time-To-Live)
not equal to 255.";
}
} }
mandatory "true";
description description
"Indicates the reason for the protocol error."; "Indicates the reason for the protocol error.";
} }
} }
notification vrrp-virtual-router-error-event { notification vrrp-virtual-router-error-event {
description description
"Notification event for an error happened on a virtual "Notification event for an error happened on a virtual
router."; router.";
leaf interface { leaf interface {
type if:interface-ref; type if:interface-ref;
mandatory "true";
description description
"Indicates the interface for which statistics area "Indicates the interface for which statistics area
to be cleared."; to be cleared.";
} }
leaf ip-version { leaf ip-version {
type enumeration { type enumeration {
enum 4 { enum 4 {
description "IPv4"; description "IPv4";
} }
enum 6 { enum 6 {
description "IPv6"; description "IPv6";
} }
} }
mandatory "true";
description "Indicates the IP version."; description "Indicates the IP version.";
} }
leaf vrid-v4 { leaf vrid-v4 {
type leafref { type leafref {
path "/if:interfaces/if:interface" path "/if:interfaces/if:interface"
+ "[if:name = current()/../interface]/ip:ipv4/vrrp/" + "[if:name = current()/../vrrp:interface]/ip:ipv4/"
+ "vrrp-instance/vrid"; + "vrrp:vrrp/vrrp:vrrp-instance/vrrp:vrid";
} }
description description
"Indicates the virtual router on which the event has "Indicates the virtual router on which the event has
occurred."; occurred.";
} }
leaf vrid-v6 { leaf vrid-v6 {
type leafref { type leafref {
path "/if:interfaces/if:interface" path "/if:interfaces/if:interface"
+ "[if:name = current()/../interface]/ip:ipv6/vrrp/" + "[if:name = current()/../vrrp:interface]/ip:ipv6/"
+ "vrrp-instance/vrid"; + "vrrp:vrrp/vrrp:vrrp-instance/vrrp:vrid";
} }
description description
"Indicates the virtual router on which the event has "Indicates the virtual router on which the event has
occurred."; occurred.";
} }
leaf virtual-router-error-reason { leaf virtual-router-error-reason {
type enumeration { type identityref {
enum interval-error { base vrrp:vrrp-error-virtual-router;
description
"A packet has been received with an advertisement
interval different than the one configured for the local
virtual router";
}
enum address-list-error {
description
"A packet has been received with an address list that
does not match the locally configured address list for
the virtual router.";
}
enum packet-length-error {
description
"A packet has been received with a packet length less
than the length of the VRRP header.";
}
} }
mandatory "true";
description description
"Indicates the reason for the virtual router error."; "Indicates the reason for the virtual router error.";
} }
} }
} }
<CODE ENDS> <CODE ENDS>
4. IANA Considerations 5. IANA Considerations
RFC Ed.: In this section, replace all occurrences of 'XXXX' with the RFC Ed.: In this section, replace all occurrences of 'XXXX' with the
actual RFC number (and remove this note). actual RFC number (and remove this note).
This document registers the following namespace URIs in the IETF XML This document registers the following namespace URIs in the IETF XML
registry [RFC3688]: registry [RFC3688]:
-------------------------------------------------------------------- --------------------------------------------------------------------
URI: urn:ietf:params:xml:ns:yang:ietf-vrrp URI: urn:ietf:params:xml:ns:yang:ietf-vrrp
Registrant Contact: The IESG. Registrant Contact: The IESG.
XML: N/A, the requested URI is an XML namespace. XML: N/A, the requested URI is an XML namespace.
-------------------------------------------------------------------- --------------------------------------------------------------------
This document registers the following YANG modules in the YANG Module This document registers the following YANG modules in the YANG Module
Names registry [RFC6020]: Names registry [RFC7950]:
-------------------------------------------------------------------- --------------------------------------------------------------------
name: ietf-vrrp name: ietf-vrrp
namespace: urn:ietf:params:xml:ns:yang:ietf-vrrp namespace: urn:ietf:params:xml:ns:yang:ietf-vrrp
prefix: vrrp prefix: vrrp
reference: RFC XXXX reference: RFC XXXX
-------------------------------------------------------------------- --------------------------------------------------------------------
5. Security Considerations 6. Security Considerations
The configuration, state, action and notification data defined in The configuration, state, and action data defined in this document
this document are designed to be accessed via the NETCONF protocol are designed to be accessed via a management protocol with a secure
[RFC6241]. The data-model by itself does not create any security transport layer, such as NETCONF [RFC6241]. The NETCONF access
implications. The security considerations for the NETCONF protocol control model [RFC6536] provides the means to restrict access for
are applicable. The NETCONF protocol used for sending the data particular NETCONF users to a preconfigured subset of all available
supports authentication and encryption. NETCONF protocol operations and content.
6. References A number of configuration data nodes defined in this document are
writable/creatable/deletable (i.e., "config true" in YANG terms,
which is the default). These data nodes may be considered sensitive
or vulnerable in some network environments. Write operations to
these data nodes, such as "edit-config" in NETCONF, can have negative
effects on the network if the protocol operations are not properly
protected. The vulnerable "config true" parameters and subtrees are
the following:
6.1. Normative References /if:interfaces/if:interface/ip:ipv4/vrrp:vrrp/vrrp:vrrp-instance
[RFC6020] Bjorklund, M., "YANG - A Data Modeling Language for the /if:interfaces/if:interface/ip:ipv6/vrrp:vrrp/vrrp:vrrp-instance
Network Configuration Protocol (NETCONF)", RFC 6020,
October 2010.
[RFC6021] Schoenwaelder, J., "Common YANG Data Types", RFC 6021, Unauthorized access to any node of these can adversely affect the
October 2010. routing subsystem of both the local device and the network. This may
lead to network malfunctions, delivery of packets to inappropriate
destinations, and other problems.
[RFC6241] Enns, R., Bjorklund, M., Schoenwaelder, J., and A. Bierman, 7. References
"Network Configuration Protocol (NETCONF)", RFC 6241, June
2011.
[RFC2234] Crocker, D. and Overell, P.(Editors), "Augmented BNF for 7.1. Normative References
Syntax Specifications: ABNF", RFC 2234, Internet Mail
Consortium and Demon Internet Ltd., November 1997.
[RFC2338] Knight, S., Weaver, D., Whipple, D., Hinden, R., Mitzel, [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate
D., Hunt, P., Higginson, P., Shand, M., and A. Lindem, Requirement Levels", BCP 14, RFC 2119,
"Virtual Router Redundancy Protocol", RFC 2338, April 1998. DOI 10.17487/RFC2119, March 1997,
<http://www.rfc-editor.org/info/rfc2119>.
[RFC2787] Jewell, B. and D. Chuang, "Definitions of Managed Objects [RFC3688] Mealling, M., "The IETF XML Registry", BCP 81, RFC 3688,
for the Virtual Router Redundancy Protocol", RFC 2787, DOI 10.17487/RFC3688, January 2004,
March 2000. <http://www.rfc-editor.org/info/rfc3688>.
[RFC5798] Nadas, S., Ed., "Virtual Router Redundancy Protocol (VRRP) [RFC3768] Hinden, R., Ed., "Virtual Router Redundancy Protocol
Version 3 for IPv4 and IPv6", RFC 5798, March 2010. (VRRP)", RFC 3768, DOI 10.17487/RFC3768, April 2004,
<http://www.rfc-editor.org/info/rfc3768>.
[RFC6527] Tata, K., Ed., "Definitions of Managed Objects for the [RFC5798] Nadas, S., Ed., "Virtual Router Redundancy Protocol (VRRP)
Virtual Router Redundancy Protocol Version 3 (VRRPv3)", RFC Version 3 for IPv4 and IPv6", RFC 5798,
6527, March 2012. DOI 10.17487/RFC5798, March 2010,
<http://www.rfc-editor.org/info/rfc5798>.
6.2. Informative References [RFC6020] Bjorklund, M., Ed., "YANG - A Data Modeling Language for
the Network Configuration Protocol (NETCONF)", RFC 6020,
DOI 10.17487/RFC6020, October 2010,
<http://www.rfc-editor.org/info/rfc6020>.
[RFC6087] Bierman, A., "Guidelines for Authors and Reviewers of YANG [RFC6241] Enns, R., Ed., Bjorklund, M., Ed., Schoenwaelder, J., Ed.,
Data Model Documents", RFC 6087, January 2011. and A. Bierman, Ed., "Network Configuration Protocol
(NETCONF)", RFC 6241, DOI 10.17487/RFC6241, June 2011,
<http://www.rfc-editor.org/info/rfc6241>.
Authors' Addresses [RFC6991] Schoenwaelder, J., Ed., "Common YANG Data Types",
RFC 6991, DOI 10.17487/RFC6991, July 2013,
<http://www.rfc-editor.org/info/rfc6991>.
Xufeng Liu (Editor) [RFC7223] Bjorklund, M., "A YANG Data Model for Interface
Kuatro Technologies Management", RFC 7223, DOI 10.17487/RFC7223, May 2014,
<http://www.rfc-editor.org/info/rfc7223>.
[RFC7277] Bjorklund, M., "A YANG Data Model for IP Management",
RFC 7277, DOI 10.17487/RFC7277, June 2014,
<http://www.rfc-editor.org/info/rfc7277>.
[RFC7950] Bjorklund, M., Ed., "The YANG 1.1 Data Modeling Language",
RFC 7950, DOI 10.17487/RFC7950, August 2016,
<http://www.rfc-editor.org/info/rfc7950>.
[I-D.ietf-netconf-rfc5277bis]
Clemm, A., Prieto, A., Voit, E., Nilsen-Nygaard, E.,
Tripathy, A., Chisholm, S., and H. Trevino, "Subscribing
to Event Notifications", draft-ietf-netconf-rfc5277bis-01
(work in progress), October 2016.
[I-D.ietf-netconf-yang-push]
Clemm, A., Voit, E., Prieto, A., Tripathy, A., Nilsen-
Nygaard, E., Bierman, A., and B. Lengyel, "Subscribing to
YANG datastore push updates", draft-ietf-netconf-yang-
push-05 (work in progress), March 2017.
7.2. Informative References
[RFC6087] Bierman, A., "Guidelines for Authors and Reviewers of YANG
Data Model Documents", RFC 6087, DOI 10.17487/RFC6087,
January 2011, <http://www.rfc-editor.org/info/rfc6087>.
[RFC6536] Bierman, A. and M. Bjorklund, "Network Configuration
Protocol (NETCONF) Access Control Model", RFC 6536,
DOI 10.17487/RFC6536, March 2012,
<http://www.rfc-editor.org/info/rfc6536>.
[RFC7951] Lhotka, L., "JSON Encoding of Data Modeled with YANG",
RFC 7951, DOI 10.17487/RFC7951, August 2016,
<http://www.rfc-editor.org/info/rfc7951>.
Appendix A. Data Tree Example
This section contains an example of an instance data tree in the JSON
encoding [RFC7951], containing both configuration and state data.
Virtual router IP address: 10.0.0.1
+-----------------+ +-----------------+
| | | |
| Router 1.1.1.1 | | Router 1.1.1.2 |
| | | |
+--------+--------+ +--------+--------+
|eth0 |eth0
|10.0.1.1 |10.0.2.1
-------+--------------------------+-------
| |
|10.0.2.1 |10.0.2.2
+--------+--------+ +--------+--------+
| Host 1 | | Host 2 |
| Default gateway:| | Default gateway:|
| 10.0.0.1 | | 10.0.0.1 |
+-----------------+ +-----------------+
The instance data tree for Router 1.1.1.1 in the above figure could
be as follows:
{
"ietf-interfaces:interfaces": {
"interface": [
{
"name": "eth1",
"type": "iana-if-type:ethernetCsmacd",
"description": "An interface with VRRP enabled.",
"ietf-ip:ipv4": {
"address": [
{
"ip": "10.0.1.1",
"prefix-length": 24
}
],
"forwarding": true,
"ietf-vrrp:vrrp": {
"vrrp-instance": [
{
"vrid": 1,
"version": "vrrp-v3",
"priority": 200,
"advertise-interval-centi-sec": 50,
"virtual-ipv4-addresses": {
"virtual-ipv4-address": [
"ipv4-address": "10.0.0.1"
]
}
}
]
}
}
}
]
},
"ietf-interfaces:interfaces-state": {
"interface": [
{
"name": "eth1",
"type": "iana-if-type:ethernetCsmacd",
"phys-address": "00:0C:42:E5:B1:E9",
"oper-status": "up",
"statistics": {
"discontinuity-time": "2016-10-24T17:11:27+02:00"
},
"ietf-ip:ipv4": {
"forwarding": true,
"mtu": 1500,
"address": [
{
"ip": "10.0.1.1",
"prefix-length": 24
}
]
"ietf-vrrp:vrrp": {
"vrrp-instance": [
{
"vrid": 1,
"version": "vrrp-v3",
"log-state-change": false,
"preempt": {
"enabled": true,
"hold-time": 0
}
"priority": 200,
"accept-mode": false,
"advertise-interval-centi-sec": 50,
"virtual-ipv4-addresses": {
"virtual-ipv4-address": [
"ipv4-address": "10.0.0.1"
]
},
"state": "master",
"is-owner": false,
"last-adv-source": "10.1.1.1",
"up-datetime": "2016-10-24T17:11:27+02:00",
"master-down-interval": 161,
"skew-time": 11,
"last-event": "vrrp-event-interface-up",
"new-master-reason": "priority",
"statistics": {
"discontinuity-datetime":
"2016-10-24T17:11:27+02:00",
"master-transitions": 2,
"advertisement-recv": 20,
"advertisement-sent": 12,
"interval-errors": 0,
"priority-zero-pkts-rcvd": 0,
"priority-zero-pkts-sent": 0,
"invalid-type-pkts-rcvd": 0,
"address-list-errors": 0,
"packet-length-errors": 1
}
}
]
}
}
}
],
"vrrp-global": {
"virtual-routers": 3,
"interfaces": 2,
"statistics": {
"discontinuity-datetime": "2016-10-24T17:11:27+02:00",
"checksum-errors": 2,
"version-errors": 0,
"vrid-errors": 0,
"ip-ttl-errors": 1
}
}
}
}
Authors' Addresses
Xufeng Liu (editor)
Jabil
8281 Greensboro Drive, Suite 200 8281 Greensboro Drive, Suite 200
McLean, VA 22102 McLean VA 22102
USA USA
Email: xliu@kuatrotech.com EMail: Xufeng_Liu@jabil.com
Athanasios Kyparlis Athanasios Kyparlis
Kuatro Technologies Jabil
8281 Greensboro Drive, Suite 200 8281 Greensboro Drive, Suite 200
McLean, VA 22102 McLean VA 22102
USA USA
Email: akyparlis@kuatrotech.com EMail: Athanasios_Kyparlis@jabil.com
Ravi Parikh Ravi Parikh
VMware VMware
3425 Hillview Avenue 3425 Hillview Avenue
Palo Alto, CA 94304 Palo Alto CA 94304
USA USA
Email: parikhr@vmware.com EMail: parikhr@vmware.com
Acee Lindem Acee Lindem
Cisco Systems Cisco Systems
301 Midenhall Way 301 Midenhall Way
Cary, NC 27513 Cary NC 27513
USA USA
Email: acee@cisco.com EMail: acee@cisco.com
Mingui Zhang Mingui Zhang
Huawei Technologies Huawei Technologies
No. 156 Beiqing Rd. Haidian District No. 156 Beiqing Rd. Haidian District
Beijing 100095 Beijing 100095
P.R. China P.R. China
Email: zhangmingui@huawei.com EMail: zhangmingui@huawei.com
 End of changes. 138 change blocks. 
277 lines changed or deleted 841 lines changed or added

This html diff was produced by rfcdiff 1.45. The latest version is available from http://tools.ietf.org/tools/rfcdiff/