[Docs] [txt|pdf] [Tracker] [WG] [Email] [Diff1] [Diff2] [Nits]

Versions: (draft-chisholm-netconf-monitoring) 00 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 RFC 6022

Network Working Group                                           M. Scott
Internet-Draft                                               S. Chisholm
Intended status: Standards Track                                  Nortel
Expires: December 27, 2008                                  M. Bjorklund
                                                          Tail-f Systems
                                                           June 25, 2008


                       NETCONF Monitoring Schema
                    draft-ietf-netconf-monitoring-02

Status of this Memo

   By submitting this Internet-Draft, each author represents that any
   applicable patent or other IPR claims of which he or she is aware
   have been or will be disclosed, and any of which he or she becomes
   aware will be disclosed, in accordance with Section 6 of BCP 79.

   Internet-Drafts are working documents of the Internet Engineering
   Task Force (IETF), its areas, and its working groups.  Note that
   other groups may also distribute working documents as Internet-
   Drafts.

   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."

   The list of current Internet-Drafts can be accessed at
   http://www.ietf.org/ietf/1id-abstracts.txt.

   The list of Internet-Draft Shadow Directories can be accessed at
   http://www.ietf.org/shadow.html.

   This Internet-Draft will expire on December 27, 2008.

Copyright Notice

   Copyright (C) The IETF Trust (2008).












Scott, et al.           Expires December 27, 2008               [Page 1]


Internet-Draft          NETCONF Monitoring Schema              June 2008


Abstract

   This document defines NETCONF content via XML Schema to be used to
   monitor the NETCONF protocol.  It includes information about NETCONF
   sessions, locks, and subscriptions and is intended to facilitate
   management of a NETCONF server.

   In addition this memo defines a mechanism to discover all possible
   data models (schema list retrieval) and a mechanism to retrieve
   schema via NETCONF (get schema).  Both can be performed dynamically
   throughout a session, unlike capabilities exchange which is performed
   during session setup only.  Both support multiple schema versions,
   formats and locations.


Table of Contents

   1.  Introduction . . . . . . . . . . . . . . . . . . . . . . . . .  3
     1.1.  Definition of Terms  . . . . . . . . . . . . . . . . . . .  3
   2.  XML Schema to Monitor NETCONF  . . . . . . . . . . . . . . . .  4
     2.1.  netconf  . . . . . . . . . . . . . . . . . . . . . . . . .  4
       2.1.1.  capabilities . . . . . . . . . . . . . . . . . . . . .  4
       2.1.2.  configurations . . . . . . . . . . . . . . . . . . . .  5
       2.1.3.  schemas  . . . . . . . . . . . . . . . . . . . . . . .  5
       2.1.4.  sessions . . . . . . . . . . . . . . . . . . . . . . .  6
       2.1.5.  subscriptions  . . . . . . . . . . . . . . . . . . . .  7
       2.1.6.  statistics . . . . . . . . . . . . . . . . . . . . . .  8
   3.  Schema Specific Operations . . . . . . . . . . . . . . . . . . 10
     3.1.  New NETCONF RPC, <get-schema>  . . . . . . . . . . . . . . 10
     3.2.  NETCONF Schema List Retrieval (<get> monitoring data)  . . 10
   4.  Examples . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
     4.1.  Retrieving schema list via <get> . . . . . . . . . . . . . 12
     4.2.  Retrieving schema instances  . . . . . . . . . . . . . . . 14
   5.  XSD Schema . . . . . . . . . . . . . . . . . . . . . . . . . . 16
     5.1.  NETCONF Monitoring Schema  . . . . . . . . . . . . . . . . 16
     5.2.  inet:host schema . . . . . . . . . . . . . . . . . . . . . 27
   6.  Security Considerations  . . . . . . . . . . . . . . . . . . . 30
   7.  Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . 31
   8.  Normative References . . . . . . . . . . . . . . . . . . . . . 32
   Appendix A.  YANG module (non-normative) . . . . . . . . . . . . . 33
   Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . . 41
   Intellectual Property and Copyright Statements . . . . . . . . . . 42









Scott, et al.           Expires December 27, 2008               [Page 2]


Internet-Draft          NETCONF Monitoring Schema              June 2008


1.  Introduction

   This document defines NETCONF content via [XMLSchema] to be used to
   monitor the NETCONF protocol.  It provides information about NETCONF
   sessions and subscriptions.

1.1.  Definition of Terms

   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].

   Element:  An [XML] Element.

   Operation:  This term is used to refer to NETCONF protocol
      operations.  Specifically within this document, operation refers
      to NETCONF protocol operations defined in support of NETCONF
      notifications.

   Schema:  This term is used to refer to a data model fragment,
      independent of which data modeling language is used in the data
      model.

   Subscription:  A concept related to the delivery of notifications (if
      any to send) involving destination and selection of notifications.
      It is bound to the lifetime of a session.

   XML Schema:  The W3C XML Schema [XMLSchema] data modeling language.























Scott, et al.           Expires December 27, 2008               [Page 3]


Internet-Draft          NETCONF Monitoring Schema              June 2008


2.  XML Schema to Monitor NETCONF

   The following data is proposed to allow a NETCONF client to monitor
   both the NETCONF server itself and the associated network device
   operational data.  The specific data proposed in this memo and
   suggested usage:

2.1.  netconf


    netconf
     |_capabilities
     |_configurations
     |_schemas
     |_sessions
     |_subscriptions
     |_statistics

  capabilities (SimpleType:  xs:anyURI):
    List of NETCONF capabilities supported by the server.

  configurations (ComplexType:  ConfigurationDatastore):
    List of NETCONF datastores on the server.
    Includes all supported datastore types (running, candidate, startup)

  schemas (ComplexType:  SchemaEntry)
    List of schemas supported on the server.
    Includes all the information required to identify the schema and
    to support its retrieval.

  sessions (ComplexType:  ManagementSession):
    List of all active sessions on the device including NETCONF
    and other sessions (ie. CLI).

  subscriptions (ComplexType:  NetconfSubscription):
    List of all NETCONF notification subscriptions active on the server.

  statistics (ComplexType:  ManagementStatistics)
     Contains management stats for the NETCONF server
     including performance and error related counters.

2.1.1.  capabilities

   Minimally the same capabilities as exchanged during session setup
   such as those defined at
   http://www.iana.org/assignments/netconf-capability-urns plus any
   vendor-specific capabilities.




Scott, et al.           Expires December 27, 2008               [Page 4]


