[Webinar] SpiraTest - Setting New Standards in Quality Assurance
Getting started with YANG
1. Automate | Orchestrate | Remediate
Getting Started with YANG
Yet Another Next Generation ...
2. What
is
YANG?
Data modeling language for the NETCONF
(network configuration protocol)
to model both configuration data as well as state data of network
elements
to define the format of event notifications emitted by network
elements
define the signature of remote procedure calls that can be
invoked on network elements via the NETCONF protocol
3. Some
history
SNMP was the first widely used network management protocol
SNMP based on the SMI (Structure of Management Information)
language had limitations wrt configuration management of network
elements
Lack of support for simple things like backup-and-restore of element
configuration
No concept of transactions (single- or multibox)
Many inherent limitations in SMI (e.g. label length)
Data modelling limitations for NETCONF led to the creation of a new
standard and YANG was adopted
SMIng (SMI v3.0) was the basis of YANG
The YANG language v1.0 was finalized in Oct 2010 by IETF NETCONF Data
Modeling Language Working Group (NETMOD), and is defined in RFC
6020
Version 1.1 is now being discussed by IETF
4. YANG
features
Human readable, and easy to learn representation
Hierarchical configuration data models
Reusable types and groupings (structured types)
Extensibility through augmentation mechanisms
Supports definition of operations (RPCs)
Formal constraints for configuration validation
Data modularity through modules and sub-modules
Well defined versioning rules
6. Some YANG
language
capabilities
Organization – Leaf, leaf-list, container, lists, grouping, choice
Data model structure – Module, submodule, augment, if-feature, when
Constraints – Must, unique, min-elements, max-elements, mandatory
Data types – Many built-in types, sub-typing, restrictions
Reusable groupings – grouping allows collections of nodes to be reused
augments inserts nodes into an existing hierarchy so they can augment
existing YANG modules, e.g. a standard module where the
implementation provides additional vendor specific data/service
deviations override nodes in an existing hierarchy so they can deviate from
existing YANG modules, e.g. a standard module where the
implementation cannot provide the data/service for a particular node
“rpc” statement defines methods, input and output parameters
7. YANG YAML RAML XML
Synonym Yet Another Next Generation YAML Ain't Markup Language Restful API Modeling Language eXtensible Markup Language
Purpose Config via NETCONF
object data serialization for
readability To describe REStful APIs To define structured data textually
Benefits
Easier to maintain configuration for
network devices Human readable data definition
Faster, easier and reusable API
definition
Better than proprietary binary data
formats
Configuration Support Yes No No Yes, but not easy
Transactions support Yes No No Yes, but not easy
Transport Independent No No Independent
Preceded by SMI v3 JSON YAML 1.2 -
Used in
Data modelling for networks.
Used in projects like OpenDayLight
Variety of projects esp in python
world for text representation of
object data. Eg.Openstack
Generating API documentation
and stubs for the server and
client
Where transport independence is
required along with textual data
definition
Comparison Matrix
8. Sample YANG
module acme-system {
namespace "http://acme.example.com/system";
prefix "acme”;
organization "ACME Inc.”;
contact "joe@acme.example.com";
description "The module for entities implementing the ACME system.”;
revision 2007-11-05 { description "Initial revision.”; }
container system {
leaf host-name {
type string;
description "Hostname for this system”;
}
}
}
9. YANG
promoters
Juniper brought XML-based configuration for NETCONF to the table
Tail-f (now acquired by Cisco) pioneered YANG
Ericsson helped in the adoption of YANG by helping it become a standard
Some enterprises that have provided YANG support in their offerings include:
Brocade
Huawei
Edgeware
Yuma
Oracle
10. Some YANG
supported
devices
1. Brocade - VCS Fabric Switches
2. Alaxala – Ethernet switches
3. Cisco – IOS 12.4(9)T and later, IOS XE 2.1 and later
4. Ericsson
5. Juniper Networks – JUNOS 7.5 and later
6. RuggedCom – Routers and switches, RX5000 and MX5000
7. Taseon – Intelligent optical networks, TN 320
8. Verivue – Next-generation video distribution, MDX 9020
9. Edgeware – Servers for on-demand TV, WTV-2X
10.Nexor – Messaging Gateways
11.Telco Systems – Carrier Ethernet Multiservice Aggregation, T-Metro 7224