]>
Commit | Line | Data |
---|---|---|
e9ce224b RW |
1 | module frr-ripngd { |
2 | yang-version 1.1; | |
3 | namespace "http://frrouting.org/yang/ripngd"; | |
4 | prefix frr-ripngd; | |
5 | ||
6 | import ietf-inet-types { | |
7 | prefix inet; | |
8 | } | |
9 | import ietf-yang-types { | |
10 | prefix yang; | |
11 | } | |
12 | import frr-interface { | |
13 | prefix frr-interface; | |
14 | } | |
15 | import frr-route-types { | |
16 | prefix frr-route-types; | |
17 | } | |
18 | ||
19 | organization | |
20 | "Free Range Routing"; | |
21 | contact | |
22 | "FRR Users List: <mailto:frog@lists.frrouting.org> | |
23 | FRR Development List: <mailto:dev@lists.frrouting.org>"; | |
24 | description | |
25 | "This module defines a model for managing FRR ripngd daemon."; | |
26 | ||
27 | revision 2018-11-27 { | |
28 | description | |
29 | "Initial revision."; | |
30 | reference | |
31 | "RFC 2080: RIPng for IPv6."; | |
32 | } | |
33 | ||
34 | container ripngd { | |
35 | /* | |
36 | * Global configuration data | |
37 | */ | |
38 | container instance { | |
39 | presence "Present if the RIPng protocol is enabled."; | |
40 | description | |
41 | "RIPng routing instance."; | |
42 | ||
43 | leaf allow-ecmp { | |
44 | type boolean; | |
45 | default "false"; | |
46 | description | |
47 | "Allow equal-cost multi-path."; | |
48 | } | |
49 | leaf default-information-originate { | |
50 | type boolean; | |
51 | default "false"; | |
52 | description | |
53 | "Control distribution of default route."; | |
54 | } | |
55 | leaf default-metric { | |
56 | type uint8 { | |
57 | range "1..16"; | |
58 | } | |
59 | default "1"; | |
60 | description | |
61 | "Default metric of redistributed routes."; | |
62 | } | |
63 | leaf-list network { | |
64 | type inet:ipv6-prefix; | |
65 | description | |
66 | "Enable RIPng on the specified IPv6 network."; | |
67 | } | |
68 | leaf-list interface { | |
69 | type string { | |
70 | length "1..16"; | |
71 | } | |
72 | description | |
73 | "Enable RIPng on the specified interface."; | |
74 | } | |
75 | list offset-list { | |
76 | key "interface direction"; | |
77 | description | |
78 | "Offset-list to modify route metric."; | |
79 | leaf interface { | |
80 | type string; | |
81 | description | |
82 | "Interface to match. Use '*' to match all interfaces."; | |
83 | } | |
84 | leaf direction { | |
85 | type enumeration { | |
86 | enum in { | |
87 | value 0; | |
88 | description | |
89 | "Incoming updates."; | |
90 | } | |
91 | enum out { | |
92 | value 1; | |
93 | description | |
94 | "Outgoing updates."; | |
95 | } | |
96 | } | |
97 | description | |
98 | "Incoming or outgoing updates."; | |
99 | } | |
100 | leaf access-list { | |
101 | type string; | |
102 | mandatory true; | |
103 | description | |
104 | "Access-list name."; | |
105 | } | |
106 | leaf metric { | |
107 | type uint8 { | |
108 | range "0..16"; | |
109 | } | |
110 | mandatory true; | |
111 | description | |
112 | "Route metric."; | |
113 | } | |
114 | } | |
115 | leaf-list passive-interface { | |
116 | type string { | |
117 | length "1..16"; | |
118 | } | |
119 | description | |
120 | "A list of interfaces where the sending of RIPng packets | |
121 | is disabled."; | |
122 | } | |
123 | list redistribute { | |
124 | key "protocol"; | |
125 | description | |
126 | "Redistributes routes learned from other routing protocols."; | |
127 | leaf protocol { | |
128 | type frr-route-types:frr-route-types-v6; | |
129 | description | |
130 | "Routing protocol."; | |
131 | must '. != "ripng"'; | |
132 | } | |
133 | leaf route-map { | |
134 | type string { | |
135 | length "1..max"; | |
136 | } | |
137 | description | |
138 | "Applies the conditions of the specified route-map to | |
139 | routes that are redistributed into the RIPng routing | |
140 | instance."; | |
141 | } | |
142 | leaf metric { | |
143 | type uint8 { | |
144 | range "0..16"; | |
145 | } | |
146 | description | |
147 | "Metric used for the redistributed route. If a metric is | |
148 | not specified, the metric configured with the | |
149 | default-metric attribute in RIPng router configuration is | |
150 | used. If the default-metric attribute has not been | |
151 | configured, the default metric for redistributed routes | |
152 | is 0."; | |
153 | } | |
154 | } | |
155 | leaf-list static-route { | |
156 | type inet:ipv6-prefix; | |
157 | description | |
158 | "RIPng static routes."; | |
159 | } | |
160 | leaf-list aggregate-address { | |
161 | type inet:ipv6-prefix; | |
162 | description | |
163 | "RIPng aggregate route announcement."; | |
164 | } | |
165 | container timers { | |
166 | description | |
167 | "Settings of basic timers"; | |
168 | leaf flush-interval { | |
169 | type uint16 { | |
170 | range "1..65535"; | |
171 | } | |
172 | units "seconds"; | |
173 | default "120"; | |
174 | description | |
175 | "Interval before a route is flushed from the routing | |
176 | table."; | |
177 | } | |
178 | leaf holddown-interval { | |
179 | type uint16 { | |
180 | range "1..65535"; | |
181 | } | |
182 | units "seconds"; | |
183 | default "180"; | |
184 | description | |
185 | "Interval before better routes are released."; | |
186 | } | |
187 | leaf update-interval { | |
188 | type uint16 { | |
189 | range "1..65535"; | |
190 | } | |
191 | units "seconds"; | |
192 | default "30"; | |
193 | description | |
194 | "Interval at which RIPng updates are sent."; | |
195 | } | |
196 | } | |
197 | } | |
198 | ||
199 | /* | |
200 | * Operational data. | |
201 | */ | |
202 | container state { | |
203 | config false; | |
204 | description | |
205 | "Operational data."; | |
206 | ||
207 | container neighbors { | |
208 | description | |
209 | "Neighbor information."; | |
210 | list neighbor { | |
211 | key "address"; | |
212 | description | |
213 | "A RIPng neighbor."; | |
214 | leaf address { | |
215 | type inet:ipv6-address; | |
216 | description | |
217 | "IPv6 address that a RIPng neighbor is using as its | |
218 | source address."; | |
219 | } | |
220 | leaf last-update { | |
221 | type yang:date-and-time; | |
222 | description | |
223 | "The time when the most recent RIPng update was | |
224 | received from this neighbor."; | |
225 | } | |
226 | leaf bad-packets-rcvd { | |
227 | type yang:counter32; | |
228 | description | |
229 | "The number of RIPng invalid packets received from | |
230 | this neighbor which were subsequently discarded | |
231 | for any reason (e.g. a version 0 packet, or an | |
232 | unknown command type)."; | |
233 | } | |
234 | leaf bad-routes-rcvd { | |
235 | type yang:counter32; | |
236 | description | |
237 | "The number of routes received from this neighbor, | |
238 | in valid RIPng packets, which were ignored for any | |
239 | reason (e.g. unknown address family, or invalid | |
240 | metric)."; | |
241 | } | |
242 | } | |
243 | } | |
244 | container routes { | |
245 | description | |
246 | "Route information."; | |
247 | list route { | |
248 | key "prefix"; | |
249 | description | |
250 | "A RIPng IPv6 route."; | |
251 | leaf prefix { | |
252 | type inet:ipv6-prefix; | |
253 | description | |
254 | "IPv6 address and prefix length, in the format | |
255 | specified in RFC6991."; | |
256 | } | |
257 | leaf next-hop { | |
258 | type inet:ipv6-address; | |
259 | description | |
260 | "Next hop IPv6 address."; | |
261 | } | |
262 | leaf interface { | |
263 | type string; | |
264 | description | |
265 | "The interface that the route uses."; | |
266 | } | |
267 | leaf metric { | |
268 | type uint8 { | |
269 | range "0..16"; | |
270 | } | |
271 | description | |
272 | "Route metric."; | |
273 | } | |
274 | } | |
275 | } | |
276 | } | |
277 | } | |
278 | ||
279 | /* | |
280 | * Per-interface configuration data | |
281 | */ | |
282 | augment "/frr-interface:lib/frr-interface:interface" { | |
283 | container ripng { | |
284 | description | |
285 | "RIPng interface parameters."; | |
286 | leaf split-horizon { | |
287 | type enumeration { | |
288 | enum "disabled" { | |
289 | value 0; | |
290 | description | |
291 | "Disables split-horizon processing."; | |
292 | } | |
293 | enum "simple" { | |
294 | value 1; | |
295 | description | |
296 | "Enables simple split-horizon processing."; | |
297 | } | |
298 | enum "poison-reverse" { | |
299 | value 2; | |
300 | description | |
301 | "Enables split-horizon processing with poison | |
302 | reverse."; | |
303 | } | |
304 | } | |
305 | default "simple"; | |
306 | description | |
307 | "Controls RIPng split-horizon processing on the specified | |
308 | interface."; | |
309 | } | |
310 | } | |
311 | } | |
312 | ||
313 | /* | |
314 | * RPCs | |
315 | */ | |
316 | rpc clear-ripng-route { | |
317 | description | |
318 | "Clears RIPng routes from the IPv6 routing table and routes | |
319 | redistributed into the RIPng protocol."; | |
320 | } | |
321 | } |