Internet-Draft          NETCONF Monitoring Schema              June 2008


2.1.2.  configurations


  configurations:  NetconfDataStore complex data type.

  configuration
       |_name
       |_locks

  name:
     Enumeration of supported datastores; candidate, running, startup.

  locks (ComplexType:  ManagementSessionLock):
     Contains current lock information for the datastores.  Global and
     partial locks are supported as either a single global lock or
     multiple partial locks per datastore.

     Both a global lock and a partial lock will contain the sessionId
     and time the lock was acquired.  Additionally partial lock items
     will contain both the selection and the list of lockedNodes.  The
     selection is the xpath expression which was used to evaluate the
     list of nodes to lock.  The lockedNodes is the list of actual nodes
     which were locked at the the selection was evaluated.  This is
     provided for completeness noting that the list of nodes returned by
     the selection may differ over time.

2.1.3.  schemas
























Scott, et al.           Expires December 27, 2008               [Page 5]


Internet-Draft          NETCONF Monitoring Schema              June 2008


  schemas:
  List of supported schemas for the NETCONF server.

   schema
      |_identifier   (key)
      |_version      (key)
      |_format       (key)
      |_namespace
      |_location

  The elements identifier, version, and format are used as a key in the
  schema list.  They are also used in the <get-schema> RPC.

  identifier:
    Identifier for the schema list entry.  Typically the module name or
    filename of the schema.  It is also used in the <get-schema>
    RPC and may be used for other means.

  version:
    Version of the schema supported.  Multiple versions can be supported
    simultaneously by a NETCONF server.  Each must be reported
    individually in the schema list, i.e. with same identifier, possibly
    different location, but different version.

  format:
    The data modeling language of the file/module.  Current selection of
    XSD, YANG, and RNG.

  namespace:
    The XML namespace defined by the data model.

  location:
    A location from which this specific schema, format, and version can
    be retrieved.  Can be either on the network device (eg: file system
    reference for ftp retrieval), retrievable explicitly via NETCONF
    (value: 'NETCONF') or some network location (eg: URL for http
    retrieval).

2.1.4.  sessions












Scott, et al.           Expires December 27, 2008               [Page 6]


Internet-Draft          NETCONF Monitoring Schema              June 2008


   sessions (ComplexType: ManagementSessionInfo):

   session
       |_sessionId
       |_transport
       |_protocol
       |_username
       |_sourceHost
       |_loginTime

   sessionId:
     Unique identifier for the session.

   transport:
     Idenfities transport for each session, e.g. "Console", "SSH".

   protocol:
     Identifies the protocol being used for each session, e.g.:
     "NETCONF", "CLI", "WebUI".

   username:
     Session owner.

   sourceHost:
     Host identifier (IP + name) for the client.

   loginTime:
     Time (UTC) at which the session was established.

2.1.5.  subscriptions





















Scott, et al.           Expires December 27, 2008               [Page 7]


Internet-Draft          NETCONF Monitoring Schema              June 2008


   subscriptions:  NetconfSubscription complex type.

   List of notifications subscriptions for all active sessions.

   subscription
      |_sessionId
      |_stream
      |_filter
      |_startTime
      |_stopTime
      |_messagesSent

   sessionId:  netconf SessionId type
     Unique identifier for the notifications.
     Same value as returned in 'sessions' to allow correlation.

   stream:  netconf  notification streamNameType
     Specific event notifications subscribed by session.
     Unique identifier mappable to event subscriptions.

   filter:  netconf notification FilterType
      Filter being applied to the notification stream.

   startTime (xs:dateTime)
      Optional startTime parameter given in the <create-subscription>
      request.

   stopTime (xs:dateTime)
      Optional stopTime parameter given in the <create-subscription>
      request.

   messagesSent (xs:unsignedInt)
       Total messages sent for this subscription.

2.1.6.  statistics
















Scott, et al.           Expires December 27, 2008               [Page 8]


Internet-Draft          NETCONF Monitoring Schema              June 2008


 managementStatistics(ComplexType: ManagementPerformanceStatistics):
   Contains management session related performance data for the NETCONF
   server.

 netconfStartTime:
   Date and time at which the NETCONF server process was started.
   Allows for calculation of simple time interval for reported metrics.
   Ie:  current time - startTime defines the collection interval for the
   metrics allowing for calculations such as averages.
   More complex calculations would require multiple collection
   intervals with both start and stop times defined per interval.

 inSessions:
   The total number of NETCONF sessions started towards the NETCONF
   peer.

 inXMLParseErrors:
   The total number of messages that were unparsable and thus ignored.
   This covers both unparsable <hello> and <rpc> messages.

 inBadHellos:
   The total number of sessions silently dropped because an invalid
   <hello> message was received.  This includes <hello> messages with a
   "session-id" attribute, bad namespace, and bad capability
   declarations.

 inRpcs:
   The total number of rpc requests received.

 inBadRpcs:
   The total number of rpcs which were parsed correctly, but couldn't
   be serviced because they contained non-conformant XML, e.g. missing a
   mandatory parameter.

 inNotSupportedRpcs:
   The total number of rpcs which were parsed correctly, but couldn't
   be serviced because they were not supported by the agent.

 outRpcReplies:
   The total number of <rpc-reply> messages sent.

 outRpcErrors:
   The total number of <rpc-reply> messages with <rpc-error> sent.

 outNotifications:
   The total number of <notification> messages sent.





Scott, et al.           Expires December 27, 2008               [Page 9]


Internet-Draft          NETCONF Monitoring Schema              June 2008


3.  Schema Specific Operations

3.1.  New NETCONF RPC, <get-schema>

   When the schema is available on the device and the client wishes to
   have it returned via NETCONF this new RPC operation is used.

   Example: Query a specific schema on device using <get-schema>
   operation


   <rpc message-id="101"
        xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
     <get-schema xmlns="urn:ietf:params:xml:ns:netconf:state">
       <identifier>foo</identifier>
       <version>v1</version>
       <format>XSD</format>
     </get-schema>
   </rpc>

   The NETCONF server returns the XML schema (XSD).

   <rpc-reply message-id="101"
              xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
     <data><![CDATA[
       <xs:schema
         <!-- Contents of foo schema would be returned here -->
       </xs:schema>]]>
     </data>
   </rpc-reply>

   Schema list is supported via existing NETCONF <get> operation and is
   defined in the monitoring data model to facilitate retrieval.  This
   will support retrieval of the schema list specifically.  The details
   returned in the list will facilitate retrieval from a network
   location via a URL.  Additionally the ability to retrieve a schema
   via NETCONF will be supported.  In this case a new RPC operation is
   introduced to support this retrieval.

