No relevant resource is found in the selected language.

This site uses cookies. By continuing to browse the site you are agreeing to our use of cookies. Read our privacy policy>Search

Reminder

To have a better experience, please upgrade your IE browser.

upgrade

Configuration Guide - Network Management and Monitoring

CloudEngine 12800 and 12800E V200R005C10

This document describes the configurations of Network Management and Monitoring, including SNMP, RMON, LLDP, NQA, Service Diagnosis, Mirroring, Packet Capture, sFlow, and NETCONF.
Rate and give feedback:
Huawei uses machine translation combined with human proofreading to translate this document to different languages in order to help you better understand the content of this document. Note: Even the most advanced machine translation cannot match the quality of professional translators. Huawei shall not bear any responsibility for translation accuracy and it is recommended that you refer to the English document (a link for which has been provided).
Basic Concepts of RESTCONF

Basic Concepts of RESTCONF

NETCONF Network Architecture

Figure 4-1 describes the basic RESTCONF network architecture. Main elements in the RESTCONF network architecture are as follows:

  • RESTCONF client

    The RESTCONF client uses NETCONF to manage network devices. The client sends a request to the server to create, delete, modify, or query one or more data records.

  • RESTCONF server

    The server maintains managed network devices, responds to client requests, and reports management data to the client. After receiving a request sent by the client, the server parses the request, processes the request, and sends a response to the client.

Figure 4-1 NETCONF network architecture

The data that a RESTCONF client obtains from a running RESTCONF server includes configuration data and status data.

  • The client can query the status data and configuration data.
  • The RESTCONF client can modify configuration data and operate the configuration data so that the status of the RESTCONF server migrates to a user-expected status.
  • The RESTCONF client cannot modify status data. Status data includes the running status of the RESTCONF server and other statistics.

RESTCONF Modeling Language

RESTCONF uses YANG as its modeling language. YANG is a data modeling language used to model configuration data and status data in RESTCONF.

The YANG data model is a machine-oriented model interface, which defines data structures and constraints to provide more flexible and complete data description.

Basic Concepts

The RESTCONF client and server run HTTPs to establish a secure and connection-oriented session. The client sends a request to the server. After processing the user request, the server replies with a response to the client. The request and response messages are coded in either XML or JavaScript Object Notation (JSON) format.

Message coding

  • XML encoding

    XML, the encoding format used by RESTCONF, enables the use of a text file to represent complex hierarchical data. A traditional text tool or XML-specific compilation tool can be used to read, save, and operate configuration data.

    XML-based network management uses XML to describe managed data and management operations so that management information can be parsed by networking devices.

    The XML encoding format file header is <?xml version= "1.0" encoding= "UTF-8" ?>, where:
    • <?: is the start of an instruction.
    • xml: identifies an XML file.
    • version="1.0": The XML1.0 standard version is used.
    • encoding: is the character set encoding format. Only UTF-8 encoding is supported.
    • ?>: is the end of an instruction.
  • JSON encoding

    JavaScript Object Notation (JSON) is a lightweight text data exchange format. JSON uses JavaScript syntax to describe data objects, but JSON is still independent of languages and platforms, making it easier to understand.

    JSON is similar to XML, but JSON is shorter, faster, and easier to parse than XML.

    JSON syntax rules are as follows:
    • Data is in name/value pairs.
    • Data is separated by commas (,).
    • An object is saved in braces ({}).
    • An array is saved in brackets ([]).
    The JSON format is as follows:
    • JSON name/value pair. For example:
      "Name": "Apple"
    • JSON value: The value can be a number, string, logical value, array, object, or null. For example:
      "Price": 3.99
    • JSON object: An object is an unordered collection of name-value pairs. An object starts with a left brace ({} and ends with a right brace (}). Each name is followed by a colon (:), and name/value pairs are separated by commas (,). For example:

      { "firstName": "Brett", "lastName":"McLaughlin", "email": "aaaa" }
    • JSON array: An array is an ordered list of values. An array starts with a left bracket ([) and ends with a right bracket (]). Arrays are separated by commas (,). For example:

      { "people": [ 
        { "firstName": "Brett", "lastName":"McLaughlin", "email": "aaaa" }, 
        { "firstName": "Jason", "lastName":"Hunter", "email": "bbbb"} 
        ]
      }

RESTCONF capability

In addition to providing a group of basic operations, RESTCONF also provides extended capabilities supported by the device. The capability set is used to declare that the device supports these extended capabilities. Each capability set is identified by a uniform resource identifier (URI).

Table 4-2 describes the standard capability sets supported by RESTCONF.

Table 4-2 Capability set description

Name

URI

Description of Capability Set Operations

depth

urn:ietf:params:xml:restconf:capability:depth:1.0

A device supports the "depth" query parameter of version 1.0. This capability indicates that the device supports a specified maximum number of data query times.

fields

urn:ietf:params:xml:restconf:capability:fields:1.0

The device supports the "fields" query parameter of version 1.0. This capability indicates that a device can obtain the subset of the target data content.

with-defaults

urn:ietf:params:xml:restconf:capability:with-defaults:1.0

The device supports the "with-defaults" query parameter of version 1.0. This capability indicates that a device can process the default value display mode.

defaults

urn:ietf:params:restconf:capability:defaults:1.0

This capability indicates the default value of the "with-defaults" query parameter.

NOTE:
If the "with-defaults" query parameter is not specified in the request URI, the default value is report-all (to query all nodes).
Translation
Download
Updated: 2019-04-20

Document ID: EDOC1100075344

Views: 29093

Downloads: 29

Average rating:
This Document Applies to these Products
Related Documents
Related Version
Share
Previous Next