1 module ietf-netconf-notifications {
4 "urn:ietf:params:xml:ns:yang:ietf-netconf-notifications";
8 import ietf-inet-types { prefix inet; revision-date "2010-09-24";}
9 import ietf-netconf { prefix nc; revision-date "2011-06-01";}
12 "IETF NETCONF (Network Configuration Protocol) Working Group";
15 "WG Web: <http://tools.ietf.org/wg/netconf/>
16 WG List: <mailto:netconf@ietf.org>
19 <mailto:bertietf@bwijnen.net>
21 WG Chair: Mehmet Ersue
22 <mailto:mehmet.ersue@nsn.com>
25 <mailto:andy@netconfcentral.org>";
28 "This module defines a YANG data model for use with the
29 NETCONF protocol that allows the NETCONF client to
30 receive common NETCONF base event notifications.
32 Copyright (c) 2012 IETF Trust and the persons identified as
33 the document authors. All rights reserved.
35 Redistribution and use in source and binary forms, with or
36 without modification, is permitted pursuant to, and subject
37 to the license terms contained in, the Simplified BSD License
41 set forth in Section 4.c of the IETF Trust's Legal Provisions
42 Relating to IETF Documents
43 (http://trustee.ietf.org/license-info).
45 This version of this YANG module is part of RFC 6470; see
46 the RFC itself for full legal notices.";
48 revision "2012-02-06" {
50 "Initial version. Errata 3957 added.";
52 "RFC 6470: NETCONF Base Notifications";
55 grouping common-session-parms {
57 "Common session parameters to identify a
64 "Name of the user for the session.";
68 type nc:session-id-or-zero-type;
71 "Identifier of the session.
72 A NETCONF session MUST be identified by a non-zero value.
73 A non-NETCONF session MAY be identified by the value zero.";
79 "Address of the remote host for the session.";
90 grouping changed-by-parms {
92 "Common parameters to identify the source
93 of a change event, such as a configuration
94 or capability change.";
96 container changed-by {
98 "Indicates the source of the change.
99 If caused by internal action, then the
100 empty leaf 'server' will be present.
101 If caused by a management session, then
102 the name, remote host address, and session ID
103 of the session that made the change will be reported.";
104 choice server-or-user {
106 //FIXME: Use shorthand version of case statement, if possible
111 "If present, the change was caused
116 uses common-session-parms;
118 } // choice server-or-user
119 } // container changed-by-parms
123 notification netconf-config-change {
125 "Generated when the NETCONF server detects that the
126 <running> or <startup> configuration datastore
127 has been changed by a management session.
128 The notification summarizes the edits that
131 The server MAY choose to also generate this
132 notification while loading a datastore during the
133 boot process for the device.";
135 uses changed-by-parms;
144 description "The <running> datastore has changed.";
147 description "The <startup> datastore has changed";
152 "Indicates which configuration datastore has changed.";
157 "An edit record SHOULD be present for each distinct
158 edit operation that the server has detected on
159 the target datastore. This list MAY be omitted
160 if the detailed edit operations are not known.
161 The server MAY report entries in this list for
162 changes not made by a NETCONF session (e.g., CLI).";
165 type instance-identifier;
167 "Topmost node associated with the configuration change.
168 A server SHOULD set this object to the node within
169 the datastore that is being altered. A server MAY
170 set this object to one of the ancestors of the actual
171 node that was changed, or omit this object, if the
172 exact node is not known.";
176 type nc:edit-operation-type;
178 "Type of edit operation performed.
179 A server MUST set this object to the NETCONF edit
180 operation performed on the target datastore.";
183 } // notification netconf-config-change
190 notification netconf-capability-change {
192 "Generated when the NETCONF server detects that
193 the server capabilities have changed.
194 Indicates which capabilities have been added, deleted,
195 and/or modified. The manner in which a server
196 capability is changed is outside the scope of this
199 uses changed-by-parms;
201 leaf-list added-capability {
204 "List of capabilities that have just been added.";
207 leaf-list deleted-capability {
210 "List of capabilities that have just been deleted.";
213 leaf-list modified-capability {
216 "List of capabilities that have just been modified.
217 A capability is considered to be modified if the
218 base URI for the capability has not changed, but
219 one or more of the parameters encoded at the end of
220 the capability URI have changed.
221 The new modified value of the complete URI is returned.";
223 } // notification netconf-capability-change
226 notification netconf-session-start {
228 "Generated when a NETCONF server detects that a
229 NETCONF session has started. A server MAY generate
230 this event for non-NETCONF management sessions.
231 Indicates the identity of the user that started
233 uses common-session-parms;
234 } // notification netconf-session-start
239 notification netconf-session-end {
241 "Generated when a NETCONF server detects that a
242 NETCONF session has terminated.
243 A server MAY optionally generate this event for
244 non-NETCONF management sessions. Indicates the
245 identity of the user that owned the session,
246 and why the session was terminated.";
248 uses common-session-parms;
251 when "../termination-reason = 'killed'";
252 type nc:session-id-type;
254 "The ID of the session that directly caused this session
255 to be abnormally terminated. If this session was abnormally
256 terminated by a non-NETCONF session unknown to the server,
257 then this leaf will not be present.";
260 leaf termination-reason {
264 "The session was terminated by the client in normal
265 fashion, e.g., by the NETCONF <close-session>
266 protocol operation.";
270 "The session was terminated in abnormal
271 fashion, e.g., by the NETCONF <kill-session>
272 protocol operation.";
276 "The session was terminated because the transport layer
277 connection was unexpectedly closed.";
281 "The session was terminated because of inactivity,
282 e.g., waiting for the <hello> message or <rpc>
290 "The client's <hello> message was invalid.";
294 "The session was terminated for some other reason.";
299 "Reason the session was terminated.";
301 } // notification netconf-session-end
304 notification netconf-confirmed-commit {
306 "Generated when a NETCONF server detects that a
307 confirmed-commit event has occurred. Indicates the event
308 and the current state of the confirmed-commit procedure
311 "RFC 6241, Section 8.4";
313 uses common-session-parms {
314 when "confirm-event != 'timeout'";
321 "The confirmed-commit procedure has started.";
325 "The confirmed-commit procedure has been canceled,
326 e.g., due to the session being terminated, or an
327 explicit <cancel-commit> operation.";
331 "The confirmed-commit procedure has been canceled
332 due to the confirm-timeout interval expiring.
333 The common session parameters will not be present
339 "The confirmed-commit timeout has been extended,
340 e.g., by a new <confirmed-commit> operation.";
344 "The confirmed-commit procedure has been completed.";
349 "Indicates the event that caused the notification.";
354 "../confirm-event = 'start' or ../confirm-event = 'extend'";
358 "The configured timeout value if the event type
359 is 'start' or 'extend'. This value represents
360 the approximate number of seconds from the event
361 time when the 'timeout' event might occur.";
363 } // notification netconf-confirmed-commit