3.2.  NETCONF Schema List Retrieval (<get> monitoring data)

   A NETCONF client retrieves the list of supported XML Schema from a
   NETCONF server using the <get> RPC request.  The list of available
   XML Schema is retrieved by requesting the <schema> subtree via a
   <get> operation.  Available schema for the requesting session are
   returned in the reply containing the <identifier> ,<version> and
   <location> elements.  Since the same schema may be supported in
   multiple locations and/or have multiple versions and/or multiple



Scott, et al.           Expires December 27, 2008              [Page 10]


Internet-Draft          NETCONF Monitoring Schema              June 2008


   formats no particular attribute is unique.  An empty reply is
   returned if there are no available schema.

   The response data can be used to determine the available schema and
   their versions.  The schema itself (ie. schema content) is not
   returned in the response.  Information about the schema is returned
   which is used to facilitate the retrieval of a particular format and
   version of the schema using a supported mechanism on the device such
   as ftp or http.  In addition when a schema is available on the device
   a special location value of 'NETCONF' is used to indicate its
   availability on the device.  Such schema can be retrieved via NETCONF
   using the <get-schema> RPC described later in this draft.







































Scott, et al.           Expires December 27, 2008              [Page 11]


Internet-Draft          NETCONF Monitoring Schema              June 2008


4.  Examples

4.1.  Retrieving schema list via <get>


   <rpc message-id="101"
        xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
     <get>
       <filter type="subtree">
         <netconf xmlns="urn:ietf:params:xml:ns:netconf:state">
           <schemas/>
         </netconf>
       </filter>
     </get>
   </rpc>

   The NETCONF server returns a list of data models available for
   retrieval.

































Scott, et al.           Expires December 27, 2008              [Page 12]


Internet-Draft          NETCONF Monitoring Schema              June 2008


<rpc-reply message-id="101"
           xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
  <data>
    <netconf xmlns="urn:ietf:params:xml:ns:netconf:state">
      <schemas>
        <schema>
          <identifier>foo</identifier>
          <version>1.0</version>
          <format>XSD</format>
          <namespace>http://example.com/foo</namespace>
          <location>ftp://ftp.example.com/schemas/foo_1.0.xsd</location>
          <location>http://www.example.com/schema/foo_1.0.xsd</location>
          <location>NETCONF</location>
        </schema>
        <schema>
          <identifier>foo</identifier>
          <version>1.1</version>
          <format>XSD</format>
          <namespace>http://example.com/foo</namespace>
          <location>ftp://ftp.example.com/schemas/foo_1.1.xsd</location>
          <location>http://www.example.com/schema/foo_1.1.xsd</location>
          <location>NETCONF</location>
        </schema>
        <schema>
          <identifier>bar</identifier>
          <version>2008-06-01</version>
          <format>YANG</format>
          <namespace>http://example.com/bar</namespace>
          <location>
            http://example.com/schema/bar-2008-06-01.yang
          </location>
          <location>NETCONF</location>
        </schema>
        <schema>
          <identifier>bar-types</identifier>
          <version>2008-06-01</version>
          <format>YANG</format>
          <namespace>http://example.com/bar</namespace>
          <location>
            http://example.com/schema/bar-types-2008-06-01.yang
          </location>
          <location>NETCONF</location>
        </schema>
      </schemas>
    </netconf>
  </data>
</rpc-reply>




Scott, et al.           Expires December 27, 2008              [Page 13]


Internet-Draft          NETCONF Monitoring Schema              June 2008


4.2.  Retrieving schema instances

   Given the reply in the previous section, the following examples
   illustrate the availability of 'foo', 'bar', and 'bar-types' schema
   at multiple locations, with multiple formats, and in multiple
   locations.

     1.  foo,  version 1.0 in XSD format:

       a.  Via FTP using location
           ftp://ftp.example.com/schemas/foo_1.0.xsd

       b.  Via HTTP using location
           http://www.example.com/schema/foo/1.0.xsd

       c.  Via <get-schema> using identifier, version, and
           format parameters.

       <rpc message-id="102"
            xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
         <get-schema xmlns="urn:ietf:params:xml:ns:netconf:state">
           <identifer>foo</identifer>
           <version>1.0</version>
           <format>XSD</format>
         </get-schema>
       </rpc>


     2. bar, version 2008-06-01 in YANG format:

       a.  Via HTTP using location
           http://example.com/schema/bar-2008-06-01.yang

       b.  Via <get-schema> using identifer, version, and
           format parameters:

       <rpc message-id="103"
            xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
         <get-schema xmlns="urn:ietf:params:xml:ns:netconf:state">
           <identifer>bar</identifer>
           <version>2008-06-01</version>
           <format>YANG</format>
         </get-schema>
       </rpc>


     3. bar-types, version 2008-06-01 in YANG format:




Scott, et al.           Expires December 27, 2008              [Page 14]


Internet-Draft          NETCONF Monitoring Schema              June 2008


       a. Via <get-schema> using identifer, version, and
          format parameters:

       <rpc message-id="104"
            xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
         <get-schema xmlns="urn:ietf:params:xml:ns:netconf:state">
           <identifer>bar-types</identifer>
           <version>2008-06-01</version>
           <format>YANG</format>
         </get-schema>
       </rpc-reply>








































Scott, et al.           Expires December 27, 2008              [Page 15]


Internet-Draft          NETCONF Monitoring Schema              June 2008


5.  XSD Schema

5.1.  NETCONF Monitoring Schema

   The data model described in this memo is defined in the following
   XSD.


