forked from tsaad-dev/te
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ietf-te-mpls.yang
467 lines (399 loc) · 12.6 KB
/
ietf-te-mpls.yang
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
module ietf-te-mpls {
yang-version 1.1;
namespace "urn:ietf:params:xml:ns:yang:ietf-te-mpls";
/* Replace with IANA when assigned */
prefix "te-mpls";
/* Import TE base model */
import ietf-te {
prefix te;
reference "draft-ietf-teas-yang-te: A YANG Data Model for Traffic
Engineering Tunnels and Interfaces";
}
import ietf-te-device {
prefix te-dev;
reference "draft-ietf-teas-yang-te: A YANG Data Model for Traffic
Engineering Tunnels and Interfaces";
}
/* Import TE MPLS types */
import ietf-te-packet-types {
prefix "te-packet-types";
reference "draft-ietf-teas-yang-te-types: A YANG Data Model for
Common Traffic Engineering Types";
}
/* Import TE generic types */
import ietf-te-types {
prefix te-types;
reference "draft-ietf-teas-yang-te-types: A YANG Data Model for
Common Traffic Engineering Types";
}
/* Import routing types */
import ietf-routing-types {
prefix rt-types;
reference "RFC8294: Common YANG Data Types for the Routing Area";
}
import ietf-mpls-static {
prefix mpls-static;
reference "draft-ietf-mpls-static-yang: A YANG Data Model
for MPLS Static LSPs";
}
import ietf-inet-types {
prefix inet;
reference "RFC6991: Common YANG Data Types";
}
organization
"IETF Traffic Engineering Architecture and Signaling (TEAS)
Working Group";
contact
"WG Web: <http://tools.ietf.org/wg/teas/>
WG List: <mailto:[email protected]>
Editor: Tarek Saad
<mailto:[email protected]>
Editor: Rakesh Gandhi
<mailto:[email protected]>
Editor: Vishnu Pavan Beeram
<mailto:[email protected]>
Editor: Xufeng Liu
<mailto: [email protected]>
Editor: Igor Bryskin
<mailto:[email protected]>";
description
"YANG data module for MPLS TE configurations,
state, RPC and notifications. The model fully conforms to
the Network Management Datastore Architecture (NMDA).
Copyright (c) 2018 IETF Trust and the persons
identified as authors of the code. All rights reserved.
Redistribution and use in source and binary forms, with or
without modification, is permitted pursuant to, and subject
to the license terms contained in, the Simplified BSD License
set forth in Section 4.c of the IETF Trust's Legal Provisions
Relating to IETF Documents
(https://trustee.ietf.org/license-info).
This version of this YANG module is part of RFC XXXX; see
the RFC itself for full legal notices.";
// RFC Ed.: replace XXXX with actual RFC number and remove this
// note.
// RFC Ed.: update the date below with the date of RFC publication
// and remove this note.
revision "2019-11-02" {
description "Latest update to MPLS TE YANG module.";
reference
"RFCXXXX: A YANG Data Model for MPLS-TE Tunnels and LSP(s)";
}
/* MPLS TE tunnel properties*/
grouping tunnel-igp-shortcut-config {
description "TE tunnel IGP shortcut configs";
leaf shortcut-eligible {
type boolean;
default "true";
description
"Whether this LSP is considered to be eligible for us as a
shortcut in the IGP. In the case that this leaf is set to
true, the IGP SPF calculation uses the metric specified to
determine whether traffic should be carried over this LSP";
}
leaf metric-type {
type identityref {
base te-types:lsp-metric-type;
}
default te-types:lsp-metric-inherited;
description
"The type of metric specification that should be used to set
the LSP(s) metric";
}
leaf metric {
type int32;
description
"The value of the metric that should be specified. The value
supplied in this leaf is used in conjunction with the metric
type to determine the value of the metric used by the system.
Where the metric-type is set to lsp-metric-absolute - the
value of this leaf is used directly; where it is set to
lsp-metric-relative, the relevant (positive or negative)
offset is used to formulate the metric; where metric-type
is lsp-metric-inherited, the value of this leaf is not
utilized";
}
leaf-list routing-afs {
type inet:ip-version;
description
"Address families";
}
}
grouping tunnel-igp-shortcuts {
description
"TE tunnel IGP shortcut grouping";
container tunnel-igp-shortcut {
description
"Tunnel IGP shortcut properties";
uses tunnel-igp-shortcut-config;
}
}
grouping tunnel-forwarding-adjacency-configs {
description "Tunnel forwarding adjacency grouping";
leaf binding-label {
type rt-types:mpls-label;
description "MPLS tunnel binding label";
}
leaf load-share {
type uint32 {
range "1..4294967295";
}
description "ECMP tunnel forwarding
load-share factor.";
}
leaf policy-class {
type uint8 {
range "1..7";
}
description
"The class associated with this tunnel";
}
}
grouping tunnel-forwarding-adjacency {
description "Properties for using tunnel in forwarding.";
container forwarding {
description
"Tunnel forwarding properties container";
uses tunnel-forwarding-adjacency-configs;
}
}
/*** End of MPLS TE tunnel configuration/state */
grouping te-lsp-auto-bandwidth-config {
description
"Configuration parameters related to autobandwidth";
leaf enabled {
type boolean;
default false;
description
"Enables MPLS auto-bandwidth on the
LSP";
}
leaf min-bw {
type te-packet-types:bandwidth-kbps;
description
"set the minimum bandwidth in Kbps for an
auto-bandwidth LSP";
}
leaf max-bw {
type te-packet-types:bandwidth-kbps;
description
"set the maximum bandwidth in Kbps for an
auto-bandwidth LSP";
}
leaf adjust-interval {
type uint32;
description
"time in seconds between adjustments to
LSP bandwidth";
}
leaf adjust-threshold {
type rt-types:percentage;
description
"percentage difference between the LSP's
specified bandwidth and its current bandwidth
allocation -- if the difference is greater than the
specified percentage, auto-bandwidth adjustment is
triggered";
}
}
grouping te-lsp-overflow-config {
description
"configuration for MPLS LSP bandwidth
overflow adjustment";
leaf enabled {
type boolean;
default false;
description
"Enables MPLS LSP bandwidth overflow
adjustment on the LSP";
}
leaf overflow-threshold {
type rt-types:percentage;
description
"bandwidth percentage change to trigger
an overflow event";
}
leaf trigger-event-count {
type uint16;
description
"number of consecutive overflow sample
events needed to trigger an overflow adjustment";
}
}
grouping te-lsp-underflow-config {
description
"configuration for MPLS LSP bandwidth
underflow adjustment";
leaf enabled {
type boolean;
default false;
description
"enables bandwidth underflow
adjustment on the LSP";
}
leaf underflow-threshold {
type rt-types:percentage;
description
"bandwidth percentage change to trigger
and underflow event";
}
leaf trigger-event-count {
type uint16;
description
"number of consecutive underflow sample
events needed to trigger an underflow adjustment";
}
}
grouping te-tunnel-bandwidth-config {
description
"Configuration parameters related to bandwidth for a tunnel";
leaf specification-type {
type te-packet-types:te-bandwidth-requested-type;
default specified;
description
"The method used for setting the bandwidth, either explicitly
specified or configured";
}
leaf set-bandwidth {
when "../specification-type = 'specified'" {
description
"The bandwidth value when bandwidth is explicitly
specified";
}
type te-packet-types:bandwidth-kbps;
description
"set bandwidth explicitly, e.g., using
offline calculation";
}
leaf class-type {
type te-types:te-ds-class;
description
"The Class-Type of traffic transported by the LSP.";
reference "RFC4124: section-4.3.1";
}
}
grouping te-tunnel-bandwidth-state {
description
"Operational state parameters relating to bandwidth for a tunnel";
leaf signaled-bandwidth {
type te-packet-types:bandwidth-kbps;
description
"The currently signaled bandwidth of the LSP. In the case where
the bandwidth is specified explicitly, then this will match the
value of the set-bandwidth leaf; in cases where the bandwidth is
dynamically computed by the system, the current value of the
bandwidth should be reflected.";
}
}
grouping tunnel-bandwidth_top {
description
"Top level grouping for specifying bandwidth for a tunnel";
container bandwidth-mpls {
description
"Bandwidth configuration for TE LSPs";
uses te-tunnel-bandwidth-config;
container state {
config false;
description
"State parameters related to bandwidth
configuration of TE tunnels";
uses te-tunnel-bandwidth-state;
}
container auto-bandwidth {
when "../specification-type = 'auto'" {
description
"Include this container for auto bandwidth
specific configuration";
}
description
"Parameters related to auto-bandwidth";
uses te-lsp-auto-bandwidth-config;
container overflow {
description
"configuration of MPLS overflow bandwidth
adjustment for the LSP";
uses te-lsp-overflow-config;
}
container underflow {
description
"configuration of MPLS underflow bandwidth
adjustment for the LSP";
uses te-lsp-underflow-config;
}
}
}
}
grouping te-path-bandwidth_top {
description
"Top level grouping for specifying bandwidth for a TE path";
container bandwidth {
description
"Bandwidth configuration for TE LSPs";
uses te-tunnel-bandwidth-config;
container state {
config false;
description
"State parameters related to bandwidth
configuration of TE tunnels";
uses te-tunnel-bandwidth-state;
}
}
}
/**
* MPLS TE augmentations
*/
augment "/te:te/te-dev:performance-thresholds" {
uses te-packet-types:performance-metrics-throttle-container-packet;
description
"Performance parameters configurable thresholds";
}
/* MPLS TE interface augmentations */
/* MPLS TE tunnel augmentations */
augment "/te:te/te:tunnels/te:tunnel" {
description "MPLS TE tunnel config augmentations";
uses tunnel-igp-shortcuts;
uses tunnel-forwarding-adjacency;
uses tunnel-bandwidth_top;
}
/* MPLS TE LSPs augmentations */
augment "/te:te/te:tunnels/te:tunnel/" +
"te:p2p-primary-paths/te:p2p-primary-path" {
when "/te:te/te:tunnels/te:tunnel" +
"/te:p2p-primary-paths/te:p2p-primary-path" +
"/te:path-setup-protocol = 'te-types:path-setup-static'" {
description
"When the path is statically provisioned";
}
description "MPLS TE LSP augmentation";
leaf static-lsp-name {
type mpls-static:static-lsp-ref;
description "Static LSP name";
}
}
augment "/te:te/te:tunnels/te:tunnel/" +
"te:p2p-secondary-paths/te:p2p-secondary-path" {
when "/te:te/te:tunnels/te:tunnel" +
"/te:p2p-secondary-paths/te:p2p-secondary-path/" +
"te:path-setup-protocol = 'te-types:path-setup-static'" {
description
"When the path is statically provisioned";
}
description "MPLS TE LSP augmentation";
leaf static-lsp-name {
type mpls-static:static-lsp-ref;
description "Static LSP name";
}
}
augment "/te:te/te:globals/te:named-path-constraints/" +
"te:named-path-constraint" {
description "foo";
uses te-path-bandwidth_top;
}
augment "/te:te/te:tunnels/te:tunnel/te:p2p-primary-paths" +
"/te:p2p-primary-path/te:lsps/te:lsp" {
description
"MPLS TE generic data augmentation pertaining to specific TE
LSP";
uses te-packet-types:performance-metrics-attributes-packet;
}
}