| Network Working Group | Z. Wang |
| Internet-Draft | Q. Wu |
| Intended status: Standards Track | Huawei |
| Expires: April 30, 2015 | October 27, 2014 |
A YANG Data Model for BFD Operations, Administration, and Maintenance (OAM)
draft-wang-yang-bfd-oam-00
This document presents the YANG Data model for BFD OAM. The YANG Model presented in this document extends the YANG model for Layer independent OAM Management with BFD technology specifics.
This Internet-Draft is submitted in full conformance with the provisions of BCP 78 and BCP 79.
Internet-Drafts are working documents of the Internet Engineering Task Force (IETF). Note that other groups may also distribute working documents as Internet-Drafts. The list of current Internet-Drafts is at http://datatracker.ietf.org/drafts/current/.
Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress."
This Internet-Draft will expire on April 30, 2015.
Copyright (c) 2014 IETF Trust and the persons identified as the document authors. All rights reserved.
This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (http://trustee.ietf.org/license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights and restrictions with respect to this document. Code Components extracted from this document must include Simplified BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Simplified BSD License.
This document presents the YANG Data model for BFD OAM [RFC5880]. The YANG Model presented in this document extends the YANG model for Layer Independent OAM Management defined in [I-D.tissa-lime-yang-oam-model] and [I-D.wang-lime-rpc-yang-oam-management]
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in [RFC2119].
The following terms are defined in [RFC6241] and are not redefined here:
The following terms are defined in [RFC6020] and are not redefined here:
The terminology for describing YANG data models is found in [RFC6020].
A simplified graphical representation of the data model is used in this document. The meaning of the symbols in these diagrams is as follows:
<status> <flags> <name> <opts> <type>
<status> is one of:
+ for current
x for deprecated
o for obsolete
<flags> is one of:
rw for configuration data
ro for non-configuration data
-x for rpcs
-n for notifications
<name> is the name of the node
Each node is printed as:
<opts> is one of:
? for an optional leaf or choice
! for a presence container
* for a leaf-list or list
[<keys>] for a list's keys
<type> is the name of the type for leafs and leaf-lists
If the node is augmented into the tree from another module, its name is printed as <prefix>:<name>.
+-+-+-+-+-+
| Layer |
|independent
|OAM YANG |
+-+-+-+-+-+
|
O
|
+--------------------------------------------------+
| | |
+-+-+-+-+-+ +-+-+-+-+-+ +-+-+-+-+-+
| Tissa | | BFD | . . .| foo |
|OAM YANG | |OAM YANG | |OAM YANG |
+-+-+-+-+-+ +-+-+-+-+-+ +-+-+-+-+-+
| | |
| | |
| | |
+----------------------------------------------------+
| Uniform API |
+----------------------------------------------------+
Relationship of BFD OAM YANG model to Layer independent OAM YANG model
Layer independent OAM YANG model[I-D.tissa-lime-yang-oam-model] and [I-D.wang-lime-rpc-yang-oam-management] is used as the basis for all the other OAM YANG models. This allows users to span across OAM tools of different technologies through a uniform API. The following Figure depicts the relationship of BFD OAM YANG model to the Layer Independent OAM YANG Model.
The Technology parameter is defined in the [I-D.tissa-lime-yang-oam-model] and [I-D.wang-lime-rpc-yang-oam-management] as an identity. This allows easy extension of the YANG model by other technologies. Technology specific extensions are applied only when the technology is set to the specific type. "bfd" is defined as an identity that augments the base technology-types identity.
identity bfd {
base gen-oam:technology-types;
description
"bfd type";
}
Figure 2 BFD identity type.
augment
"/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP" {
leaf bfdSess-Source-UdpPort {
description
" This leaf specifies the source UDP port number used
for this BFD session's Control packets. The value may be
zero(0) if the session is in adminDown(1) state. Upon
creation of a new BFD session via this, the value of
zero(0) specified would permit the implementation to
choose its own source port number ";
type uint32;
}
leaf bfdSess-echoSrc-Udp{
description
" This leaf specifies the source UDP port number used for
this BFD session's Echo packets. The value may be zero(0)
if the session is not running in the Echo mode, or the
session is in adminDown(1) state. Upon creation of a new
BFD session via this, the value of zero(0) would
permit the implementation to choose its own source port
number ";
type uint32;
}
}
augment
"/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP /moam:session " {
leaf bfdSess-Destination-UdpPort {
description
" This leaf specifies the destination UDP port number
used for this BFD session's Control packets. The value
may be zero(0) if the session is in adminDown(1) state";
type uint32;
}
}
In BFD, the MEP ADDRESS is either the IPv4 or IPV6 address. In [LIOAM], MEP ADDRESS is defined as either IP address, or MAC address or any label value and the same definition can be used for BFD. In addition, in bfd, the udp port also is used to identify the port number associated with MEP for BFD session.
augment "/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA " {
leaf technology-sub-type {
type identityref {
base technology-sub-type;
}
}
}
In BFD, different encapsulation types such as IP/UDP, PW-ACH can be employed. "technology-sub-type" identifies the encapsulation type within the BFD. Technology sub-type is defined as an identity type. This allows different encapsulation types to augment BFD OAM YANG model to include encapsulation type specific extensions without redefining common BFD definitions
augment
"/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/ gen-oam:context-id "
{
case context-id-bfdsess {
leaf bfdsess-discriminator {
type uint32;
description
" This leaf specifies the local discriminator for this BFD
session, which is used to uniquely identify it ";
}
leaf bfdsess-remotediscr {
type uint32;
description
" This leaf specifies the session discriminator chosen
by the remote system for this BFD session. The value may
be zero(0) if the remote discriminator is not yet known
or if the session is in the down or adminDown(1) state ";
}
leaf bfdsess-dismap-index {
type uint32;
description
" This leaf specifies a mapping between a
local discriminator and a BFD session ";
}
}
}
In BFD context-id is a pair of 32 bit Discriminators (SessDiscriminator,remotSessDiscriminator). This allows other technologies to easily augment that to include technology specific extensions. The snippet below depicts an example of augmenting context-id to include Discriminator.
The BFD session have several configuration data to specify the session configuration information. i.e.The bfdsess-version-num indicate the he version number of the BFD protocol that this session is running in. And the bfdsess-demandmode-desired indicates the local system's desire to use Demand mode. The bfdsess-controlplanel-indep indicates the local system's ability to continue to function through a disruption of the control plane. And the bfdsess-authpres indicates the local system's desire to use authentication.
augment
"/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP/ gen-oam:session " {
list session-type-bfd {
key " bfdsess-type ";
leaf bfdsess-version-num {
type uint32;
description
" The version number of the BFD protocol that this session
is running in. Write access is available for this object
to provide the ability to set the desired version for this
BFD session ";
}
leaf bfdsess-type {
type uint32;
description
" This leaf specifies the type of this BFD session ";
}
leaf bfdsess-oper-mode {
type uint32;
description
" This object specifies the operational mode of this
BFD session ";
}
leaf bfdsess-demandmode-desired {
type boolean;
description
" This leaf indicates the local system's
desire to use Demand mode. Specifically, it is set
to true(1) if the local system wishes to use
Demand mode or false(2) if not ";
}
leaf bfdsess-controlplanel-indep {
type boolean;
description
" This leaf indicates the local system's
ability to continue to function through a disruption of
the control plane. Specifically, it is set
to true(1) if the local system BFD implementation is
independent of the control plane. Otherwise, the
value is set to false(2) ";
}
leaf bfdsess-multi-point {
type boolean;
description
" This leaf indicates the Multipoint (M) bit for this
session. It is set to true(1) if the Multipoint (M) bit is
set to 1. Otherwise, the value is set to false(2) ";
}
leaf bfdsess-detect-mult {
type uint32;
description
" This leaf specifies the Detect time multiplier ";
}
leaf bfdsess-authpres {
type boolean;
description
" This leaf indicates the local system's
desire to use authentication. Specifically, it is set
to true(1) if the local system wishes the session
to be authenticated or false(2) if not";
}
leaf bfdsess-authentication-type {
type uint32;
description
" The authentication type used for this BFD session.
This field is valid only when the Authentication
Present bit is set ";
}
}
}
In BFD, there may exist several interval such as: bfdSess-DesiredMinTx-Intervl,bfdSess-ReqMinRx-Interval, bfdSess-ReqMinEchoRx-Interval,bfdSess-Negotiated-Interval,bfdSess-NegotiatedEcho-Interval.
The bfdSess-DesiredMinTX-Interval can specifies the minimum interval that the local system would like to use when transmitting BFD Control packets.
The bfdSess-ReqMinRx-interval specifies the minimum interval between received BFD Echo packets that this system is capable of supporting.
The bfdSess-ReqMinEchoRx-Interval specifies the minimum interval, between received BFD Echo packets that this system is capable of supporting.
The bfdSess-Negotiated-Interval specifies the minimum interval, in microseconds, between received BFD Echo packets that this system is capable of supporting.
The bfdSess-NegotiatedEcho-Interval specifies the negotiated interval, in microseconds, that the local system is transmitting BFD Control packets.
augment
"/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP /gen-oam:session/gen-oam:interval " {
choice bfdSess-DesiredMinTx-Interval {
type uint32;
}
choice bfdSess-ReqMinRx-Interval {
type uint32;
}
choice bfdSess-ReqMinEchoRx-Interval {
type uint32;
}
choice bfdSess-Negotiated-Interval {
type uint32;
}
choice bfdSess-NegotiatedEcho-Interval {
type uint32;
}
}
The rpc model facilitates issuing commands to a NETCONF server (in this case to the device that need to execute the OAM command) and obtaining a response.
CC extension:
augment "/ gen-oam:cc/ gen-oam:output/ gen-oam: maintenance-stats " {
case session-perform-bfd {
leaf bfdSess-PerfCtrlPkt-In {
type uint32;
description
" The total number of BFD control messages received for this
BFD session";
}
leaf bfdSess-PerfCtrlPkt-Out {
type uint32;
description
" The total number of BFD control messages sent for this BFD
session";
}
leaf bfdSess-PerfCtrlPkt-Drop {
type uint32;
description
" The total number of BFD control messages received for this
session yet dropped for being invalid ";
}
leaf bfdSess-PerfCtrlPktDrop-LastTime {
type uint32;
description
" The value of sysUpTime on the most recent occasion at
which received the BFD control message for this session was
dropped. If no such up event exists, this object contains
a zero value ";
}
leaf bfdSess-PerfEchoPkt-In {
type uint32;
description
" The total number of BFD Echo messages received for this
BFD session ";
}
leaf bfdSess-PerfEchoPkt-Out {
type uint32;
description
" The total number of BFD Echo messages sent for this BFD
session ";
}
leaf bfdSess-PerfEchoPkt-Drop {
type uint32;
description
" The total number of BFD Echo messages received for this
session yet dropped for being invalid ";
}
leaf bfdSess-PerfEchoPktDrop-LastTime {
type uint32;
description
" The value of sysUpTime on the most recent occasion at
which received the BFD Echo message for this session was
dropped. If no such up event has been issued, this
object contains a zero value ";
}
leaf bfdSess-UpTime {
type uint32;
description
"The value of sysUpTime on the most recent occasion at which
the session came up. If no such event has been issued,
this object contains a zero value";
}
leaf bfdSess-PerfLastSessDownTime {
type uint32;
description
" The value of sysUpTime on the most recent occasion at
which the last time communication was lost with the
neighbor. If no down event has been issued, this object
contains a zero value ";
}
leaf bfdSess-PerfLastCommLostDiag {
type uint32;
description
" The BFD diag code for the last time communication was lost
with the neighbor. If such an event has not been issued,
this object contains a zero value";
}
leaf bfdSess-PerfSess-UpCount {
type uint32;
description
" The number of times this session has gone into the Up
state since the system last rebooted ";
}
leaf bfdSess-Perf-DiscTime {
type uint32;
description
" The value of sysUpTime on the most recent occasion at
which any one or more of the session counters suffered
a discontinuity ";
}
}
}
CV extension:
augment "/ gen-oam: cv / gen-oam:output/ gen-oam: maintenance-stats " {
case session-perform-bfdctr {
leaf bfdSess-PerfCtrlPkt-In {
type uint32;
description
" The total number of BFD control messages received for this
BFD session";
}
leaf bfdSess-PerfCtrlPkt-Out {
type uint32;
description
" The total number of BFD control messages sent for this BFD
session";
}
leaf bfdSess-PerfCtrlPkt-Drop {
type uint32;
description
" The total number of BFD control messages received for this
session yet dropped for being invalid ";
}
leaf bfdSess-PerfCtrlPktDrop-LastTime {
type uint32;
description
" The value of sysUpTime on the most recent occasion at
which received the BFD control message for this session was
dropped. If no such up event exists, this object contains
a zero value ";
}
}
leaf bfdSess-UpTime {
type uint32;
description
"The value of sysUpTime on the most recent occasion at which
the session came up. If no such event has been issued,
this object contains a zero value";
}
leaf bfdSess-PerfLastSessDownTime {
type uint32;
description
" The value of sysUpTime on the most recent occasion at
which the last time communication was lost with the
neighbor. If no down event has been issued, this object
contains a zero value ";
}
leaf bfdSess-PerfLastCommLostDiag {
type uint32;
description
" The BFD diag code for the last time communication was lost
with the neighbor. If such an event has not been issued,
this object contains a zero value";
}
leaf bfdSess-PerfSess-UpCount {
type uint32;
description
" The number of times this session has gone into the Up
state since the system last rebooted ";
}
leaf bfdSess-Perf-DiscTime {
type uint32;
description
" The value of sysUpTime on the most recent occasion at
which any one or more of the session counters suffered
a discontinuity ";
}
}
}
In BFD, the bfdsess-admin-status, bfdsess-oper-status, bfdsess-status and the bfdsess-remote-heard are used to indicate the session status. i.e. the bfdsess-admin-status denotes the desired operational status of the BFD session. And the bfdsess-oper-status denotes the actual operational status of the BFD session. The bfdsess-status is used to indicate the BFD session state. And the bfdsess-oper-status specifies the status of BFD packet reception from the remote system.
augment"/gen-oam:notifications/gen-oam:defect-condition-notification" {
leaf bfdsess-admin-status {
type enumeration{
enum enabled(1);
enum disabled(2);
enum adminDown(3);
enum down(4);
};
}
leaf bfdsess-oper-status {
type enumeration{
enum up(1);
enum down(2);
enum adminDown(3);
};
}
leaf bfdsess-status {
type uint32;
}
leaf bfdsess-remote-heard {
type boolean;
}
}
augment
/ gen-oam:domains/ gen-oam:domain/ gen-oam:MAs/gen-oam:MA:
+--rw technology-sub-type
augment
/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP:
+--:(bfdsrc-mep-udp)
+--rw bfdSess-Source-UdpPort? uint32
+--rw bfdSess-echoSrc-UdpPort? uint32
augment
/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP/ gen-oam:session:
+--rw session-status-bfd* [bfdsess-status]
+--rw bfdsess-admin-status? enumeration
+--rw bfdsess-oper-status? enumeration
+--rw bfdsess-status? uint32
+--rw bfdsess-remote-heard? boolean
augment
/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP/ gen-oam:session:
+--rw session-type* [bfdsess-type]
+--rw bfdsess-version-num? uint32
+--rw bfdsess-type? uint32
+--rw bfdsess-oper-mode? uint32
+--rw bfdsess-demandmode-desired? boolean
+--rw bfdsess-controlplanel-indep? boolean
+--rw bfdsess-multi-point? boolean
+--rw bfdsess-detect-mult? uint32
+--rw bfdsess-authpres? boolean
+--rw bfdsess-authentication-type uint32
augment
/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/ gen-oam:context-id:
+--:(context-id-bfdsess)
+--rw bfdsess-discriminator? uint32
+--rw bfdsess-remotediscr? uint32
+--rw bfdsess-dismap-index? uint32
augment
/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP/ gen-oam:session:
+--rw bfdsess-authentication*[ bfdsess-authentication-key]
+--rw bfdsess-authentication-keyid? uint32
+--rw bfdsess-authentication-key? uint32
augment
/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP/ gen-oam:session:
+--rw bfd-addr-type* [bfdSess-SrcAddr-Type, bfdSess-DstAddr-Type]
+--rw bfdSess-SrcAddr-Type uint32
+--rw bfdSess-DstAddr-Type uint32
augment
/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP/ gen-oam:session:
+--rw bfdSess-Destination-UdpPort uint32
augment
/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP/ gen-oam:session/gen-oam:interval:
+--rw bfdSess-DesiredMinTx-Interval? uint32
+--rw bfdSess-ReqMinRx-Interval? uint32
+--rw bfdSess-ReqMinEchoRx-Interval? unit32
+--rw bfdSess-Negotiated-Interval? uint32
+--rw bfdSess-NegotiatedEcho-Interval? uint32
augment
/gen-oam:cc/gen-oam:input:
+--ro technology-sub-type identityref
augment
/gen-oam:cc/gen-oam:input:
+--ro session-type* [bfdsess-type]
+--ro bfdsess-version-num? uint32
+--ro bfdsess-type? uint32
+--ro bfdsess-oper-mode? uint32
+--ro bfdsess-demandmode-desired? boolean
+--ro bfdsess-controlplanel-indep? boolean
+--ro bfdsess-multi-point? boolean
+--ro bfdsess-detect-mult? uint32
+--ro bfdsess-authpres? boolean
+--ro bfdsess-authentication-type uint32
augment
/gen-oam:cc/gen-oam:input:
+--ro (context-id)?
+--:(context-id-bfdsess)
+--ro bfdsess-discriminator? uint32
+--ro bfdsess-remotediscr? uint32
+--ro bfdsess-dismap-index? uint32
augment
/gen-oam:cc/gen-oam:input:
+--ro bfdsess-authentication*[bfdsess-authentication-key]
+--ro bfdsess-authentication-keyid? uint32
+--ro bfdsess-authentication-key? uint32
augment
/gen-oam:cc/gen-oam:input:
+--ro bfd-addr-type* [bfdSess-SrcAddr-Type,bfdSess-DstAddr-Type]
+--ro bfdSess-SrcAddr-Type uint32
+--ro bfdSess-DstAddr-Type uint32
augment
/gen-oam:cc/gen-oam:input/gen-oam:source-mep:
+--rw bfdSess-Source-UdpPort? uint32
+--rw bfdSess-echoSrc-UdpPort? uint32
augment
/gen-oam:cc/gen-oam:input/gen-oam:destination-mep:
+--rw bfdSess-Destination-UdpPort uint32
augment
/gen-oam:cc/gen-oam:input:
+--ro session-interface if:interface-ref
augment
/gen-oam:cc/gen-oam:input:
+--ro session-ttl uint32
augment
/gen-oam:cc/gen-oam:input:
+--ro bfdSess-DesiredMinTx-Interval? uint32
+--ro bfdSess-ReqMinRx-Interval? uint32
+--ro bfdSess-ReqMinEchoRx-Interval? unit32
+--ro bfdSess-Negotiated-Interval? uint32
+--ro bfdSess-NegotiatedEcho-Interval? uint32
augment
/gen-oam:cc/gen-oam:output/gen-oam:source-mep:
+--rw bfdSess-echoSrc-UdpPort? uint32
augment
/gen-oam:cc/gen-oam:output/gen-oam:destination-mep:
+--rw bfdSess-Destination-UdpPort uint32
augment
/gen-oam:cc/gen-oam:output/gen-oam:maintenance-stats:
+--:(session-perform-bfd)
+--ro bfdSess-PerfCtrlPkt-In? uint32
+--ro bfdSess-PerfCtrlPkt-Out? uint32
+--ro bfdSess-PerfCtrlPkt-Drop? unit32
+--ro bfdSess-PerfCtrlPktDrop-LastTime? uint32
+--ro bfdSess-PerfEchoPkt-In? uint32
+--ro bfdSess-PerfEchoPkt-Out? uint32
+--ro bfdSess-PerfEchoPkt-Drop? unit32
+--ro bfdSess-PerfEchoPktDrop-LastTime? uint32
+--ro bfdSess-UpTime? uint32
+--ro bfdSess-PerfLastSessDownTime? uint32
+--ro bfdSess-PerfLastCommLostDiag? uint32
+--ro bfdSess-PerfSess-UpCount? uint32
+--ro bfdSess-Perf-DiscTime? uint32
augment
/gen-oam:cv/gen-oam:input:
+--ro technology-sub-type identityref
augment
/gen-oam:cv/gen-oam:input:
+--ro session-type-bfd* [bfdsess-type]
+--ro bfdsess-version-num? uint32
+--ro bfdsess-type? uint32
+--ro bfdsess-oper-mode? uint32
+--ro bfdsess-demandmode-desired? boolean
+--ro bfdsess-controlplanel-indep? boolean
+--ro bfdsess-multi-point? boolean
+--ro bfdsess-detect-mult? uint32
+--ro bfdsess-authpres? boolean
+--ro bfdsess-authentication-type uint32
augment
/gen-oam:cv/gen-oam:input:
+--ro (context-id)?
+--:(context-id-bfdsess)
+--ro bfdsess-discriminator? uint32
+--ro bfdsess-remotediscr? uint32
+--ro bfdsess-dismap-index? uint32
augment
/gen-oam:cv/gen-oam:input:
+--ro bfdsess-authentication*[bfdsess-authentication-key]
+--ro bfdsess-authentication-keyid? uint32
+--ro bfdsess-authentication-key? uint32
augment
/gen-oam:cv/gen-oam:input:
+--ro bfd-addr-type* [bfdSess-SrcAddr-Type,bfdSess-DstAddr-Type]
+--ro bfdSess-SrcAddr-Type uint32
+--ro bfdSess-DstAddr-Type uint32
augment
/gen-oam:cv/gen-oam:input/gen-oam:source-mep:
+--rw bfdSess-Source-UdpPort? uint32
augment
/gen-oam:cv/gen-oam:input/gen-oam:destination-mep:
+--rw bfdSess-Destination-UdpPort uint32
augment
/gen-oam:cv/gen-oam:input:
+--ro session-interface if:interface-ref
augment
/gen-oam:cv/gen-oam:input:
+--ro session-ttl uint32
augment
/gen-oam:cv/gen-oam:input:
+--ro bfdSess-DesiredMinTx-Interval? uint32
+--ro bfdSess-ReqMinRx-Interval? uint32
+--ro bfdSess-ReqMinEchoRx-Interval? uint32
+--ro bfdSess-Negotiated-Interval? uint32
+--ro bfdSess-NegotiatedEcho-Interval? uint32
augment
/gen-oam:cv/gen-oam:output/gen-oam:source-mep:
+--rw bfdSess-echoSrc-UdpPort? uint32
augment
/gen-oam:cv/gen-oam:output/gen-oam:destination-mep:
+--rw bfdSess-Destination-UdpPort uint32
augment
/gen-oam:cv/gen-oam:output/gen-oam:maintenance-stats:
+--:(session-perform-bfd)
+--ro bfdSess-PerfCtrlPkt-In? uint32
+--ro bfdSess-PerfCtrlPkt-Out? uint32
+--ro bfdSess-PerfCtrlPkt-Drop? unit32
+--ro bfdSess-PerfCtrlPktDrop-LastTime? uint32
+--ro bfdSess-UpTime? uint32
+--ro bfdSess-PerfLastSessDownTime? uint32
+--ro bfdSess-PerfLastCommLostDiag? uint32
+--ro bfdSess-PerfSess-UpCount? uint32
+--ro bfdSess-Perf-DiscTime? uint32
Augment
/gen-oam:notifications/gen-oam:defect-condition-notification:
+--ro session-status * [bfdsess-status]
+--ro bfdsess-admin-status? enumeration
+--ro bfdsess-oper-status? enumeration
+--ro bfdsess-status? uint32
+--ro bfdsess-remote-heard? boolean
Data hierarchy of BFD OAM
The complete data hierarchy related to the OAM YANG model is presented below.
<CODE BEGINS> file "xxx.yang"
module bfd {
namespace "urn:ietf:params:xml:ns:yang:bfd";
prefix bfd;
import ietf-management-oam {
prefix goam;
}
import ietf-inet-types {
prefix inet;
}
import ietf-interfaces {
prefix if;
}
import ietf-yang-types {
prefix yang;
}
revision 2014-08-30 {
description
"Initial revision.";
}
identity bfd {
base bfd:technology-types;
description
"bfd type";
}
identity bfd {
base moam:command-sub-type;
}
identity bfd-contiuity-check {
base moam:command-sub-type;
}
identity bfd-connectity-verification {
base moam:command-sub-type;
}
identity technology-sub-type {
description
" In BFD, different encapsulation types such as IP/UDP, PW-ACH can be employed.
"technology-sub-type" further identifies the encapsulation type within the BFD.
Technology sub-type is defined as an identity type. This allows different
encapsulation types to augment BFD OAM YANG model to include encapsulation
type specific extensions without redefining common BFD definitions.
Instead of defining seperate models for each such encapsulation
we define technology sub type. Technology subtype is associated at MEG level" }
augment "/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA " {
leaf technology-sub-type {
type identityref {
base technology-sub-type;
}
}
}
augment
"/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP/ gen-oam:session "{
list session-status {
key " bfdsess-status ";
leaf bfdsess-admin-status {
type enumeration{
enum enabled(1);
enum disabled(2);
enum adminDown(3);
enum down(4);
};
description
" Denotes the desired operational status of the BFD session.
A transition to enabled(1) will start the BFD state machine
for the session. The state machine will have an initial
state of down(2).
A transition to disabled(2) will stop the BFD state machine
for the session. The state machine may first transition to
adminDown(1) prior to stopping.
A transition to adminDown(3) will cause the BFD state
machine to transition to adminDown(1) and will cause the
session to remain in this state.
A transition to down(4) will cause the BFD state machine
to transition to down(2) and will cause the session to
remain in this state";
}
leaf bfdsess-oper-status {
type enumeration{
enum up(1);
enum down(2);
enum adminDown(3);
};
description
" Denotes the actual operational status of the BFD session.
If the value of bfdOperStatus is down(2), this value MUST
eventually be down(2) as well. If the value of
bfdOperStatus is adminDown(3), this value MUST eventually
be adminDown(3) as well ";
}
leaf bfdsess-status {
type uint32;
description
" Configured BFD session state ";
}
leaf bfdsess-remote-heard {
type boolean;
description
" This leaf specifies the status of BFD packet reception from
the remote system. Specifically, it is set to true(1) if
the local system is actively receiving BFD packets from the
remote system and is set to false(2) if the local system
has not received BFD packets recently (within the detection
time) or if the local system is attempting to tear down
the BFD session ";
}
}
}
augment
"/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP / gen-oam:session " {
list session-type {
key " bfdsess-type ";
leaf bfdsess-version-num {
type uint32;
description
" The version number of the BFD protocol that this session
is running in. Write access is available for this object
to provide the ability to set the desired version for this
BFD session ";
}
leaf bfdsess-type {
type uint32;
description
" This leaf specifies the type of this BFD session ";
}
leaf bfdsess-oper-mode {
type uint32;
description
" This object specifies the operational mode of this
BFD session ";
}
leaf bfdsess-demandmode-desired {
type boolean;
description
" This leaf indicates the local system's
desire to use Demand mode. Specifically, it is set
to true(1) if the local system wishes to use
Demand mode or false(2) if not ";
}
leaf bfdsess-controlplanel-indep {
type boolean;
description
" This leaf indicates the local system's
ability to continue to function through a disruption of
the control plane. Specifically, it is set
to true(1) if the local system BFD implementation is
independent of the control plane. Otherwise, the
value is set to false(2) ";
}
leaf bfdsess-multi-point {
type boolean;
description
" This leaf indicates the Multipoint (M) bit for this
session. It is set to true(1) if the Multipoint (M) bit is
set to 1. Otherwise, the value is set to false(2) ";
}
leaf bfdsess-detect-mult {
type uint32;
description
" This leaf specifies the Detect time multiplier ";
}
leaf bfdsess-authpres {
type boolean;
description
" This leaf indicates the local system's
desire to use authentication. Specifically, it is set
to true(1) if the local system wishes the session
to be authenticated or false(2) if not";
}
leaf bfdsess-authentication-type {
type uint32;
description
" The authentication type used for this BFD session.
This field is valid only when the Authentication
Present bit is set ";
}
}
}
augment
"/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/ gen-oam:context-id " {
case context-id-bfdsess {
leaf bfdsess-discriminator {
type uint32;
description
" This leaf specifies the local discriminator for this BFD
session, which is used to uniquely identify it ";
}
leaf bfdsess-remotediscr {
type uint32;
description
" This leaf specifies the session discriminator chosen
by the remote system for this BFD session. The value may
be zero(0) if the remote discriminator is not yet known
or if the session is in the down or adminDown(1) state ";
}
leaf bfdsess-dismap-index{
type uint32;
description
" This leaf specifies a mapping between a
local discriminator and a BFD session ";
}
}
}
augment
"/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP / gen-oam:session " {
list bfdsess-authentication {
key " bfdsess-authentication-keyid,bfdsess-authentication-key ";
leaf bfdsess-authentication-keyid {
type uint32;
description
" This leaf specifies the authentication key ID in use for this session.
This object permits multiple keys to be active simultaneously.
The value -1 indicates that no authentication key ID will
be present in the optional BFD Authentication Section ";
}
leaf bfdsess-authentication-key {
type uint32;
description
" This leaf specifies the authentication key. When the
bfdSess-Authentication-Type is simplePassword(1), the value
of this object is the password present in the BFD packets.
When the bfdSess-Authentication-Type is one of the keyed
authentication types, this value is used in the
computation of the key present in the BFD authentication
packet ";
}
}
}
augment
"/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP / gen-oam:session " {
list bfd-addr-type {
key " bfdSess-SrcAddr-Type,bfdSess-DstAddr-Type ";
leaf bfdSess-SrcAddr-Type {
description
" This leaf specifies the IP address type of the source IP
address of this BFD session. The value of unknown(0) is
allowed only when the session is singleHop(1) and the
source IP address of this BFD session is derived from
the outgoing interface, or when the BFD session is not
associated with a specific interface. If any other
unsupported values are attempted in a set operation, the
agent MUST return an inconsistentValue error ";
type uint32;
}
leaf bfdSess-DstAddr-Type {
description
" This leaf specifies the IP address type of the neighboring
IP address that is being monitored with this BFD session.
The value of unknown(0) is allowed only when the session is
singleHop(1) and the outgoing interface is of type
point to point, or when the BFD session is not associated
with a specific interface. If any other unsupported values
are attempted in a set operation, the agent MUST return an
inconsistentValue error ";
type uint32;
}
}
}
augment
"/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP"{
leaf bfdSess-Source-UdpPort {
description
" This leaf specifies the source UDP port number used
for this BFD session's Control packets. The value may be
zero(0) if the session is in adminDown(1) state. Upon
creation of a new BFD session via this, the value of
zero(0) specified would permit the implementation to
choose its own source port number ";
type uint32;
}
leaf bfdSess-echoSrc-Udp{
description
" This leaf specifies the source UDP port number used for
this BFD session's Echo packets. The value may be zero(0)
if the session is not running in the Echo mode, or the
session is in adminDown(1) state. Upon creation of a new
BFD session via this, the value of zero(0) would
permit the implementation to choose its own source port
number ";
type uint32;
}
}
augment
"/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP/moam:session "{
leaf bfdSess-Destination-UdpPort {
description
" This leaf specifies the destination UDP port number
used for this BFD session's Control packets. The value
may be zero(0) if the session is in adminDown(1) state";
type uint32;
}
}
augment
"/gen-oam:domains/gen-oam:domain/gen-oam:MAs/gen-oam:MA/gen-oam:MEP
/gen-oam:session/gen-oam:interval " {
choice bfdSess-DesiredMinTx-Interval {
description
" This leaf specifies the minimum interval, in
microseconds, that the local system would like to use
when transmitting BFD Control packets. The value of
zero(0) is reserved in this case and should not be
used ";
type uint32;
}
choice bfdSess-ReqMinRx-Interval {
description
" This leaf specifies the minimum interval, in
microseconds, between received BFD Control packets the
local system is capable of supporting. The value of
zero(0) can be specified when the transmitting system
does not want the remote system to send any periodic BFD
Control packets ";
type uint32;
}
choice bfdSess-ReqMinEchoRx-Interval {
description
" This leaf specifies the minimum interval, in
microseconds, between received BFD Echo packets that this
system is capable of supporting. The value must be zero(0) if
this is a multihop BFD session ";
type uint32;
}
choice bfdSess-Negotiated-Interval {
description
" This leaf specifies the negotiated interval, in
microseconds, that the local system is transmitting
BFD Control packets ";
type uint32;
}
choice bfdSess-NegotiatedEcho-Interval {
description
" This leaf specifies the negotiated interval, in
microseconds, that the local system is transmitting
BFD Echo packets. The value is expected to be zero if
the sessions are not running in Echo mode ";
type uint32;
}
}
augment "/gen-oam:cc/gen-oam:input " {
leaf technology-sub-type {
type identityref {
base technology-sub-type;
}
}
}
augment "/gen-oam:cc/gen-oam:input " {
list session-type{
key " bfdsess-type ";
leaf bfdsess-version-num {
type uint32;
}
leaf bfdsess-type {
type uint32;
}
leaf bfdsess-oper-mode {
type uint32;
}
leaf bfdsess-demandmode-desired {
type boolean;
}
leaf bfdsess-controlplanel-indep {
type boolean;
}
leaf bfdsess-multi-point {
type boolean;
}
leaf bfdsess-detect-mult {
type uint32;
}
leaf bfdsess-authpres {
type boolean;
}
leaf bfdsess-authentication-type {
type uint32;
}
}
}
augment
"/gen-oam:cc/gen-oam:input " {
list session-status {
key " bfdsess-status "
leaf bfdsess-admin-status {
type enumeration{
enum enabled(1);
enum disabled(2);
enum adminDown(3);
enum down(4);
};
}
leaf bfdsess-oper-status {
type enumeration{
enum up(1);
enum down(2);
enum adminDown(3);
};
}
leaf bfdsess-status {
type uint32;
}
leaf bfdsess-remote-heard {
type boolean;
}
}
}
augment
"/gen-oam:cc/gen-oam:input " {
choice context-id{
case context-id-bfdsess {
leaf bfdsess-discriminator {
type uint32;
}
leaf bfdsess-remotediscr {
type uint32;
}
leaf bfdsess-dismap-index {
type uint32;
}
}
}
}
augment
"/gen-oam:cc/gen-oam:input " {
list bfdsess-authentication {
key"bfdsess-authentication-keyid,bfdsess-authentication-key ";
leaf bfdsess-authentication-keyid {
type uint32;
}
leaf bfdsess-authentication-key {
type uint32;
}
}
}
augment
"/gen-oam:cc/gen-oam:input " {
leaf bfdSess-SrcAddr-Type {
type uint32;
}
leaf bfdSess-DstAddr-Type {
type uint32;
}
}
}
augment
"/gen-oam:cc/gen-oam:input " {
leaf bfdSess-Source-UdpPort{
type uint32;
}
leaf bfdSess-echoSrc-Udp{
type uint32;
}
}
augment
"/gen-oam:cc/gen-oam:input " {
leaf bfdSess-Destination-UdpPort {
type uint32;
}
}
augment
"/gen-oam:cc/gen-oam:input "{
list session-interval {
key " bfdSess-DesiredMinTx-Interval ";
leaf bfdSess-DesiredMinTx-Interval {
type uint32;
}
leaf bfdSess-ReqMinRx-Interval {
type uint32;
}
leaf bfdSess-ReqMinEchoRx-Interval {
type uint32;
}
leaf bfdSess-Negotiated-Interval {
type uint32;
}
leaf bfdSess-NegotiatedEcho-Interval {
type uint32;
}
}
}
augment
"/gen-oam:cc/gen-oam:output " {
leaf bfdSess-Source-UdpPort {
type uint32;
}
leaf bfdSess-echoSrc-Udp{
type uint32;
}
}
augment
"/gen-oam:cc/gen-oam:output " {
leaf bfdSess-Destination-UdpPort {
type uint32;
}
}
augment
"/gen-oam:cc/gen-oam:output /gen-oam: maintenance-stats " {
case session-perform-bfd {
leaf bfdSess-PerfCtrlPkt-In {
type uint32;
description
" The total number of BFD control messages received for this
BFD session";
}
leaf bfdSess-PerfCtrlPkt-Out {
type uint32;
description
" The total number of BFD control messages sent for this BFD
session";
}
leaf bfdSess-PerfCtrlPkt-Drop {
type uint32;
description
" The total number of BFD control messages received for this
session yet dropped for being invalid ";
}
leaf bfdSess-PerfCtrlPktDrop-LastTime {
type uint32;
description
" The value of sysUpTime on the most recent occasion at
which received the BFD control message for this session was
dropped. If no such up event exists, this object contains
a zero value ";
}
leaf bfdSess-PerfEchoPkt-In {
type uint32;
description
" The total number of BFD Echo messages received for this
BFD session ";
}
leaf bfdSess-PerfEchoPkt-Out {
type uint32;
description
" The total number of BFD Echo messages sent for this BFD
session ";
}
leaf bfdSess-PerfEchoPkt-Drop {
type uint32;
description
" The total number of BFD Echo messages received for this
session yet dropped for being invalid ";
}
leaf bfdSess-PerfEchoPktDrop-LastTime {
type uint32;
description
" The value of sysUpTime on the most recent occasion at
which received the BFD Echo message for this session was
dropped. If no such up event has been issued, this
object contains a zero value ";
}
leaf bfdSess-UpTime {
type uint32;
description
"The value of sysUpTime on the most recent occasion at which
the session came up. If no such event has been issued,
this object contains a zero value";
}
leaf bfdSess-PerfLastSessDownTime {
type uint32;
description
" The value of sysUpTime on the most recent occasion at
which the last time communication was lost with the
neighbor. If no down event has been issued, this object
contains a zero value ";
}
leaf bfdSess-PerfLastCommLostDiag {
type uint32;
description
" The BFD diag code for the last time communication was lost
with the neighbor. If such an event has not been issued,
this object contains a zero value";
}
leaf bfdSess-PerfSess-UpCount {
type uint32;
description
" The number of times this session has gone into the Up
state since the system last rebooted ";
}
leaf bfdSess-Perf-DiscTime {
type uint32;
description
" The value of sysUpTime on the most recent occasion at
which any one or more of the session counters suffered
a discontinuity ";
}
}
}
augment "/gen-oam:cv/gen-oam:input " {
leaf technology-sub-type {
type identityref {
base technology-sub-type;
}
}
}
augment "/gen-oam:cv/gen-oam:input " {
list session-type{
key " bfdsess-type ";
leaf bfdsess-version-num {
type uint32;
}
leaf bfdsess-type {
type uint32;
}
leaf bfdsess-oper-mode {
type uint32;
}
leaf bfdsess-demandmode-desired {
type boolean;
}
leaf bfdsess-controlplanel-indep {
type boolean;
}
leaf bfdsess-multi-point {
type boolean;
}
leaf bfdsess-detect-mult {
type uint32;
}
leaf bfdsess-authpres {
type boolean;
}
leaf bfdsess-authentication-type {
type uint32;
}
}
}
augment
"/gen-oam:cv/gen-oam:input " {
list session-status {
key " bfdsess-status "
leaf bfdsess-admin-status {
type enumeration{
enum enabled(1);
enum disabled(2);
enum adminDown(3);
enum down(4);
};
}
leaf bfdsess-oper-status {
type enumeration{
enum up(1);
enum down(2);
enum adminDown(3);
};
}
leaf bfdsess-status {
type uint32;
}
leaf bfdsess-remote-heard {
type boolean;
}
}
}
augment
"/gen-oam:cv/gen-oam:input " {
choice context-id{
case context-id-bfdsess {
leaf bfdsess-discriminator {
type uint32;
}
leaf bfdsess-remotediscr {
type uint32;
}
leaf bfdsess-dismap-index {
type uint32;
}
}
}
}
augment
"/gen-oam:cv/gen-oam:input " {
list bfdsess-authentication {
key"bfdsess-authentication-keyid,bfdsess-authentication-key ";
leaf bfdsess-authentication-keyid {
type uint32;
}
leaf bfdsess-authentication-key {
type uint32;
}
}
}
augment
"/gen-oam:cv/gen-oam:input " {
leaf bfdSess-SrcAddr-Type {
type uint32;
}
leaf bfdSess-DstAddr-Type {
type uint32;
}
}
}
augment
"/gen-oam:cv/gen-oam:input " {
leaf bfdSess-Source-UdpPort{
type uint32;
}
}
augment
"/gen-oam:cv/gen-oam:input " {
leaf bfdSess-Destination-UdpPort {
type uint32;
}
}
augment
"/gen-oam:cv/gen-oam:input "{
list session-interval {
key " bfdSess-DesiredMinTx-Interval ";
leaf bfdSess-DesiredMinTx-Interval {
type uint32;
}
leaf bfdSess-ReqMinRx-Interval {
type uint32;
}
leaf bfdSess-ReqMinEchoRx-Interval {
type uint32;
}
leaf bfdSess-Negotiated-Interval {
type uint32;
}
leaf bfdSess-NegotiatedEcho-Interval {
type uint32;
}
}
}
augment
"/gen-oam:cv/gen-oam:output " {
leaf bfdSess-Source-UdpPort {
type uint32;
}
}
augment
"/gen-oam:cv/gen-oam:output " {
leaf bfdSess-Destination-UdpPort {
type uint32;
}
}
augment
"/gen-oam:cv/gen-oam:output /gen-oam: maintenance-stats " {
case session-perform-bfd {
leaf bfdSess-PerfCtrlPkt-In {
type uint32;
description
" The total number of BFD control messages received for this
BFD session";
}
leaf bfdSess-PerfCtrlPkt-Out {
type uint32;
description
" The total number of BFD control messages sent for this BFD
session";
}
leaf bfdSess-PerfCtrlPkt-Drop {
type uint32;
description
" The total number of BFD control messages received for this
session yet dropped for being invalid ";
}
leaf bfdSess-PerfCtrlPktDrop-LastTime {
type uint32;
description
" The value of sysUpTime on the most recent occasion at
which received the BFD control message for this session was
dropped. If no such up event exists, this object contains
a zero value ";
}
leaf bfdSess-UpTime {
type uint32;
description
"The value of sysUpTime on the most recent occasion at which
the session came up. If no such event has been issued,
this object contains a zero value";
}
leaf bfdSess-PerfLastSessDownTime {
type uint32;
description
" The value of sysUpTime on the most recent occasion at
which the last time communication was lost with the
neighbor. If no down event has been issued, this object
contains a zero value ";
}
leaf bfdSess-PerfLastCommLostDiag {
type uint32;
description
" The BFD diag code for the last time communication was lost
with the neighbor. If such an event has not been issued,
this object contains a zero value";
}
leaf bfdSess-PerfSess-UpCount {
type uint32;
description
" The number of times this session has gone into the Up
state since the system last rebooted ";
}
leaf bfdSess-Perf-DiscTime {
type uint32;
description
" The value of sysUpTime on the most recent occasion at
which any one or more of the session counters suffered
a discontinuity ";
}
}
}
augment"/gen-oam:notifications/gen-oam:defect-condition-notification
" {
leaf bfdsess-admin-status {
type enumeration{
enum enabled(1);
enum disabled(2);
enum adminDown(3);
enum down(4);
};
}
leaf bfdsess-oper-status {
type enumeration{
enum up(1);
enum down(2);
enum adminDown(3);
};
}
leaf bfdsess-status {
type uint32;
}
leaf bfdsess-remote-heard {
type boolean;
}
}
<CODE ENDS>
<CODE BEGINS> file "xxx.yang"
This document defines default configuration that MUST be present in the devices that comply with this document. Base Mode allows users to have zero-touch experience. Details of BFD Base Mode for OAM are defined in [RFC7331].
TBD.
TBD.
| [I-D.tissa-lime-yang-oam-model] | Senevirathne, T., Finn, N., Kumar, D., Salam, S. and Q. Wu, "Generic YANG Data Model for Operations, Administration, and Maintenance (OAM)", Internet-Draft draft-tissa-lime-yang-oam-model-02, October 2014. |
| [I-D.wang-lime-rpc-yang-oam-management] | Wang, Z., "Additional RPC definitions to Generic YANG Data Model for layer Independent OAM Management", October 2014. |
| [RFC2119] | Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", March 1997. |
| [RFC5880] | Katz, D. and D. Ward, "Bidirectional Forwarding Detection (BFD)", RFC 5880, June 2010. |
| [RFC6020] | Bjorklund, M., "YANG - A Data Modeling Language for the Network Configuration Protocol (NETCONF)", RFC 6020, October 2010. |
| [RFC6241] | Enns, R., Bjorklund, M., Schoenwaelder, J. and A. Bierman, "Network Configuration Protocol (NETCONF)", RFC 6241, June 2011. |
| [RFC7331] | Nadeau, T., Ali, Z. and N. Akiya, "Bidirectional Forwarding Detection (BFD) Management Information Base", RFC 7331, August 2014. |