<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
  xmlns:netconf="urn:ietf:params:xml:ns:netconf:base:1.0"
  xmlns:ncEvent="urn:ietf:params:xml:ns:netconf:notification:1.0"
  xmlns:inet="urn:ietf:params:xml:ns:inet-types"
  targetNamespace="urn:ietf:params:xml:ns:netconf:state"
  xmlns="urn:ietf:params:xml:ns:netconf:state"
  elementFormDefault="qualified">

  <!-- import base netconf definitions -->
  <xs:import namespace="urn:ietf:params:xml:ns:netconf:base:1.0"
    schemaLocation="netconf.xsd"/>

  <xs:import namespace="urn:ietf:params:xml:ns:netconf:notification:1.0"
  schemaLocation="notification.xsd"/>

  <xs:import namespace="urn:ietf:params:xml:ns:inet-types"
    schemaLocation="inet-ip.xsd"/>

  <!-- Model -->
  <xs:element name="netconf">
    <xs:complexType>
      <xs:sequence>
        <xs:element name="capabilities" minOccurs="1" maxOccurs="1">
          <xs:annotation>
            <xs:documentation>
              The list of currently provided NETCONF capabilities.
              This may be different than those exchanged during
              session setup (i.e. hello).
            </xs:documentation>
          </xs:annotation>
          <xs:complexType>
            <xs:sequence>
              <xs:element name="capability" type="xs:anyURI"
                          maxOccurs="unbounded"/>
            </xs:sequence>
          </xs:complexType>
        </xs:element>

        <xs:element name="configurations" minOccurs="1" maxOccurs="1">
          <xs:annotation>



Scott, et al.           Expires December 27, 2008              [Page 16]


Internet-Draft          NETCONF Monitoring Schema              June 2008


            <xs:documentation>
              Contains the NETCONF configurations data storesavailable
              on the device.
            </xs:documentation>
          </xs:annotation>
          <xs:complexType>
            <xs:sequence>
              <xs:element name="configuration"
                          type="ConfigurationDatastore"
                          minOccurs="0" maxOccurs="unbounded"/>
            </xs:sequence>
          </xs:complexType>
        </xs:element>

        <xs:element name="schemas" minOccurs="0" maxOccurs="1">
          <xs:annotation>
            <xs:documentation>
              Contains the list of supported schemas on the device.
              I.e. NETCONF data models, interface descriptions, etc.
            </xs:documentation>
          </xs:annotation>
          <xs:complexType>
            <xs:sequence>
              <xs:element name="schema" type="SchemaEntry"
                          minOccurs="0" maxOccurs="unbounded"/>
            </xs:sequence>
          </xs:complexType>
        </xs:element>

        <xs:element name="sessions" minOccurs="1" maxOccurs="1">
          <xs:annotation>
            <xs:documentation>
              Contains the details on active sessions on the device.
              Covers both NETCONF and non-NETCONF management sessions.
            </xs:documentation>
          </xs:annotation>
          <xs:complexType>
            <xs:sequence>
              <xs:element name="session" type="ManagementSession"
                          minOccurs="0" maxOccurs="unbounded"/>
            </xs:sequence>
          </xs:complexType>
        </xs:element>

        <xs:element name="subscriptions" minOccurs="0">
          <xs:annotation>
            <xs:documentation>
              Contains the details on active event stream



Scott, et al.           Expires December 27, 2008              [Page 17]


Internet-Draft          NETCONF Monitoring Schema              June 2008


              subscriptions.  Includes active replay streams, if
              supported.
            </xs:documentation>
          </xs:annotation>
          <xs:complexType>
            <xs:sequence>
              <xs:element name="subscription" type="NetconfSubscription"
                          minOccurs="0" maxOccurs="unbounded"/>
            </xs:sequence>
          </xs:complexType>
        </xs:element>

        <xs:element name="statistics" type="ManagementStatistics"
                    minOccurs="0" maxOccurs="1">
          <xs:annotation>
            <xs:documentation>
              Contains  management metrics for the NETCONF server.
            </xs:documentation>
          </xs:annotation>
        </xs:element>
      </xs:sequence>
    </xs:complexType>
  </xs:element>

  <!-- Complex type definitions -->
  <xs:complexType name="ConfigurationDatastore">
    <xs:annotation>
      <xs:documentation>
        Contains information on the datastores available on
        the NETCONF server including locks.
      </xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element name="name" type="ConfigurationDatastoreType">
        <xs:annotation>
          <xs:documentation>
            enumeration of supported datastores; candidate,
            running, startup
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="locks" minOccurs="0">
        <xs:annotation>
          <xs:documentation>
            An indication of whether a resource is locked or
            unlocked.  If locked, additional information about
            the locking such as user an time stamp is provided.
          </xs:documentation>



Scott, et al.           Expires December 27, 2008              [Page 18]


Internet-Draft          NETCONF Monitoring Schema              June 2008


        </xs:annotation>
        <xs:complexType>
          <xs:choice minOccurs="0">
            <xs:element name="globalLock" type="GlobalLock">
              <xs:annotation>
                <xs:documentation>
                  Present if a global lock is set.
                </xs:documentation>
              </xs:annotation>
            </xs:element>
            <xs:element name="partialLocks" type="PartialLock"
                        maxOccurs="unbounded">
              <xs:annotation>
                <xs:documentation>
                  Present if at least one partial lock is set.
                </xs:documentation>
              </xs:annotation>
            </xs:element>
          </xs:choice>
        </xs:complexType>
      </xs:element>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="SchemaEntry">
    <xs:annotation>
      <xs:documentation>
        Contains the information used to describe the schema.
      </xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element name="identifier" type="xs:string">
        <xs:annotation>
          <xs:documentation>
            Identifier to uniquely reference the schema.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="version" type="xs:string">
        <xs:annotation>
          <xs:documentation>
            Version of the schema supported.  Multiple versions can be
            supported simultaneously.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="format" type="SchemaFormat">
        <xs:annotation>



Scott, et al.           Expires December 27, 2008              [Page 19]


Internet-Draft          NETCONF Monitoring Schema              June 2008


          <xs:documentation>
            Schema language for the file/module.  Eg: XSD, YANG, RNG.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="namespace" type="xs:anyURI">
        <xs:annotation>
          <xs:documentation>
            The XML namespace defined by the data model.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="location" minOccurs="0" maxOccurs="unbounded">
        <xs:annotation>
          <xs:documentation>
            A location from which the schema can be retrieved.  Can be
            either on the network device retrievable explicitly via
            the get-schema netconf operation (denoted by the value
            'NETCONF') or some network location (i.e. URL).
          </xs:documentation>
        </xs:annotation>
        <xs:simpleType>
          <xs:union>
            <xs:simpleType>
              <xs:restriction base="xs:string">
                <xs:enumeration value="NETCONF"/>
              </xs:restriction>
            </xs:simpleType>
            <xs:simpleType>
              <xs:restriction base="xs:anyURI">
              </xs:restriction>
            </xs:simpleType>
          </xs:union>
        </xs:simpleType>
      </xs:element>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="ManagementSession">
    <xs:annotation>
      <xs:documentation>
        Contains information related to managment sessions on
        the device.
    </xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element name="sessionId" type="netconf:SessionId">
        <xs:annotation>



