1 module ietf-netconf-monitoring {
6 "urn:ietf:params:xml:ns:yang:ietf-netconf-monitoring";
10 import ietf-yang-types {
13 import ietf-inet-types {
18 "IETF NETCONF (Network Configuration) Working Group";
21 "WG Web: <http://tools.ietf.org/wg/netconf/>
22 WG List: <mailto:netconf@ietf.org>
24 WG Chair: Mehmet Ersue
25 <mailto:mehmet.ersue@nsn.com>
28 <mailto:bertietf@bwijnen.net>
31 <mailto:mark.scott@ericsson.com>
33 Editor: Martin Bjorklund
34 <mailto:mbj@tail-f.com>";
37 "NETCONF Monitoring Module.
38 All elements in this module are read-only.
40 Copyright (c) 2010 IETF Trust and the persons identified as
41 authors of the code. All rights reserved.
43 Redistribution and use in source and binary forms, with or
44 without modification, is permitted pursuant to, and subject
45 to the license terms contained in, the Simplified BSD
46 License set forth in Section 4.c of the IETF Trust's
47 Legal Provisions Relating to IETF Documents
48 (http://trustee.ietf.org/license-info).
50 This version of this YANG module is part of RFC 6022; see
51 the RFC itself for full legal notices.";
53 revision "2010-10-04" {
54 description "Initial revision.";
56 "RFC 6022: YANG Module for NETCONF Monitoring";
61 typedef netconf-datastore-type {
74 "Enumeration of possible NETCONF datastore types.";
76 "RFC 4741: NETCONF Configuration Protocol";
82 "Base identity for NETCONF transport types.";
85 identity netconf-ssh {
88 "NETCONF over Secure Shell (SSH).";
90 "RFC 4742: Using the NETCONF Configuration Protocol
91 over Secure SHell (SSH)";
95 identity netconf-soap-over-beep {
98 "NETCONF over Simple Object Access Protocol (SOAP) over
99 Blocks Extensible Exchange Protocol (BEEP).";
101 "RFC 4743: Using NETCONF over the Simple Object
102 Access Protocol (SOAP)";
106 identity netconf-soap-over-https {
109 "NETCONF over Simple Object Access Protocol (SOAP)
110 over Hypertext Transfer Protocol Secure (HTTPS).";
112 "RFC 4743: Using NETCONF over the Simple Object
113 Access Protocol (SOAP)";
117 identity netconf-beep {
120 "NETCONF over Blocks Extensible Exchange Protocol (BEEP).";
122 "RFC 4744: Using the NETCONF Protocol over the
123 Blocks Extensible Exchange Protocol (BEEP)";
127 identity netconf-tls {
130 "NETCONF over Transport Layer Security (TLS).";
132 "RFC 5539: NETCONF over Transport Layer Security (TLS)";
136 identity schema-format {
138 "Base identity for data model schema languages.";
144 "W3C XML Schema Definition.";
146 "W3C REC REC-xmlschema-1-20041028:
147 XML Schema Part 1: Structures";
154 "The YANG data modeling language for NETCONF.";
156 "RFC 6020: YANG - A Data Modeling Language for the
157 Network Configuration Protocol (NETCONF)";
163 description "The YIN syntax for YANG.";
165 "RFC 6020: YANG - A Data Modeling Language for the
166 Network Configuration Protocol (NETCONF)";
173 "Regular Language for XML Next Generation (RELAX NG).";
175 "ISO/IEC 19757-2:2008: RELAX NG";
181 description "Relax NG Compact Syntax";
183 "ISO/IEC 19757-2:2008: RELAX NG";
187 grouping common-counters {
189 "Counters that exist both per session, and also globally,
190 accumulated from all sessions.";
192 type yang:zero-based-counter32;
194 "Number of correct <rpc> messages received.";
198 type yang:zero-based-counter32;
200 "Number of messages received when an <rpc> message was expected,
201 that were not correct <rpc> messages. This includes XML parse
202 errors and errors on the rpc layer.";
205 leaf out-rpc-errors {
206 type yang:zero-based-counter32;
208 "Number of <rpc-reply> messages sent that contained an
209 <rpc-error> element.";
212 leaf out-notifications {
213 type yang:zero-based-counter32;
215 "Number of <notification> messages sent.";
217 } // grouping common-counters
219 container netconf-state {
222 "The netconf-state container is the root of the monitoring
224 container capabilities {
226 "Contains the list of NETCONF capabilities supported by the
228 leaf-list capability {
231 "List of NETCONF capabilities supported by the server.";
233 } // container capabilities
235 container datastores {
237 "Contains the list of NETCONF configuration datastores.";
241 "List of NETCONF configuration datastores supported by
242 the NETCONF server and related information.";
244 type netconf-datastore-type;
246 "Name of the datastore associated with this list entry.";
251 "This container is present only if the datastore
254 "The NETCONF <lock> and <partial-lock> operations allow
255 a client to lock specific resources in a datastore. The
256 NETCONF server will prevent changes to the locked
257 resources by all sessions except the one that acquired
260 Monitoring information is provided for each datastore
261 entry including details such as the session that acquired
262 the lock, the type of lock (global or partial) and the
263 list of locked resources. Multiple locks per datastore
267 "Lock related parameters, common to both global and
269 leaf locked-by-session {
273 "The session ID of the session that has locked
274 this resource. Both a global lock and a partial
275 lock MUST contain the NETCONF session-id.
277 If the lock is held by a session that is not managed
278 by the NETCONF server (e.g., a CLI session), a session
279 id of 0 (zero) is reported.";
281 "RFC 4741: NETCONF Configuration Protocol";
286 type yang:date-and-time;
289 "The date and time of when the resource was
292 } // grouping lock-info
295 "Indicates if a global lock or a set of partial locks
297 container global-lock {
299 "Present if the global lock is set.";
301 } // container global-lock
305 "List of partial locks.";
307 "RFC 5717: Partial Lock Remote Procedure Call (RPC) for
313 "This is the lock id returned in the <partial-lock>
323 "The xpath expression that was used to request
324 the lock. The select expression indicates the
325 original intended scope of the lock.";
328 leaf-list locked-node {
329 type instance-identifier;
331 "The list of instance-identifiers (i.e., the
334 The scope of the partial lock is defined by the list
337 } // list partial-lock
338 } // choice lock-type
341 } // container datastores
345 "Contains the list of data model schemas supported by the
348 key "identifier version format";
350 "List of data model schemas supported by the server.";
354 "Identifier to uniquely reference the schema. The
355 identifier is used in the <get-schema> operation and may
356 be used for other purposes such as file retrieval.
358 For modeling languages that support or require a data
359 model name (e.g., YANG module name) the identifier MUST
360 match that name. For YANG data models, the identifier is
361 the name of the module or submodule. In other cases, an
362 identifier such as a filename MAY be used instead.";
368 "Version of the schema supported. Multiple versions MAY be
369 supported simultaneously by a NETCONF server. Each
370 version MUST be reported individually in the schema list,
371 i.e., with same identifier, possibly different location,
372 but different version.
374 For YANG data models, version is the value of the most
375 recent YANG 'revision' statement in the module or
376 submodule, or the empty string if no 'revision' statement
385 "The data modeling language the schema is written
386 in (currently xsd, yang, yin, rng, or rnc).
387 For YANG data models, 'yang' format MUST be supported and
388 'yin' format MAY also be provided.";
395 "The XML namespace defined by the data model.
397 For YANG data models, this is the module's namespace.
398 If the list entry describes a submodule, this field
399 contains the namespace of the module to which the
413 "One or more locations from which the schema can be
414 retrieved. This list SHOULD contain at least one
417 A schema entry may be located on a remote file system
418 (e.g., reference to file system for ftp retrieval) or
419 retrieved directly from a server supporting the
420 <get-schema> operation (denoted by the value 'NETCONF').";
423 } // container schemas
427 "The sessions container includes session-specific data for
428 NETCONF management sessions. The session list MUST include
429 all currently active NETCONF sessions.";
433 "All NETCONF sessions managed by the NETCONF server
434 MUST be reported in this list.";
440 "Unique identifier for the session. This value is the
441 NETCONF session identifier, as defined in RFC 4741.";
443 "RFC 4741: NETCONF Configuration Protocol";
453 "Identifies the transport for each session, e.g.,
454 'netconf-ssh', 'netconf-soap', etc.";
461 "The username is the client identity that was authenticated
462 by the NETCONF transport protocol. The algorithm used to
463 derive the username is NETCONF transport protocol specific
464 and in addition specific to the authentication mechanism
465 used by the NETCONF transport protocol.";
471 "Host identifier of the NETCONF client. The value
472 returned is implementation specific (e.g., hostname,
473 IPv4 address, IPv6 address)";
477 type yang:date-and-time;
480 "Time at the server at which the session was established.";
483 uses common-counters {
485 "Per-session counters. Zero based with following reset
487 - at start of a session
488 - when max value is reached";
491 } // container sessions
493 container statistics {
495 "Statistical data pertaining to the NETCONF server.";
496 leaf netconf-start-time {
497 type yang:date-and-time;
499 "Date and time at which the management subsystem was
504 type yang:zero-based-counter32;
506 "Number of sessions silently dropped because an
507 invalid <hello> message was received. This includes <hello>
508 messages with a 'session-id' attribute, bad namespace, and
509 bad capability declarations.";
513 type yang:zero-based-counter32;
515 "Number of sessions started. This counter is incremented
516 when a <hello> message with a <session-id> is sent.
518 'in-sessions' - 'in-bad-hellos' =
519 'number of correctly started netconf sessions'";
522 leaf dropped-sessions {
523 type yang:zero-based-counter32;
525 "Number of sessions that were abnormally terminated, e.g.,
526 due to idle timeout or transport close. This counter is not
527 incremented when a session is properly closed by a
528 <close-session> operation, or killed by a <kill-session>
532 uses common-counters {
534 "Global counters, accumulated from all sessions.
535 Zero based with following reset behaviour:
536 - re-initialization of NETCONF server
537 - when max value is reached";
539 } // container statistics
540 } // container netconf-state
544 "This operation is used to retrieve a schema from the
548 The NETCONF server returns the requested schema.
551 If requested schema does not exist, the <error-tag> is
554 If more than one schema matches the requested parameters, the
555 <error-tag> is 'operation-failed', and <error-app-tag> is
562 "Identifier for the schema list entry.";
568 "Version of the schema requested. If this parameter is not
569 present, and more than one version of the schema exists on
570 the server, a 'data-not-unique' error is returned, as
579 "The data modeling language of the schema. If this
580 parameter is not present, and more than one formats of
581 the schema exists on the server, a 'data-not-unique' error
582 is returned, as described above.";
589 "Contains the schema content.";