SNMP, NETCONF, YANG, RESTCONF and Network Automation

In the past life as a network engineer, when working on a large deployment, I have relied on the Excel spreadsheet with macros to generate configuration files.  Copy and Paste – Job done.  Any change in the script, I had to re-run the whole process and trust me it was not fun.

Network monitoring software like HP OpenView and CiscoWorks, offered limited functionality around automation as they were primarily used for monitoring and configuration management.  Depending on the complexity of the change to be applied, using a combination of UNIX shell and Python scripts I have managed to get my way around.

I have always wanted to understand what was missing in the current management tools and what is coming down the line and now that every other technology is now a Software Defined (SD) something including Network, WAN, DC..its time that I dig deeper.  This blog will be an overview of the technologies and follow up getting started with NETCONF and YANG in the next few week.


A Simple Network Management  Protocol (SNMP) that can be used to configure and retrieve variables on a device.  MIB – A Management Information Base that defines all data managed by SNMP.

  • Transport over UDP
  • Stateless
  • Unable to backup and restore element
  •  Operations
    • GET
    • GET-NEXT
    • SET
    • TRAP ….

SNMP has been around for a long time and can also be used to configure variable on a device.  To Add VLAN requires a quite a few steps, and you would think, it will be easier to login to each switch/router and make that change and maybe this complexity is the reason why SNMP is rarely used for configuring devices.

A comprehensive list of shortcomings with SNMP discussed at the Network Management workshop in 2002 can be found here SNMP Framework Discussion


RFC 4741  The Network Configuration Protocol (NETCONF) provides mechanisms to install, manipulate, and delete the configuration of network devices. It uses an Extensible Markup Language (XML)-based data encoding for the configuration data as well as the protocol messages. The NETCONF protocol operations are realized on top of a simple Remote Procedure Call (RPC) layer.

  • Designed to be as a replacement for CLI
  • Transported over SSH (TCP)  and stateless
  • Service and Network management
  • Supports network wide transactions
  • Consistency check built in
  • Named data stores ex – Startup, Running, File/URL’s
  • Distinction between configuration and state data
  • XML Payload – Modelled in YANG

NETCONF can be conceptually partitioned into four layers:



As defined in the RFC 6020 YANG is a data modeling language used to model configuration and state data manipulated by the Network Configuration Protocol (NETCONF), NETCONF remote procedure calls, and NETCONF notifications.

YANG is a language used to model data for the NETCONF protocol. A YANG module defines a hierarchy of data that can be used for NETCONF- based operations, including configuration, state data, Remote Procedure Calls (RPCs), and notifications. This allows a complete description of all data sent between a NETCONF client and server

YANG is to NETCONF as MIB is to SNMP.

Next blog will be an attempt to setup ncclient and extract configuration from a network device. Fingers crossed..


RESTCONF is still a “work in progress” as defined “draft-ietf-netconf-restconf-05”.  

The NETCONF protocol defines configuration datastores and a set of Create, Retrieve, Update, Delete (CRUD) operations that can be used to access these datastores. The YANG language defines the syntax and semantics of datastore content, operational data, protocol operations, and event notifications. RESTCONF uses HTTP operations to provide CRUD operations on a NETCONF datastore containing YANG defined data

The one good point in and when its is standard if have some knowledge of HTTP operations this quote from the text will bring a smile “Since NETCONF protocol operations are not relevant,the user should not need any prior knowledge of NETCONF in order to use RESTCONF”

Both in Open Source world with OpenDaylight Foundation controller and Cisco commercial Cisco Open SDN Controller, NETCONF and RESTCONF are well on it way being integral part of the offerings.  Time will tell on as to when these products are widely adopted.




2 thoughts on “SNMP, NETCONF, YANG, RESTCONF and Network Automation

  1. Pingback: NETCONF, ncclient and Network Automation – Hemanth's Networking Blog

Leave a Comment