Scott, et al.           Expires December 27, 2008              [Page 20]


Internet-Draft          NETCONF Monitoring Schema              June 2008


          <xs:documentation>
            Unique identifier for the session instance.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="transport" type="TransportType">
        <xs:annotation>
          <xs:documentation>
            Identifies the transport for each session, e.g.
            "Console", "SSH".
          </xs:documentation>
        </xs:annotation>
      </xs:element>

      <xs:element name="protocol" type="ProtocolType">
        <xs:annotation>
          <xs:documentation>
            Identifies the protocol being used for each session,
            e.g. "NETCONF", "CLI", "WebUI".
          </xs:documentation>
        </xs:annotation>
      </xs:element>

      <xs:element name="username" type="xs:string">
        <xs:annotation>
          <xs:documentation>
            Session owner.
          </xs:documentation>
        </xs:annotation>
      </xs:element>

      <xs:element name="sourceHost" type="inet:host">
        <xs:annotation>
          <xs:documentation>
            Client for the session.
          </xs:documentation>
        </xs:annotation>
      </xs:element>

      <xs:element name="loginTime" type="xs:dateTime">
        <xs:annotation>
          <xs:documentation>
            Time at which the session was established.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
    </xs:sequence>
  </xs:complexType>



Scott, et al.           Expires December 27, 2008              [Page 21]


Internet-Draft          NETCONF Monitoring Schema              June 2008


  <xs:complexType name="NetconfSubscription">
    <xs:annotation>
      <xs:documentation>
        Contains information on the active subscriptions on the
        NETCONF server.  Subscriptions which have ended are not
        reported.
      </xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element name="sessionId" type="netconf:SessionId"/>
      <xs:element name="stream" type="ncEvent:streamNameType"/>
      <xs:element name="filter" type="netconf:filterInlineType"/>
      <xs:element name="startTime" type="xs:dateTime" minOccurs="0"/>
      <!-- stopTime is optional on servers with replay support -->
      <xs:element name="stopTime" type="xs:dateTime" minOccurs="0"/>
      <xs:element name="messagesSent" type="xs:unsignedInt"/>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="ManagementStatistics">
    <xs:annotation>
      <xs:documentation>
        Contains management statistics for the NETCONF server.
    </xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element name="netconfStartTime" type="xs:dateTime">
        <xs:annotation>
          <xs:documentation>
            Date and time at which the NETCONF server process was
            started.  Allows for calculation of time interval for
            reported metrics.
        </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="inSessions" type="xs:unsignedInt">
        <xs:annotation>
          <xs:documentation>
            The total number of NETCONF sessions started towards the
            NETCONF peer.
            inSessions - inBadHellos = 'number of correctly started
                                          netconf sessions'
        </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="inXMLParseErrors" type="xs:unsignedInt">
        <xs:annotation>
          <xs:documentation>



Scott, et al.           Expires December 27, 2008              [Page 22]


Internet-Draft          NETCONF Monitoring Schema              June 2008


            The total number of messages that were unparsable and thus
            ignored.  This covers both unparsable 'hello' and 'rpc'
            messages.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="inBadHellos" type="xs:unsignedInt">
        <xs:annotation>
          <xs:documentation>
            The total number of sessions silently dropped because an
            invalid 'hello' message was received.  This includes hello
            messages with a 'session-id' attribute, bad namespace, and
            bad capability declarations.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="inRpcs" type="xs:unsignedInt">
        <xs:annotation>
          <xs:documentation>
            The total number of rpc requests received.
        </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="inBadRpcs" type="xs:unsignedInt">
        <xs:annotation>
          <xs:documentation>
            The total number of rpcs which were parsed correctly, but
            couldn't be serviced because they contained non-conformant
            XML, e.g. missing a mandatory parameter.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="inNotSupportedRpcs" type="xs:unsignedInt">
        <xs:annotation>
          <xs:documentation>
            The total number of rpcs which were parsed correctly, but
            couldn't be serviced because they were not supported by
            the agent.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="outRpcReplies" type="xs:unsignedInt">
        <xs:annotation>
          <xs:documentation>
            The total number of 'rpc-reply' messages sent.
          </xs:documentation>
        </xs:annotation>
      </xs:element>



Scott, et al.           Expires December 27, 2008              [Page 23]


Internet-Draft          NETCONF Monitoring Schema              June 2008


      <xs:element name="outRpcErrors" type="xs:unsignedInt">
        <xs:annotation>
          <xs:documentation>
            The total number of 'rpc-reply' messages with
            'rpc-error' sent.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="outNotifications" type="xs:unsignedInt">
        <xs:annotation>
          <xs:documentation>
            The total number of 'notification' messages sent.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="ConfigurationDatastoreType">
    <xs:annotation>
      <xs:documentation>
        Enumeration of possible NETCONF datastore types.
      </xs:documentation>
    </xs:annotation>
    <xs:choice >
      <xs:element name="startup" type="xs:string"/>
      <xs:element name="candidate" type="xs:string"/>
      <xs:element name="running" type="xs:string"/>
    </xs:choice>
  </xs:complexType>

  <xs:complexType name="GlobalLock">
    <xs:sequence>
      <xs:element name="lockedBySession"
                  type="netconf:SessionId">
        <xs:annotation>
          <xs:documentation>
            The session Id which holds the lock.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="lockedTime"
                  type="xs:dateTime">
        <xs:annotation>
          <xs:documentation>
            Date and Time the lock was acquired.
          </xs:documentation>
        </xs:annotation>



Scott, et al.           Expires December 27, 2008              [Page 24]


Internet-Draft          NETCONF Monitoring Schema              June 2008


      </xs:element>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="PartialLock">
    <xs:sequence>
      <xs:element name="lockId" type="xs:unsignedInt">
        <xs:annotation>
          <xs:documentation>
            For a partial lock this provides the lock id.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="lockedBySession"
                  type="netconf:SessionId">
        <xs:annotation>
          <xs:documentation>
            The session Id which holds the lock.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="lockedTime"
                  type="xs:dateTime">
        <xs:annotation>
          <xs:documentation>
            Date and Time the lock was acquired.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="select" maxOccurs="unbounded">
        <xs:annotation>
          <xs:documentation>
            The xpath expression which was used to request the lock.
          </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="lockedNodes"
                  minOccurs="0" maxOccurs="unbounded">
        <xs:annotation>
          <xs:documentation>
            The list of instance-identifiers (i.e. the locked nodes).
          </xs:documentation>
        </xs:annotation>
      </xs:element>
    </xs:sequence>
  </xs:complexType>





