blob: 6b3ddc194d4ac10c72ffcd6dd37cef3d36697709 [file] [log] [blame]
Thomas Vachuska8ca75a22017-08-24 16:12:59 -07001module openconfig-rsvp-sr-ext {
2 yang-version "1";
3
4 namespace "http://openconfig.net/yang/rsvp-sr-ext";
5 prefix "oc-sr-rsvp-ext";
6
7 import openconfig-extensions { prefix "oc-ext"; }
8 import openconfig-types { prefix "oc-types"; }
9 import openconfig-network-instance { prefix "oc-ni"; }
10
11 organization
12 "OpenConfig working group";
13
14 contact
15 "OpenConfig working group
16 www.openconfig.net";
17
18 description
19 "This module adds extensions to the OpenConfig MPLS models to
20 provide extensions which allow the coexistence of RSVP-TE and
21 Segment Routing (SR) within the same network. It augments the
22 existing OpenConfig segment routing (SR) and RSVP-TE models
23 where required.";
24
25 oc-ext:openconfig-version "0.1.0";
26
27 revision 2017-03-06 {
28 description
29 "Initial revision.";
30 reference "0.1.0";
31 }
32
33 grouping bandwidth-measurement-global-state {
34 description
35 "Operational state parameters for bandwidth measurement which
36 apply globally to the device.";
37
38 leaf effective-adjustment-interval {
39 type uint32;
40 units "seconds";
41 description
42 "The effective adjustment interval that is being used by
43 the system. In the case that the adjustment-interval leaf
44 is set to a non-integer multiple of the collection-interval,
45 and the system does not support this, the value of this leaf
46 should reflect the effective value of the adjustment interval
47 that it has selected. In the case where no rounding of the
48 adjustment interval has occurred, this value should have the
49 same value as the adjustment-inerval leaf.";
50 }
51 }
52
53 grouping bandwidth-measurement-global-config {
54 description
55 "Configuration parameters for bandwidth measurement which apply
56 globally to the device.";
57
58 leaf measure-sr-traffic {
59 type boolean;
60 description
61 "When this leaf is set to true, the local system should
62 measure the bandwidth utilisation of SR traffic on interfaces
63 for which TED entries are being generated.
64
65 In the case that this functionality is enabled, traffic
66 forwarded using LFIB entries that correspond to MPLS
67 labels which correspond to SR SIDs should be accounted
68 for.";
69 reference
70 "draft-sitaraman-sr-rsvp-coexistence-rec-01";
71 }
72
73 // TODO(robjs): For future extension, traffic accounting for
74 // non-SR, non-RSVP traffic could be added here. e.g., LDP,
75 // BGP-LU etc.
76
77 leaf collection-interval {
78 type uint32;
79 units "seconds";
80 description
81 "The interval at which the collection of interface
82 statistics relating to non-RSVP-TE traffic should be
83 performed";
84 reference
85 "draft-sitaraman-sr-rsvp-coexistence-rec-01";
86 }
87
88 leaf adjustment-interval {
89 type uint32;
90 units "seconds";
91 description
92 "The interval after which an adjustment to the utilised
93 bandwidth on the interface is made. This value must be
94 greater than, or equal to, the collection interval for
95 statistics. This value is referred to as N in
96 draft-sitaraman-sr-rsvp-coexistence-rec-01.
97
98 After N seconds have expired, the
99 arithmetic mean of the samples is taken, and this is
100 considered as the non-RSVP-TE utilisation of the
101 interface. In the case that the adjustment interval is
102 an integer >1 multiple of the collection interval, this
103 serves to provide smoothing of the collected bandwidth
104 statistics.";
105 reference
106 "draft-sitaraman-sr-rsvp-coexistence-rec-01";
107 }
108
109 leaf bandwidth-multiplier {
110 type decimal64 {
111 fraction-digits 4;
112 }
113 default 1.0000;
114 description
115 "A multiplier applied to the sampled bandwidth which
116 determines the value that is propagated to the IGP TED.
117 By default this value is 1.0000, and hence the actual
118 sampled value is flooded.";
119 }
120 }
121
122 grouping bandwidth-measurement-update-config {
123 description
124 "Configuration parameters related to when the bandwidth
125 measurement information is used to update the IGP TED.";
126
127 leaf update-trigger {
128 type enumeration {
129 enum ADJUSTED_MAX_RESERVABLE_PCT {
130 description
131 "Update of a new maximum reservable bandwidth IGP
132 TLV is based on the value changing >= X% of
133 the currently flooded adjusted-absolute-subscription-bw.
134 The percentage of this value that is used is specified
135 by the adjusted-max-reservable-bw-pct leaf.";
136 }
137 enum SR_TRAFFIC_PCT {
138 description
139 "Update of the new maximum reservable bandwidth IGP
140 TLV is based on the value changing >= X% of the last
141 calculated segment routing traffic utilisation for the
142 interface. The percentage delta of this value is
143 specified by the sr-traffic-pct leaf.";
144 }
145 }
146 description
147 "The trigger that should be used to determine when the IGP
148 TED is updated with new information as to the effective
149 maximum reservable bandwidth
150 (adjusted-absolute-subscription-bw)";
151 }
152
153 leaf adjusted-max-reservable-bw-pct {
154 when "../update-trigger = 'ADJUSTED_MAX_RESERVABLE_PCT'" {
155 description
156 "Only allow the adjusted-max-reservable-bw update trigger
157 to be specified when the update-trigger mode is specified
158 to be a percentage of the currently flooded value.";
159 }
160 type oc-types:percentage;
161 description
162 "The delta in the adjusted-max-reservable-bandwidth that
163 should trigger an update in the value which is flooded
164 through the IGP TED.
165 The delta is measured as a percentage of the
166 current adjusted value of the maximum reservable bandwidth
167 of the interface, as specified by the
168 adjusted-absolute-subscription-bw RSVP-TE leaf.";
169 reference
170 "draft-sitaraman-sr-rsvp-coexistence-rec-01";
171 }
172
173 leaf sr-traffic-pct {
174 when "../update-trigger = 'SR_TRAFFIC_PCT'" {
175 description
176 "Only allow the SR traffic percentage trigger to be
177 specified when the update trigger is defined to be a
178 percentage of the last calculated SR traffic value.";
179 }
180 type oc-types:percentage;
181 description
182 "The change in the calculated SR traffic on the interface
183 that should trigger an update in the value of the
184 maximum reservable bandwidth flooded through the IGP TED.
185 The value is specified as a percentage of the
186 last-calculated-sr-traffic state leaf.";
187 }
188 }
189
190 grouping bandwidth-measurement-global-structural {
191 description
192 "Structural grouping for the measurement of segment routing
193 traffic, and its advertisement into the IGP TED.";
194
195 container bandwidth-measurement {
196 description
197 "Configuration and operational state parameters related to
198 how bandwidth utilisation is measured and flooded into the
199 IGP.";
200
201 container config {
202 description
203 "Configuration parameters relating to bandwidth
204 measurement.";
205
206 uses bandwidth-measurement-global-config;
207 }
208
209 container state {
210 config false;
211 description
212 "Operational state parameters relating to bandwidth
213 measurement";
214
215 uses bandwidth-measurement-global-config;
216 uses bandwidth-measurement-global-state;
217 }
218
219 container update-trigger {
220 description
221 "Configuration and operational state parameters related
222 to the update trigger for flooding new bandwidth
223 information into the IGP.";
224
225 container config {
226 description
227 "Configuration parameters related to the bandwidth
228 measurement update trigger.";
229
230 uses bandwidth-measurement-update-config;
231 }
232
233 container state {
234 config false;
235 description
236 "Operational state parameters related to the bandwidth
237 measurement update trigger.";
238
239 uses bandwidth-measurement-update-config;
240 }
241 }
242 }
243 }
244
245 augment "/oc-ni:network-instances/oc-ni:network-instance/" +
246 "oc-ni:mpls/oc-ni:te-global-attributes" {
247 description
248 "Add the bandwidth measurement parameters to MPLS global
249 traffic engineering hierarchy.";
250
251 uses bandwidth-measurement-global-structural;
252 }
253
254 grouping bandwidth-measurement-rsvp-te-adjusted-state {
255 description
256 "Logical grouping augmented into the RSVP-TE hierarchy to
257 provide an operational state value which reflects the
258 adjusted RSVP-TE available bandwidth.";
259
260 leaf adjusted-absolute-subscription-bw {
261 type uint64;
262 units "kbps";
263 description
264 "The adjusted absolute value (in kbps) of the
265 bandwidth which is reservable to RSVP-TE on the
266 local system. In the case that the bandwidth-measurement
267 configuration does not account for non-RSVP-TE traffic
268 then this value is equal to the
269 calculated-absolute-subscription-bw, in the case that
270 non-RSVP-TE traffic is being accounted for, it is lower
271 such that calculated-absolute-subscription-bw -
272 adjusted-absolute-subscription-bw = the current calculated
273 non-RSVP-TE traffic.
274
275 This value reflects the last flooded value of the maximum
276 reservable bandwidth, or subscription.";
277 }
278 }
279
280 augment "/oc-ni:network-instances/oc-ni:network-instance/" +
281 "oc-ni:mpls/oc-ni:signaling-protocols/oc-ni:rsvp-te/" +
282 "oc-ni:interface-attributes/oc-ni:interface/" +
283 "oc-ni:subscription/oc-ni:state" {
284
285 description
286 "Augmentation to add the adjusted RSVP-TE available bandwidth
287 state to the RSVP-TE signaling protocol.";
288
289 uses bandwidth-measurement-rsvp-te-adjusted-state;
290 }
291
292 grouping bandwidth-measurement-intf-structural {
293 description
294 "Structural grouping containing interface bandwidth
295 measurement configuration and operational state
296 parameters.";
297
298 container bandwidth-measurement {
299 description
300 "Configuration and operational state parameters relating to
301 per-interface bandwidth measurement. These parameters are
302 used in the case that RSVP-TE coexists with other MPLS
303 signaling protocols on an interface.";
304
305 container state {
306 config false;
307 description
308 "Operational state parameters relating to the containing
309 interface's bandwidth measurement.";
310
311 uses bandwidth-measurement-intf-state;
312 }
313 }
314 }
315
316 grouping bandwidth-measurement-intf-state {
317 description
318 "Operational state parameters per-interface for the measured
319 bandwidth on an interface";
320
321 leaf last-sample-time {
322 type oc-types:timeticks64;
323 description
324 "The time at which the last sample of bandwidth utilisation
325 for both RSVP-TE and non-RSVP-TE traffic was taken. This value
326 is represented in nanoseconds since the Unix epoch.";
327 }
328
329 leaf last-sample-measured-rsvp-util {
330 type uint64;
331 units "kbps";
332 description
333 "The measured RSVP-TE bandwidth utilisation at the last sample
334 (whose time is indicated in last-sample-time). This value is
335 expressed as a 64-bit unsigned integer representing the number
336 of kilobits per second that RSVP-TE traffic is consuming on
337 the interface.";
338 }
339
340 leaf last-sample-measured-sr-util {
341 type uint64;
342 units "kbps";
343 description
344 "The measured Segment Routing bandwidth utilisation at the
345 last sample (whose time is indicated in last-sample-time).
346 This value is expressed as a 64-bit unsigned integer
347 representing the number of kilobits per second that Segment
348 Routing traffic is consuming on the interface.";
349 }
350
351 leaf last-calculated-time {
352 type oc-types:timeticks64;
353 description
354 "The time at which the last calculated value for bandwidth
355 utilisation was performed.";
356 }
357
358 leaf last-calculated-sr-utilisation {
359 type uint64;
360 description
361 "The last calculated value of the Segment Routing utilisation
362 (taken post any averaging or adjustment that occurs). This
363 value is updated regardless of whether the value was flooded
364 or not.";
365 }
366
367 leaf last-flooded-time {
368 type oc-types:timeticks64;
369 description
370 "The time, expressed in nanoseconds since the epoch, at which
371 the bandwidth utilisation of non-RSVP-TE traffic resulted in
372 the value being flooded in the IGP. If the configuration of the
373 local system specifies a 0% change requires flooding, this leaf
374 will always reflect the value of the last-calculated-time. In
375 systems that have suppression due to a >0% delta being required
376 then it indicates the last time that the percentage threshold
377 was exceeded.";
378 }
379 }
380
381 augment "/oc-ni:network-instances/oc-ni:network-instance/oc-ni:mpls" +
382 "/oc-ni:te-interface-attributes/oc-ni:interface" {
383 description
384 "Augment the per-interface bandwidth measurement parameters into the
385 MPLS hierarchy of network instance.";
386
387 uses bandwidth-measurement-intf-structural;
388 }
389}