Scott, et al.           Expires December 27, 2008              [Page 25]


Internet-Draft          NETCONF Monitoring Schema              June 2008


 <!-- Simple types -->
  <xs:simpleType name="SchemaFormat">
    <xs:annotation>
      <xs:documentation>
        Format of the schema.
      </xs:documentation>
    </xs:annotation>
    <xs:restriction base="xs:string">
      <xs:enumeration value="XSD"/>
      <xs:enumeration value="YANG"/>
      <xs:enumeration value="RNG"/>
    </xs:restriction>
  </xs:simpleType>

  <xs:simpleType name="TransportType">
    <xs:annotation>
      <xs:documentation>
        Transport choices.
      </xs:documentation>
    </xs:annotation>
    <xs:restriction base="xs:string">
      <xs:enumeration value="SSH"/>
      <xs:enumeration value="SSL"/>
      <xs:enumeration value="Console"/>
      <xs:enumeration value="HTTP"/>
      <xs:enumeration value="HTTPS"/>
    </xs:restriction>
  </xs:simpleType>

  <xs:simpleType name="ProtocolType">
    <xs:annotation>
      <xs:documentation>
        Protocol choices.
      </xs:documentation>
    </xs:annotation>
    <xs:restriction base="xs:string">
      <xs:enumeration value="CLI"/>
      <xs:enumeration value="NETCONF"/>
      <xs:enumeration value="WebUI"/>
    </xs:restriction>
  </xs:simpleType>

  <!-- RPC Definitions -->
  <xs:element name="get-schema"
              substitutionGroup="netconf:rpcOperation">
    <xs:annotation>
      <xs:documentation>
        RPC definition:  &lt;get-schema&gt;



Scott, et al.           Expires December 27, 2008              [Page 26]


Internet-Draft          NETCONF Monitoring Schema              June 2008


      </xs:documentation>
    </xs:annotation>
  <xs:complexType>
    <xs:complexContent>
      <xs:extension base="netconf:rpcOperationType">
        <xs:sequence>
          <xs:element name="identifier" type="xs:string"/>
          <xs:element name="version" type="xs:string"/>
          <xs:element name="format" type="SchemaFormat"/>
        </xs:sequence>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
  </xs:element>
</xs:schema>


5.2.  inet:host schema

   The complex type ManagementSession contains element sourceHost of
   type inet:host.  The following schema defines the referenced type.


   <?xml version="1.0" encoding="UTF-8"?>
   <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
              targetNamespace="urn:ietf:params:xml:ns:inet-types"
              xmlns:inet="urn:ietf:params:xml:ns:inet-types"
              elementFormDefault="qualified"
              attributeFormDefault="unqualified">

     <xs:simpleType name="ipAddress">
       <xs:annotation>
         <xs:documentation>
           The ipAddress type represents an IP address and
           is IP version neutral. The format of the textual
           representations implies the IP version.
         </xs:documentation>
       </xs:annotation>

       <xs:union>
         <xs:simpleType>
           <xs:restriction base="inet:ipv4Address">
           </xs:restriction>
         </xs:simpleType>
         <xs:simpleType>
           <xs:restriction base="inet:ipv6Address">
           </xs:restriction>
         </xs:simpleType>



Scott, et al.           Expires December 27, 2008              [Page 27]


Internet-Draft          NETCONF Monitoring Schema              June 2008


       </xs:union>
     </xs:simpleType>

     <xs:simpleType name="ipv4Address">
       <xs:annotation>
         <xs:documentation>
           The ipv4Address type represents an IPv4 address in
           dotted-quad notation. The IPv4 address may include
           a zone index, separated by a % sign.
         </xs:documentation>
       </xs:annotation>

       <xs:restriction base="xs:string">
         <xs:pattern value=
                  "(([0-1]?[0-9]?[0-9]|2[0-4][0-9]|25[0-5])\.){3}
                   ([0-1]?[0-9]?[0-9]|2[0-4][0-9]|25[0-5])
                   (%[\p{N}\p{L}]+)?"/>
       </xs:restriction>
     </xs:simpleType>

     <xs:simpleType name="ipv6Address">
       <xs:annotation>
         <xs:documentation>
           The ipv6Address type represents an IPv6 address in
           full, mixed, shortened and shortened mixed notation.
           The IPv6 address may include a zone index, separated
           by a % sign.
         </xs:documentation>
       </xs:annotation>

       <xs:restriction base="xs:string">
         <xs:pattern value=
                  "((([0-9a-fA-F]{1,4}:){7})([0-9a-fA-F]{1,4})
                   (%[\p{N}\p{L}]+)?)
                   |((([0-9a-fA-F]{1,4}:){6})(([0-9]{1,3}\.
                       [0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}))
                    (%[\p{N}\p{L}]+)?)
                  |((([0-9a-fA-F]{1,4}:)*([0-9a-fA-F]{1,4}))*(::)
                    (([0-9a-fA-F]{1,4}:)*([0-9a-fA-F]{1,4}))*
                    (%[\p{N}\p{L}]+)?)
                  ((([0-9a-fA-F]{1,4}:)*([0-9a-fA-F]{1,4}))*(::)
                   (([0-9a-fA-F]{1,4}:)*([0-9a-fA-F]{1,4}))*
                   (([0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}))
                    (%[\p{N}\p{L}]+)?)"/>
       </xs:restriction>
     </xs:simpleType>

     <xs:simpleType name="domainName">



Scott, et al.           Expires December 27, 2008              [Page 28]


Internet-Draft          NETCONF Monitoring Schema              June 2008


       <xs:annotation>
         <xs:documentation>
           The domainName type represents a DNS domain
           name. The name SHOULD be fully qualified
           whenever possible.

           The description clause of objects using the
           domainName type MUST describe how (and when)
           these names are resolved to IP addresses.

           Note that the resolution of a domainName value
           may require to query multiple DNS records (e.g.,
           A for IPv4 and AAAA for IPv6).  The order of the
           resolution process and which DNS record takes
           precedence depends on the configuration of the
           resolver.
         </xs:documentation>
       </xs:annotation>

       <xs:restriction base="xs:string">
         <xs:pattern value="([\p{L}\p{N}]+\.)*[\p{L}\p{N}]"/>
       </xs:restriction>
     </xs:simpleType>

     <xs:simpleType name="host">
       <xs:annotation>
         <xs:documentation>
           The host type represents either an IP address
           or a DNS domain name.
         </xs:documentation>
       </xs:annotation>

       <xs:union>
         <xs:simpleType>
           <xs:restriction base="inet:ipAddress">
           </xs:restriction>
         </xs:simpleType>
         <xs:simpleType>
           <xs:restriction base="inet:domainName">
           </xs:restriction>
         </xs:simpleType>
       </xs:union>
     </xs:simpleType>


   </xs:schema>





Scott, et al.           Expires December 27, 2008              [Page 29]


Internet-Draft          NETCONF Monitoring Schema              June 2008


6.  Security Considerations

   The information in this Schema provides information about NETCONF
   system that could be used to aid an attack on that system.  Care
   should be taken to restrict access to this information as
   appropriate.













































Scott, et al.           Expires December 27, 2008              [Page 30]


Internet-Draft          NETCONF Monitoring Schema              June 2008


7.  Acknowledgements

   Thanks to the NETCONF working group for providing a much earlier
   draft of Schema to manage NETCONF and NETCONF Notifications that were
   cannibalized to produce this draft.














































Scott, et al.           Expires December 27, 2008              [Page 31]


Internet-Draft          NETCONF Monitoring Schema              June 2008


8.  Normative References

   [NETCONF]  Enns, R., "NETCONF Configuration Protocol", RFC 4741,
              February 2006.

   [NETCONF-EVENT]
              Chisholm, S. and H. Trevino, "NETCONF Event
              Notifications", ID draft-ietf-netconf-notification-14,
              June 2008.

   [RFC2119]  Bradner, s., "Key words for RFCs to Indicate Requirements
              Levels", RFC 2119, March 1997.

   [XML]      World Wide Web Consortium, "Extensible Markup Language
              (XML) 1.0", W3C XML, February 1998,
              <http://www.w3.org/TR/1998/REC-xml-19980210>.

   [XMLSchema]
              Fallside, D. and P. Walmsley, "XML Schema Part 0: Primer
              Second Edition", W3C XML Schema, October 2004.































Scott, et al.           Expires December 27, 2008              [Page 32]


Internet-Draft          NETCONF Monitoring Schema              June 2008


Appendix A.  YANG module (non-normative)


module netconf-state {

  namespace "urn:ietf:params:xml:ns:netconf:state";
  prefix "ns";

  import yang-types { prefix yang; }
  import inet-types { prefix inet; }

  organization
    "IETF";

  description
    "NETCONF Monitoring Module.
     All elements in this module are read-only.";

  revision "2008-06-23" {
    description "Initial revision.";
  }

  typedef SessionId {
    type uint32 {
      range "1..max";
    }
    reference "rfc4741";
  }

  grouping ConfigurationDatastoreType {
    description
      "Enumeration of possible NETCONF datastore types.";
    reference "rfc4741";
    choice datastore {
      mandatory true;
      leaf running {
        type empty;
      }
      leaf candidate {
        type empty;
      }
      leaf startup {
        type empty;
      }
    }
  }

  typedef TransportType {



Scott, et al.           Expires December 27, 2008              [Page 33]


Internet-Draft          NETCONF Monitoring Schema              June 2008


    type enumeration {
      enum "SSH";
      enum "SSL";
      enum "Console";
      enum "HTTP";
      enum "HTTPS";
    }
  }

  typedef ProtocolType {
    type enumeration {
      enum "CLI";
      enum "NETCONF";
      enum "WebUI";
    }
  }

  typedef SchemaFormat {
    type enumeration {
      enum "XSD" {
        reference "W3C REC REC-xmlschema-1-20041028";
      }
      enum "YANG" {
        reference "draft-ietf-netmod-yang";
      }
      enum "RNG" {
        reference "ISO/IEC 19757-2";
      }
    }
  }

  container netconf {
    config false;

    container capabilities {
      description
        "The list of currently provided NETCONF capabilities.  This
         may be different than those exchanged during session setup
         (i.e. hello).";
      leaf-list capability {
        type yang:uri;
        min-elements 1;
      }
    }

    container configurations {
      description
        "List of NETCONF configuration datastores (e.g. running,



Scott, et al.           Expires December 27, 2008              [Page 34]


Internet-Draft          NETCONF Monitoring Schema              June 2008


         startup, candidate) supported on this device and related
         information.";
      list configuration {
        container name {
          uses ConfigurationDatastoreType;
        }
        container locks {
          description
            "An indication of whether a resource is locked or
             unlocked.  If locked, additional information about
             the locking such as user an time stamp is provided.";

          grouping LockInfo {
            leaf lockedBySession {
              type SessionId;
              description
                "The session ID of the session that has locked
                 this resource.";
            }
            leaf lockedTime {
              type yang:date-and-time;
              description
                "The date and time of when the resource was
                 locked.";
            }
          }

          choice lockType {
            container globalLock {
              description
                "Present if the global lock is set.";
              uses LockInfo;
            }
            list partialLocks {
              key lockId;
              description
                "Present if at least one partial lock is set.";

              leaf lockId {
                type uint32;
              }
              uses LockInfo;
              leaf-list select {
                type string;
                min-elements 1;
                description
                  "The xpath expression which was used to request
                   the lock.";



Scott, et al.           Expires December 27, 2008              [Page 35]


Internet-Draft          NETCONF Monitoring Schema              June 2008


              }
              leaf-list lockedNodes {
                type instance-identifier;
                description
                  "The list of instance-identifiers (i.e. the
                   locked nodes).";
              }
            }
          }
        }
      }
    }

    container schemas {
      list schema {
        key "identifier format version";
        leaf identifier {
          type string;
          description
            "Identifier to uniquely reference the schema";
        }
        leaf version {
          type string;
          description
            "Version of the schema supported.  Multiple versions can be
             supported simultaneously.";
        }
        leaf format {
          type SchemaFormat;
          description
            "Schema language for the file/module.";
        }
        leaf namespace {
          type yang:uri;
          description
            "The XML namespace defined by the data model.";
        }
        leaf location {
          type union {
            type enumeration {
              enum "NETCONF";
            }
            type yang:uri;
          }
          description
            "A location from which the schema can be retrieved.  Can be
             either on the network device retrievable explicitly via the
             get-schema netconf operation (denoted by the value



Scott, et al.           Expires December 27, 2008              [Page 36]


Internet-Draft          NETCONF Monitoring Schema              June 2008


             'NETCONF') or some network location (i.e. URL).";
        }
      }
    }

    container sessions {
      description
        "List of NETCONF sessions currently active on this device.";
      list session {
        key sessionId;
        leaf sessionId {
          type SessionId;
        }
        leaf transport {
          type TransportType;
        }
        leaf protocol {
          type ProtocolType;
        }
        leaf username  {
          type string;
        }
        leaf sourceHost {
          type inet:host;
        }
        leaf loginTime {
          type yang:date-and-time;
          description
            "Time at which the session was established.";
        }
      }
    }

    container subscriptions {
      description
        "Contains information on the active subscriptions on the
         NETCONF server.  Subscriptions which have ended are not
         reported.";
      list subscription {
        key sessionId;
        description
          "Information about Netconf Notification Subscriptions.";
        leaf sessionId {
          type SessionId;
          description
            "The session id associated with this subscription.";
        }
        leaf stream {



Scott, et al.           Expires December 27, 2008              [Page 37]


Internet-Draft          NETCONF Monitoring Schema              June 2008


          type string;
          description
            "The stream associated with this subscription.";
        }
        anyxml filter {
          description
            "The filters associated with this subscription.";
        }
        leaf startTime {
          type yang:date-and-time;
          description
            "The startTime parameter from the create-subscription
             invokation, if it was present.";
        }
        leaf stopTime {
          type yang:date-and-time;
          description
            "The stopTime parameter from the create-subscription
             invokation, if it was present.";
        }
        leaf messagesSent {
          type yang:zero-based-counter32;
          description
            "A count of event notifications sent along
             this connection since the subscription was
             created.";
        }
      }
    }

    container statistics {
      leaf netconfStartTime {
        type yang:date-and-time;
        description
          "Date and time at which the NETCONF server process was
           started.  Allows for calculation of time interval for
           reported metrics.";
      }
      leaf inSessions {
        type yang:zero-based-counter32;
        description
          "The total number of NETCONF sessions started towards the
           NETCONF peer.

            inSessions - inBadHellos = 'number of correctly started
                                        netconf sessions'";
      }
      leaf inXMLParseErrors {



Scott, et al.           Expires December 27, 2008              [Page 38]


Internet-Draft          NETCONF Monitoring Schema              June 2008


        type yang:zero-based-counter32;
        description
          "The total number of messages that were unparsable and thus
           ignored.  This covers both unparsable 'hello' and 'rpc'
           messages.";
      }
      leaf inBadHellos {
        type yang:zero-based-counter32;
        description
          "The total number of sessions silently dropped because an
           invalid 'hello' message was received.  This includes hello
           messages with a 'session-id' attribute, bad namespace, and
           bad capability declarations.";
      }
      leaf inRpcs {
        type yang:zero-based-counter32;
        description
          "The total number of rpc requests received.";
      }
      leaf inBadRpcs {
        type yang:zero-based-counter32;
        description
          "The total number of rpcs which were parsed correctly, but
           couldn't be serviced because they contained
           non-conformant XML,  e.g. missing a mandatory parameter.";
      }
      leaf inNotSupportedRpcs {
        type yang:zero-based-counter32;
        description
          "The total number of rpcs which were parsed correctly, but
           couldn't be serviced because they were not supported by
           the agent.";
      }
      leaf outRpcReplies {
        type yang:zero-based-counter32;
        description
          "The total number of 'rpc-reply' messages sent.";
      }
      leaf outRpcErrors {
        type yang:zero-based-counter32;
        description
          "The total number of 'rpc-reply' messages with 'rpc-error'
            sent.";
      }
      leaf outNotifications {
        type yang:zero-based-counter32;
        description
          "The total number of 'notifications' messages sent.";



Scott, et al.           Expires December 27, 2008              [Page 39]


Internet-Draft          NETCONF Monitoring Schema              June 2008


      }
    }

  }

  rpc get-schema {
    input {
      leaf identifier {
        type string;
        mandatory true;
      }
      leaf version {
        type string;
        mandatory true;
      }
      leaf format {
        type SchemaFormat;
        mandatory true;
      }
    }
  }

}




























Scott, et al.           Expires December 27, 2008              [Page 40]


Internet-Draft          NETCONF Monitoring Schema              June 2008


Authors' Addresses

   Mark Scott
   Nortel
   3500 Carling Ave
   Nepean, Ontario  K2H 8E9
   Canada

   Email: markscot@nortel.com


   Sharon Chisholm
   Nortel
   3500 Carling Ave
   Nepean, Ontario  K2H 8E9
   Canada

   Email: schishol@nortel.com


   Martin Bjorklund
   Tail-f Systems
   Klara Norra Kyrkogata 31
   SE-111 22 Stockholm,
   Sweden

   Email: mbj@tail-f.com
























Scott, et al.           Expires December 27, 2008              [Page 41]


Internet-Draft          NETCONF Monitoring Schema              June 2008


Full Copyright Statement

   Copyright (C) The IETF Trust (2008).

   This document is subject to the rights, licenses and restrictions
   contained in BCP 78, and except as set forth therein, the authors
   retain all their rights.

   This document and the information contained herein are provided on an
   "AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS
   OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY, THE IETF TRUST AND
   THE INTERNET ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS
   OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF
   THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
   WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.


Intellectual Property

   The IETF takes no position regarding the validity or scope of any
   Intellectual Property Rights or other rights that might be claimed to
   pertain to the implementation or use of the technology described in
   this document or the extent to which any license under such rights
   might or might not be available; nor does it represent that it has
   made any independent effort to identify any such rights.  Information
   on the procedures with respect to rights in RFC documents can be
   found in BCP 78 and BCP 79.

   Copies of IPR disclosures made to the IETF Secretariat and any
   assurances of licenses to be made available, or the result of an
   attempt made to obtain a general license or permission for the use of
   such proprietary rights by implementers or users of this
   specification can be obtained from the IETF on-line IPR repository at
   http://www.ietf.org/ipr.

   The IETF invites any interested party to bring to its attention any
   copyrights, patents or patent applications, or other proprietary
   rights that may cover technology that may be required to implement
   this standard.  Please address the information to the IETF at
   ietf-ipr@ietf.org.


Acknowledgment

   Funding for the RFC Editor function is provided by the IETF
   Administrative Support Activity (IASA).





Scott, et al.           Expires December 27, 2008              [Page 42]


Html markup produced by rfcmarkup 1.129d, available from https://tools.ietf.org/tools/rfcmarkup/