2 * Copyright (C) 2001,2002 Sampo Saaristo
3 * Tampere University of Technology
4 * Institute of Communications Engineering
5 * Copyright (C) 2018 Volta Networks
8 * This program is free software; you can redistribute it and/or modify it
9 * under the terms of the GNU General Public License as published by the Free
10 * Software Foundation; either version 2 of the License, or (at your option)
13 * This program is distributed in the hope that it will be useful, but WITHOUT
14 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
15 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
18 * You should have received a copy of the GNU General Public License along
19 * with this program; see the file COPYING; if not, write to the Free Software
20 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
30 #include "northbound_cli.h"
33 #include "lib/linklist.h"
34 #include "isisd/isisd.h"
35 #include "isisd/isis_cli.h"
36 #include "isisd/isis_misc.h"
37 #include "isisd/isis_circuit.h"
38 #include "isisd/isis_csm.h"
40 #ifndef VTYSH_EXTRACT_PL
41 #include "isisd/isis_cli_clippy.c"
47 * XPath: /frr-isisd:isis/instance
49 DEFPY_NOSH(router_isis
, router_isis_cmd
, "router isis WORD$tag",
52 "ISO Routing area tag\n")
55 char base_xpath
[XPATH_MAXLEN
];
57 snprintf(base_xpath
, XPATH_MAXLEN
,
58 "/frr-isisd:isis/instance[area-tag='%s']", tag
);
59 nb_cli_enqueue_change(vty
, ".", NB_OP_CREATE
, NULL
);
60 /* default value in yang for is-type is level-1, but in FRR
61 * the first instance is assigned is-type level-1-2. We
62 * need to make sure to set it in the yang model so that it
63 * is consistent with what FRR sees.
65 if (listcount(isis
->area_list
) == 0)
66 nb_cli_enqueue_change(vty
, "./is-type", NB_OP_MODIFY
,
68 ret
= nb_cli_apply_changes(vty
, base_xpath
);
69 if (ret
== CMD_SUCCESS
)
70 VTY_PUSH_XPATH(ISIS_NODE
, base_xpath
);
75 DEFPY(no_router_isis
, no_router_isis_cmd
, "no router isis WORD$tag",
78 "ISO Routing area tag\n")
80 char temp_xpath
[XPATH_MAXLEN
];
81 struct listnode
*node
, *nnode
;
82 struct isis_circuit
*circuit
= NULL
;
83 struct isis_area
*area
= NULL
;
85 if (!yang_dnode_exists(vty
->candidate_config
->dnode
,
86 "/frr-isisd:isis/instance[area-tag='%s']",
88 vty_out(vty
, "ISIS area %s not found.\n", tag
);
89 return CMD_ERR_NOTHING_TODO
;
92 nb_cli_enqueue_change(vty
, ".", NB_OP_DESTROY
, NULL
);
93 area
= isis_area_lookup(tag
);
94 if (area
&& area
->circuit_list
&& listcount(area
->circuit_list
)) {
95 for (ALL_LIST_ELEMENTS(area
->circuit_list
, node
, nnode
,
97 /* add callbacks to delete each of the circuits listed
99 const char *vrf_name
=
100 circuit
->interface
->vrf
->name
;
102 temp_xpath
, XPATH_MAXLEN
,
103 "/frr-interface:lib/interface[name='%s'][vrf='%s']/frr-isisd:isis",
104 circuit
->interface
->name
, vrf_name
);
105 nb_cli_enqueue_change(vty
, temp_xpath
, NB_OP_DESTROY
,
110 return nb_cli_apply_changes(
111 vty
, "/frr-isisd:isis/instance[area-tag='%s']", tag
);
114 void cli_show_router_isis(struct vty
*vty
, struct lyd_node
*dnode
,
118 vty_out(vty
, "router isis %s\n",
119 yang_dnode_get_string(dnode
, "./area-tag"));
123 * XPath: /frr-interface:lib/interface/frr-isisd:isis/
124 * XPath: /frr-interface:lib/interface/frr-isisd:isis/ipv4-routing
125 * XPath: /frr-interface:lib/interface/frr-isisd:isis/ipv6-routing
126 * XPath: /frr-isisd:isis/instance
128 DEFPY(ip_router_isis
, ip_router_isis_cmd
, "ip router isis WORD$tag",
129 "Interface Internet Protocol config commands\n"
130 "IP router interface commands\n"
131 "IS-IS routing protocol\n"
132 "Routing process tag\n")
134 char temp_xpath
[XPATH_MAXLEN
];
135 const char *circ_type
;
136 struct isis_area
*area
;
137 struct interface
*ifp
;
139 /* area will be created if it is not present. make sure the yang model
140 * is synced with FRR and call the appropriate NB cb.
142 area
= isis_area_lookup(tag
);
144 snprintf(temp_xpath
, XPATH_MAXLEN
,
145 "/frr-isisd:isis/instance[area-tag='%s']", tag
);
146 nb_cli_enqueue_change(vty
, temp_xpath
, NB_OP_CREATE
, tag
);
147 snprintf(temp_xpath
, XPATH_MAXLEN
,
148 "/frr-isisd:isis/instance[area-tag='%s']/is-type",
150 nb_cli_enqueue_change(
151 vty
, temp_xpath
, NB_OP_MODIFY
,
152 listcount(isis
->area_list
) == 0 ? "level-1-2" : NULL
);
153 nb_cli_enqueue_change(vty
, "./frr-isisd:isis", NB_OP_CREATE
,
155 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/area-tag",
157 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/ipv4-routing",
158 NB_OP_MODIFY
, "true");
159 nb_cli_enqueue_change(
160 vty
, "./frr-isisd:isis/circuit-type", NB_OP_MODIFY
,
161 listcount(isis
->area_list
) == 0 ? "level-1-2"
164 /* area exists, circuit type defaults to its area's is_type */
165 switch (area
->is_type
) {
167 circ_type
= "level-1";
170 circ_type
= "level-2";
172 case IS_LEVEL_1_AND_2
:
173 circ_type
= "level-1-2";
176 /* just to silence compiler warnings */
177 return CMD_WARNING_CONFIG_FAILED
;
179 nb_cli_enqueue_change(vty
, "./frr-isisd:isis", NB_OP_CREATE
,
181 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/area-tag",
183 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/ipv4-routing",
184 NB_OP_MODIFY
, "true");
185 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/circuit-type",
186 NB_OP_MODIFY
, circ_type
);
189 /* check if the interface is a loopback and if so set it as passive */
190 pthread_rwlock_rdlock(&running_config
->lock
);
192 ifp
= nb_running_get_entry(NULL
, VTY_CURR_XPATH
, false);
193 if (ifp
&& if_is_loopback(ifp
))
194 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/passive",
195 NB_OP_MODIFY
, "true");
197 pthread_rwlock_unlock(&running_config
->lock
);
199 return nb_cli_apply_changes(vty
, NULL
);
202 DEFPY(ip6_router_isis
, ip6_router_isis_cmd
, "ipv6 router isis WORD$tag",
203 "Interface Internet Protocol config commands\n"
204 "IP router interface commands\n"
205 "IS-IS routing protocol\n"
206 "Routing process tag\n")
208 char temp_xpath
[XPATH_MAXLEN
];
209 const char *circ_type
;
210 struct isis_area
*area
;
211 struct interface
*ifp
;
213 /* area will be created if it is not present. make sure the yang model
214 * is synced with FRR and call the appropriate NB cb.
216 area
= isis_area_lookup(tag
);
218 snprintf(temp_xpath
, XPATH_MAXLEN
,
219 "/frr-isisd:isis/instance[area-tag='%s']", tag
);
220 nb_cli_enqueue_change(vty
, temp_xpath
, NB_OP_CREATE
, tag
);
221 snprintf(temp_xpath
, XPATH_MAXLEN
,
222 "/frr-isisd:isis/instance[area-tag='%s']/is-type",
224 nb_cli_enqueue_change(
225 vty
, temp_xpath
, NB_OP_MODIFY
,
226 listcount(isis
->area_list
) == 0 ? "level-1-2" : NULL
);
227 nb_cli_enqueue_change(vty
, "./frr-isisd:isis", NB_OP_CREATE
,
229 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/area-tag",
231 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/ipv6-routing",
232 NB_OP_MODIFY
, "true");
233 nb_cli_enqueue_change(
234 vty
, "./frr-isisd:isis/circuit-type", NB_OP_MODIFY
,
235 listcount(isis
->area_list
) == 0 ? "level-1-2"
238 /* area exists, circuit type defaults to its area's is_type */
239 switch (area
->is_type
) {
241 circ_type
= "level-1";
244 circ_type
= "level-2";
246 case IS_LEVEL_1_AND_2
:
247 circ_type
= "level-1-2";
250 /* just to silence compiler warnings */
251 return CMD_WARNING_CONFIG_FAILED
;
253 nb_cli_enqueue_change(vty
, "./frr-isisd:isis", NB_OP_CREATE
,
255 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/area-tag",
257 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/ipv6-routing",
258 NB_OP_MODIFY
, "true");
259 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/circuit-type",
260 NB_OP_MODIFY
, circ_type
);
263 /* check if the interface is a loopback and if so set it as passive */
264 pthread_rwlock_rdlock(&running_config
->lock
);
266 ifp
= nb_running_get_entry(NULL
, VTY_CURR_XPATH
, false);
267 if (ifp
&& if_is_loopback(ifp
))
268 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/passive",
269 NB_OP_MODIFY
, "true");
271 pthread_rwlock_unlock(&running_config
->lock
);
273 return nb_cli_apply_changes(vty
, NULL
);
276 DEFPY(no_ip_router_isis
, no_ip_router_isis_cmd
,
277 "no <ip|ipv6>$ip router isis [WORD]$tag",
279 "Interface Internet Protocol config commands\n"
280 "IP router interface commands\n"
281 "IP router interface commands\n"
282 "IS-IS routing protocol\n"
283 "Routing process tag\n")
285 const struct lyd_node
*dnode
;
287 dnode
= yang_dnode_get(vty
->candidate_config
->dnode
,
288 "%s/frr-isisd:isis", VTY_CURR_XPATH
);
293 * If both ipv4 and ipv6 are off delete the interface isis container.
295 if (strmatch(ip
, "ipv6")) {
296 if (!yang_dnode_get_bool(dnode
, "./ipv4-routing"))
297 nb_cli_enqueue_change(vty
, "./frr-isisd:isis",
298 NB_OP_DESTROY
, NULL
);
300 nb_cli_enqueue_change(vty
,
301 "./frr-isisd:isis/ipv6-routing",
302 NB_OP_MODIFY
, "false");
304 if (!yang_dnode_get_bool(dnode
, "./ipv6-routing"))
305 nb_cli_enqueue_change(vty
, "./frr-isisd:isis",
306 NB_OP_DESTROY
, NULL
);
308 nb_cli_enqueue_change(vty
,
309 "./frr-isisd:isis/ipv4-routing",
310 NB_OP_MODIFY
, "false");
313 return nb_cli_apply_changes(vty
, NULL
);
316 void cli_show_ip_isis_ipv4(struct vty
*vty
, struct lyd_node
*dnode
,
319 if (!yang_dnode_get_bool(dnode
, NULL
))
321 vty_out(vty
, " ip router isis %s\n",
322 yang_dnode_get_string(dnode
, "../area-tag"));
325 void cli_show_ip_isis_ipv6(struct vty
*vty
, struct lyd_node
*dnode
,
328 if (!yang_dnode_get_bool(dnode
, NULL
))
330 vty_out(vty
, " ipv6 router isis %s\n",
331 yang_dnode_get_string(dnode
, "../area-tag"));
335 * XPath: /frr-isisd:isis/instance/area-address
337 DEFPY(net
, net_cmd
, "[no] net WORD",
338 "Remove an existing Network Entity Title for this process\n"
339 "A Network Entity Title for this process (OSI only)\n"
340 "XX.XXXX. ... .XXX.XX Network entity title (NET)\n")
342 nb_cli_enqueue_change(vty
, "./area-address",
343 no
? NB_OP_DESTROY
: NB_OP_CREATE
, net
);
345 return nb_cli_apply_changes(vty
, NULL
);
348 void cli_show_isis_area_address(struct vty
*vty
, struct lyd_node
*dnode
,
351 vty_out(vty
, " net %s\n", yang_dnode_get_string(dnode
, NULL
));
355 * XPath: /frr-isisd:isis/instance/is-type
357 DEFPY(is_type
, is_type_cmd
, "is-type <level-1|level-1-2|level-2-only>$level",
358 "IS Level for this routing process (OSI only)\n"
359 "Act as a station router only\n"
360 "Act as both a station router and an area router\n"
361 "Act as an area router only\n")
363 nb_cli_enqueue_change(vty
, "./is-type", NB_OP_MODIFY
,
364 strmatch(level
, "level-2-only") ? "level-2"
367 return nb_cli_apply_changes(vty
, NULL
);
370 DEFPY(no_is_type
, no_is_type_cmd
,
371 "no is-type [<level-1|level-1-2|level-2-only>]",
373 "IS Level for this routing process (OSI only)\n"
374 "Act as a station router only\n"
375 "Act as both a station router and an area router\n"
376 "Act as an area router only\n")
380 pthread_rwlock_rdlock(&running_config
->lock
);
382 struct isis_area
*area
;
384 area
= nb_running_get_entry(NULL
, VTY_CURR_XPATH
, false);
387 * Put the is-type back to defaults:
388 * - level-1-2 on first area
389 * - level-1 for the rest
391 if (area
&& listgetdata(listhead(isis
->area_list
)) == area
)
396 pthread_rwlock_unlock(&running_config
->lock
);
398 nb_cli_enqueue_change(vty
, "./is-type", NB_OP_MODIFY
, value
);
400 return nb_cli_apply_changes(vty
, NULL
);
403 void cli_show_isis_is_type(struct vty
*vty
, struct lyd_node
*dnode
,
406 int is_type
= yang_dnode_get_enum(dnode
, NULL
);
410 vty_out(vty
, " is-type level-1\n");
413 vty_out(vty
, " is-type level-2-only\n");
415 case IS_LEVEL_1_AND_2
:
416 vty_out(vty
, " is-type level-1-2\n");
422 * XPath: /frr-isisd:isis/instance/dynamic-hostname
424 DEFPY(dynamic_hostname
, dynamic_hostname_cmd
, "[no] hostname dynamic",
426 "Dynamic hostname for IS-IS\n"
427 "Dynamic hostname\n")
429 nb_cli_enqueue_change(vty
, "./dynamic-hostname", NB_OP_MODIFY
,
430 no
? "false" : "true");
432 return nb_cli_apply_changes(vty
, NULL
);
435 void cli_show_isis_dynamic_hostname(struct vty
*vty
, struct lyd_node
*dnode
,
438 if (!yang_dnode_get_bool(dnode
, NULL
))
441 vty_out(vty
, " hostname dynamic\n");
445 * XPath: /frr-isisd:isis/instance/overload
447 DEFPY(set_overload_bit
, set_overload_bit_cmd
, "[no] set-overload-bit",
448 "Reset overload bit to accept transit traffic\n"
449 "Set overload bit to avoid any transit traffic\n")
451 nb_cli_enqueue_change(vty
, "./overload", NB_OP_MODIFY
,
452 no
? "false" : "true");
454 return nb_cli_apply_changes(vty
, NULL
);
457 void cli_show_isis_overload(struct vty
*vty
, struct lyd_node
*dnode
,
460 if (!yang_dnode_get_bool(dnode
, NULL
))
462 vty_out(vty
, " set-overload-bit\n");
466 * XPath: /frr-isisd:isis/instance/attached
468 DEFPY(set_attached_bit
, set_attached_bit_cmd
, "[no] set-attached-bit",
469 "Reset attached bit\n"
470 "Set attached bit to identify as L1/L2 router for inter-area traffic\n")
472 nb_cli_enqueue_change(vty
, "./attached", NB_OP_MODIFY
,
473 no
? "false" : "true");
475 return nb_cli_apply_changes(vty
, NULL
);
478 void cli_show_isis_attached(struct vty
*vty
, struct lyd_node
*dnode
,
481 if (!yang_dnode_get_bool(dnode
, NULL
))
483 vty_out(vty
, " set-attached-bit\n");
487 * XPath: /frr-isisd:isis/instance/metric-style
489 DEFPY(metric_style
, metric_style_cmd
,
490 "metric-style <narrow|transition|wide>$style",
491 "Use old-style (ISO 10589) or new-style packet formats\n"
492 "Use old style of TLVs with narrow metric\n"
493 "Send and accept both styles of TLVs during transition\n"
494 "Use new style of TLVs to carry wider metric\n")
496 nb_cli_enqueue_change(vty
, "./metric-style", NB_OP_MODIFY
, style
);
498 return nb_cli_apply_changes(vty
, NULL
);
501 DEFPY(no_metric_style
, no_metric_style_cmd
,
502 "no metric-style [narrow|transition|wide]",
504 "Use old-style (ISO 10589) or new-style packet formats\n"
505 "Use old style of TLVs with narrow metric\n"
506 "Send and accept both styles of TLVs during transition\n"
507 "Use new style of TLVs to carry wider metric\n")
509 nb_cli_enqueue_change(vty
, "./metric-style", NB_OP_MODIFY
, "narrow");
511 return nb_cli_apply_changes(vty
, NULL
);
514 void cli_show_isis_metric_style(struct vty
*vty
, struct lyd_node
*dnode
,
517 int metric
= yang_dnode_get_enum(dnode
, NULL
);
520 case ISIS_NARROW_METRIC
:
521 vty_out(vty
, " metric-style narrow\n");
523 case ISIS_WIDE_METRIC
:
524 vty_out(vty
, " metric-style wide\n");
526 case ISIS_TRANSITION_METRIC
:
527 vty_out(vty
, " metric-style transition\n");
533 * XPath: /frr-isisd:isis/instance/area-password
535 DEFPY(area_passwd
, area_passwd_cmd
,
536 "area-password <clear|md5>$pwd_type WORD$pwd [authenticate snp <send-only|validate>$snp]",
537 "Configure the authentication password for an area\n"
538 "Clear-text authentication type\n"
539 "MD5 authentication type\n"
540 "Level-wide password\n"
543 "Send but do not check PDUs on receiving\n"
544 "Send and check PDUs on receiving\n")
546 nb_cli_enqueue_change(vty
, "./area-password", NB_OP_CREATE
, NULL
);
547 nb_cli_enqueue_change(vty
, "./area-password/password", NB_OP_MODIFY
,
549 nb_cli_enqueue_change(vty
, "./area-password/password-type",
550 NB_OP_MODIFY
, pwd_type
);
551 nb_cli_enqueue_change(vty
, "./area-password/authenticate-snp",
552 NB_OP_MODIFY
, snp
? snp
: "none");
554 return nb_cli_apply_changes(vty
, NULL
);
557 void cli_show_isis_area_pwd(struct vty
*vty
, struct lyd_node
*dnode
,
562 vty_out(vty
, " area-password %s %s",
563 yang_dnode_get_string(dnode
, "./password-type"),
564 yang_dnode_get_string(dnode
, "./password"));
565 snp
= yang_dnode_get_string(dnode
, "./authenticate-snp");
566 if (!strmatch("none", snp
))
567 vty_out(vty
, " authenticate snp %s", snp
);
572 * XPath: /frr-isisd:isis/instance/domain-password
574 DEFPY(domain_passwd
, domain_passwd_cmd
,
575 "domain-password <clear|md5>$pwd_type WORD$pwd [authenticate snp <send-only|validate>$snp]",
576 "Set the authentication password for a routing domain\n"
577 "Clear-text authentication type\n"
578 "MD5 authentication type\n"
579 "Level-wide password\n"
582 "Send but do not check PDUs on receiving\n"
583 "Send and check PDUs on receiving\n")
585 nb_cli_enqueue_change(vty
, "./domain-password", NB_OP_CREATE
, NULL
);
586 nb_cli_enqueue_change(vty
, "./domain-password/password", NB_OP_MODIFY
,
588 nb_cli_enqueue_change(vty
, "./domain-password/password-type",
589 NB_OP_MODIFY
, pwd_type
);
590 nb_cli_enqueue_change(vty
, "./domain-password/authenticate-snp",
591 NB_OP_MODIFY
, snp
? snp
: "none");
593 return nb_cli_apply_changes(vty
, NULL
);
596 DEFPY(no_area_passwd
, no_area_passwd_cmd
,
597 "no <area-password|domain-password>$cmd",
599 "Configure the authentication password for an area\n"
600 "Set the authentication password for a routing domain\n")
602 nb_cli_enqueue_change(vty
, ".", NB_OP_DESTROY
, NULL
);
604 return nb_cli_apply_changes(vty
, "./%s", cmd
);
607 void cli_show_isis_domain_pwd(struct vty
*vty
, struct lyd_node
*dnode
,
612 vty_out(vty
, " domain-password %s %s",
613 yang_dnode_get_string(dnode
, "./password-type"),
614 yang_dnode_get_string(dnode
, "./password"));
615 snp
= yang_dnode_get_string(dnode
, "./authenticate-snp");
616 if (!strmatch("none", snp
))
617 vty_out(vty
, " authenticate snp %s", snp
);
622 * XPath: /frr-isisd:isis/instance/lsp/generation-interval
624 DEFPY(lsp_gen_interval
, lsp_gen_interval_cmd
,
625 "lsp-gen-interval [level-1|level-2]$level (1-120)$val",
626 "Minimum interval between regenerating same LSP\n"
627 "Set interval for level 1 only\n"
628 "Set interval for level 2 only\n"
629 "Minimum interval in seconds\n")
631 if (!level
|| strmatch(level
, "level-1"))
632 nb_cli_enqueue_change(vty
, "./lsp/generation-interval/level-1",
633 NB_OP_MODIFY
, val_str
);
634 if (!level
|| strmatch(level
, "level-2"))
635 nb_cli_enqueue_change(vty
, "./lsp/generation-interval/level-2",
636 NB_OP_MODIFY
, val_str
);
638 return nb_cli_apply_changes(vty
, NULL
);
641 DEFPY(no_lsp_gen_interval
, no_lsp_gen_interval_cmd
,
642 "no lsp-gen-interval [level-1|level-2]$level [(1-120)]",
644 "Minimum interval between regenerating same LSP\n"
645 "Set interval for level 1 only\n"
646 "Set interval for level 2 only\n"
647 "Minimum interval in seconds\n")
649 if (!level
|| strmatch(level
, "level-1"))
650 nb_cli_enqueue_change(vty
, "./lsp/generation-interval/level-1",
652 if (!level
|| strmatch(level
, "level-2"))
653 nb_cli_enqueue_change(vty
, "./lsp/generation-interval/level-2",
656 return nb_cli_apply_changes(vty
, NULL
);
659 void cli_show_isis_lsp_gen_interval(struct vty
*vty
, struct lyd_node
*dnode
,
662 const char *l1
= yang_dnode_get_string(dnode
, "./level-1");
663 const char *l2
= yang_dnode_get_string(dnode
, "./level-2");
665 if (strmatch(l1
, l2
))
666 vty_out(vty
, " lsp-gen-interval %s\n", l1
);
668 vty_out(vty
, " lsp-gen-interval level-1 %s\n", l1
);
669 vty_out(vty
, " lsp-gen-interval level-2 %s\n", l2
);
674 * XPath: /frr-isisd:isis/instance/lsp/refresh-interval
676 DEFPY(lsp_refresh_interval
, lsp_refresh_interval_cmd
,
677 "lsp-refresh-interval [level-1|level-2]$level (1-65235)$val",
678 "LSP refresh interval\n"
679 "LSP refresh interval for Level 1 only\n"
680 "LSP refresh interval for Level 2 only\n"
681 "LSP refresh interval in seconds\n")
683 if (!level
|| strmatch(level
, "level-1"))
684 nb_cli_enqueue_change(vty
, "./lsp/refresh-interval/level-1",
685 NB_OP_MODIFY
, val_str
);
686 if (!level
|| strmatch(level
, "level-2"))
687 nb_cli_enqueue_change(vty
, "./lsp/refresh-interval/level-2",
688 NB_OP_MODIFY
, val_str
);
690 return nb_cli_apply_changes(vty
, NULL
);
693 DEFPY(no_lsp_refresh_interval
, no_lsp_refresh_interval_cmd
,
694 "no lsp-refresh-interval [level-1|level-2]$level [(1-65235)]",
696 "LSP refresh interval\n"
697 "LSP refresh interval for Level 1 only\n"
698 "LSP refresh interval for Level 2 only\n"
699 "LSP refresh interval in seconds\n")
701 if (!level
|| strmatch(level
, "level-1"))
702 nb_cli_enqueue_change(vty
, "./lsp/refresh-interval/level-1",
704 if (!level
|| strmatch(level
, "level-2"))
705 nb_cli_enqueue_change(vty
, "./lsp/refresh-interval/level-2",
708 return nb_cli_apply_changes(vty
, NULL
);
711 void cli_show_isis_lsp_ref_interval(struct vty
*vty
, struct lyd_node
*dnode
,
714 const char *l1
= yang_dnode_get_string(dnode
, "./level-1");
715 const char *l2
= yang_dnode_get_string(dnode
, "./level-2");
717 if (strmatch(l1
, l2
))
718 vty_out(vty
, " lsp-refresh-interval %s\n", l1
);
720 vty_out(vty
, " lsp-refresh-interval level-1 %s\n", l1
);
721 vty_out(vty
, " lsp-refresh-interval level-2 %s\n", l2
);
726 * XPath: /frr-isisd:isis/instance/lsp/maximum-lifetime
728 DEFPY(max_lsp_lifetime
, max_lsp_lifetime_cmd
,
729 "max-lsp-lifetime [level-1|level-2]$level (350-65535)$val",
730 "Maximum LSP lifetime\n"
731 "Maximum LSP lifetime for Level 1 only\n"
732 "Maximum LSP lifetime for Level 2 only\n"
733 "LSP lifetime in seconds\n")
735 if (!level
|| strmatch(level
, "level-1"))
736 nb_cli_enqueue_change(vty
, "./lsp/maximum-lifetime/level-1",
737 NB_OP_MODIFY
, val_str
);
738 if (!level
|| strmatch(level
, "level-2"))
739 nb_cli_enqueue_change(vty
, "./lsp/maximum-lifetime/level-2",
740 NB_OP_MODIFY
, val_str
);
742 return nb_cli_apply_changes(vty
, NULL
);
745 DEFPY(no_max_lsp_lifetime
, no_max_lsp_lifetime_cmd
,
746 "no max-lsp-lifetime [level-1|level-2]$level [(350-65535)]",
748 "Maximum LSP lifetime\n"
749 "Maximum LSP lifetime for Level 1 only\n"
750 "Maximum LSP lifetime for Level 2 only\n"
751 "LSP lifetime in seconds\n")
753 if (!level
|| strmatch(level
, "level-1"))
754 nb_cli_enqueue_change(vty
, "./lsp/maximum-lifetime/level-1",
756 if (!level
|| strmatch(level
, "level-2"))
757 nb_cli_enqueue_change(vty
, "./lsp/maximum-lifetime/level-2",
760 return nb_cli_apply_changes(vty
, NULL
);
763 void cli_show_isis_lsp_max_lifetime(struct vty
*vty
, struct lyd_node
*dnode
,
766 const char *l1
= yang_dnode_get_string(dnode
, "./level-1");
767 const char *l2
= yang_dnode_get_string(dnode
, "./level-2");
769 if (strmatch(l1
, l2
))
770 vty_out(vty
, " max-lsp-lifetime %s\n", l1
);
772 vty_out(vty
, " max-lsp-lifetime level-1 %s\n", l1
);
773 vty_out(vty
, " max-lsp-lifetime level-2 %s\n", l2
);
778 * XPath: /frr-isisd:isis/instance/lsp/mtu
780 DEFPY(area_lsp_mtu
, area_lsp_mtu_cmd
, "lsp-mtu (128-4352)$val",
781 "Configure the maximum size of generated LSPs\n"
782 "Maximum size of generated LSPs\n")
784 nb_cli_enqueue_change(vty
, "./lsp/mtu", NB_OP_MODIFY
, val_str
);
786 return nb_cli_apply_changes(vty
, NULL
);
789 DEFPY(no_area_lsp_mtu
, no_area_lsp_mtu_cmd
, "no lsp-mtu [(128-4352)]",
791 "Configure the maximum size of generated LSPs\n"
792 "Maximum size of generated LSPs\n")
794 nb_cli_enqueue_change(vty
, "./lsp/mtu", NB_OP_MODIFY
, NULL
);
796 return nb_cli_apply_changes(vty
, NULL
);
799 void cli_show_isis_lsp_mtu(struct vty
*vty
, struct lyd_node
*dnode
,
802 vty_out(vty
, " lsp-mtu %s\n", yang_dnode_get_string(dnode
, NULL
));
806 * XPath: /frr-isisd:isis/instance/spf/minimum-interval
808 DEFPY(spf_interval
, spf_interval_cmd
,
809 "spf-interval [level-1|level-2]$level (1-120)$val",
810 "Minimum interval between SPF calculations\n"
811 "Set interval for level 1 only\n"
812 "Set interval for level 2 only\n"
813 "Minimum interval between consecutive SPFs in seconds\n")
815 if (!level
|| strmatch(level
, "level-1"))
816 nb_cli_enqueue_change(vty
, "./spf/minimum-interval/level-1",
817 NB_OP_MODIFY
, val_str
);
818 if (!level
|| strmatch(level
, "level-2"))
819 nb_cli_enqueue_change(vty
, "./spf/minimum-interval/level-2",
820 NB_OP_MODIFY
, val_str
);
822 return nb_cli_apply_changes(vty
, NULL
);
825 DEFPY(no_spf_interval
, no_spf_interval_cmd
,
826 "no spf-interval [level-1|level-2]$level [(1-120)]",
828 "Minimum interval between SPF calculations\n"
829 "Set interval for level 1 only\n"
830 "Set interval for level 2 only\n"
831 "Minimum interval between consecutive SPFs in seconds\n")
833 if (!level
|| strmatch(level
, "level-1"))
834 nb_cli_enqueue_change(vty
, "./spf/minimum-interval/level-1",
836 if (!level
|| strmatch(level
, "level-2"))
837 nb_cli_enqueue_change(vty
, "./spf/minimum-interval/level-2",
840 return nb_cli_apply_changes(vty
, NULL
);
843 void cli_show_isis_spf_min_interval(struct vty
*vty
, struct lyd_node
*dnode
,
846 const char *l1
= yang_dnode_get_string(dnode
, "./level-1");
847 const char *l2
= yang_dnode_get_string(dnode
, "./level-2");
849 if (strmatch(l1
, l2
))
850 vty_out(vty
, " spf-interval %s\n", l1
);
852 vty_out(vty
, " spf-interval level-1 %s\n", l1
);
853 vty_out(vty
, " spf-interval level-2 %s\n", l2
);
858 * XPath: /frr-isisd:isis/instance/spf/ietf-backoff-delay
860 DEFPY(spf_delay_ietf
, spf_delay_ietf_cmd
,
861 "spf-delay-ietf init-delay (0-60000) short-delay (0-60000) long-delay (0-60000) holddown (0-60000) time-to-learn (0-60000)",
862 "IETF SPF delay algorithm\n"
863 "Delay used while in QUIET state\n"
864 "Delay used while in QUIET state in milliseconds\n"
865 "Delay used while in SHORT_WAIT state\n"
866 "Delay used while in SHORT_WAIT state in milliseconds\n"
867 "Delay used while in LONG_WAIT\n"
868 "Delay used while in LONG_WAIT state in milliseconds\n"
869 "Time with no received IGP events before considering IGP stable\n"
870 "Time with no received IGP events before considering IGP stable (in milliseconds)\n"
871 "Maximum duration needed to learn all the events related to a single failure\n"
872 "Maximum duration needed to learn all the events related to a single failure (in milliseconds)\n")
874 nb_cli_enqueue_change(vty
, "./spf/ietf-backoff-delay", NB_OP_CREATE
,
876 nb_cli_enqueue_change(vty
, "./spf/ietf-backoff-delay/init-delay",
877 NB_OP_MODIFY
, init_delay_str
);
878 nb_cli_enqueue_change(vty
, "./spf/ietf-backoff-delay/short-delay",
879 NB_OP_MODIFY
, short_delay_str
);
880 nb_cli_enqueue_change(vty
, "./spf/ietf-backoff-delay/long-delay",
881 NB_OP_MODIFY
, long_delay_str
);
882 nb_cli_enqueue_change(vty
, "./spf/ietf-backoff-delay/hold-down",
883 NB_OP_MODIFY
, holddown_str
);
884 nb_cli_enqueue_change(vty
, "./spf/ietf-backoff-delay/time-to-learn",
885 NB_OP_MODIFY
, time_to_learn_str
);
887 return nb_cli_apply_changes(vty
, NULL
);
890 DEFPY(no_spf_delay_ietf
, no_spf_delay_ietf_cmd
,
891 "no spf-delay-ietf [init-delay (0-60000) short-delay (0-60000) long-delay (0-60000) holddown (0-60000) time-to-learn (0-60000)]",
893 "IETF SPF delay algorithm\n"
894 "Delay used while in QUIET state\n"
895 "Delay used while in QUIET state in milliseconds\n"
896 "Delay used while in SHORT_WAIT state\n"
897 "Delay used while in SHORT_WAIT state in milliseconds\n"
898 "Delay used while in LONG_WAIT\n"
899 "Delay used while in LONG_WAIT state in milliseconds\n"
900 "Time with no received IGP events before considering IGP stable\n"
901 "Time with no received IGP events before considering IGP stable (in milliseconds)\n"
902 "Maximum duration needed to learn all the events related to a single failure\n"
903 "Maximum duration needed to learn all the events related to a single failure (in milliseconds)\n")
905 nb_cli_enqueue_change(vty
, "./spf/ietf-backoff-delay", NB_OP_DESTROY
,
908 return nb_cli_apply_changes(vty
, NULL
);
911 void cli_show_isis_spf_ietf_backoff(struct vty
*vty
, struct lyd_node
*dnode
,
915 " spf-delay-ietf init-delay %s short-delay %s long-delay %s holddown %s time-to-learn %s\n",
916 yang_dnode_get_string(dnode
, "./init-delay"),
917 yang_dnode_get_string(dnode
, "./short-delay"),
918 yang_dnode_get_string(dnode
, "./long-delay"),
919 yang_dnode_get_string(dnode
, "./hold-down"),
920 yang_dnode_get_string(dnode
, "./time-to-learn"));
924 * XPath: /frr-isisd:isis/instance/purge-originator
926 DEFPY(area_purge_originator
, area_purge_originator_cmd
, "[no] purge-originator",
927 NO_STR
"Use the RFC 6232 purge-originator\n")
929 nb_cli_enqueue_change(vty
, "./purge-originator", NB_OP_MODIFY
,
930 no
? "false" : "true");
932 return nb_cli_apply_changes(vty
, NULL
);
935 void cli_show_isis_purge_origin(struct vty
*vty
, struct lyd_node
*dnode
,
938 if (!yang_dnode_get_bool(dnode
, NULL
))
940 vty_out(vty
, " purge-originator\n");
944 * XPath: /frr-isisd:isis/instance/mpls-te
946 DEFPY(isis_mpls_te_on
, isis_mpls_te_on_cmd
, "mpls-te on",
947 MPLS_TE_STR
"Enable the MPLS-TE functionality\n")
949 nb_cli_enqueue_change(vty
, "./mpls-te", NB_OP_CREATE
,
952 return nb_cli_apply_changes(vty
, NULL
);
955 DEFPY(no_isis_mpls_te_on
, no_isis_mpls_te_on_cmd
, "no mpls-te [on]",
957 "Disable the MPLS-TE functionality\n"
958 "Disable the MPLS-TE functionality\n")
960 nb_cli_enqueue_change(vty
, "./mpls-te", NB_OP_DESTROY
,
963 return nb_cli_apply_changes(vty
, NULL
);
966 void cli_show_isis_mpls_te(struct vty
*vty
, struct lyd_node
*dnode
,
969 vty_out(vty
, " mpls-te on\n");
973 * XPath: /frr-isisd:isis/instance/mpls-te/router-address
975 DEFPY(isis_mpls_te_router_addr
, isis_mpls_te_router_addr_cmd
,
976 "mpls-te router-address A.B.C.D",
978 "Stable IP address of the advertising router\n"
979 "MPLS-TE router address in IPv4 address format\n")
981 nb_cli_enqueue_change(vty
, "./mpls-te/router-address",
982 NB_OP_MODIFY
, router_address_str
);
984 return nb_cli_apply_changes(vty
, NULL
);
987 DEFPY(no_isis_mpls_te_router_addr
, no_isis_mpls_te_router_addr_cmd
,
988 "no mpls-te router-address [A.B.C.D]",
990 "Delete IP address of the advertising router\n"
991 "MPLS-TE router address in IPv4 address format\n")
993 nb_cli_enqueue_change(vty
, "./mpls-te/router-address",
994 NB_OP_DESTROY
, NULL
);
996 return nb_cli_apply_changes(vty
, NULL
);
999 void cli_show_isis_mpls_te_router_addr(struct vty
*vty
, struct lyd_node
*dnode
,
1002 vty_out(vty
, " mpls-te router-address %s\n",
1003 yang_dnode_get_string(dnode
, NULL
));
1006 DEFPY(isis_mpls_te_inter_as
, isis_mpls_te_inter_as_cmd
,
1007 "[no] mpls-te inter-as [level-1|level-1-2|level-2-only]",
1009 "Configure MPLS-TE Inter-AS support\n"
1010 "AREA native mode self originate INTER-AS LSP with L1 only flooding scope\n"
1011 "AREA native mode self originate INTER-AS LSP with L1 and L2 flooding scope\n"
1012 "AS native mode self originate INTER-AS LSP with L2 only flooding scope\n")
1014 vty_out(vty
, "MPLS-TE Inter-AS is not yet supported\n");
1019 * XPath: /frr-isisd:isis/instance/default-information-originate
1021 DEFPY(isis_default_originate
, isis_default_originate_cmd
,
1022 "[no] default-information originate <ipv4|ipv6>$ip"
1023 " <level-1|level-2>$level [always]$always"
1024 " [{metric (0-16777215)$metric|route-map WORD$rmap}]",
1026 "Control distribution of default information\n"
1027 "Distribute a default route\n"
1028 "Distribute default route for IPv4\n"
1029 "Distribute default route for IPv6\n"
1030 "Distribute default route into level-1\n"
1031 "Distribute default route into level-2\n"
1032 "Always advertise default route\n"
1033 "Metric for default route\n"
1034 "ISIS default metric\n"
1035 "Route map reference\n"
1036 "Pointer to route-map entries\n")
1039 nb_cli_enqueue_change(vty
, ".", NB_OP_DESTROY
, NULL
);
1041 nb_cli_enqueue_change(vty
, ".", NB_OP_CREATE
, NULL
);
1042 nb_cli_enqueue_change(vty
, "./always", NB_OP_MODIFY
,
1043 always
? "true" : "false");
1044 nb_cli_enqueue_change(vty
, "./route-map",
1045 rmap
? NB_OP_MODIFY
: NB_OP_DESTROY
,
1046 rmap
? rmap
: NULL
);
1047 nb_cli_enqueue_change(vty
, "./metric", NB_OP_MODIFY
,
1048 metric_str
? metric_str
: NULL
);
1049 if (strmatch(ip
, "ipv6") && !always
) {
1051 "Zebra doesn't implement default-originate for IPv6 yet\n");
1053 "so use with care or use default-originate always.\n");
1057 return nb_cli_apply_changes(
1058 vty
, "./default-information-originate/%s[level='%s']", ip
,
1062 static void vty_print_def_origin(struct vty
*vty
, struct lyd_node
*dnode
,
1063 const char *family
, const char *level
,
1066 vty_out(vty
, " default-information originate %s %s", family
, level
);
1067 if (yang_dnode_get_bool(dnode
, "./always"))
1068 vty_out(vty
, " always");
1070 if (yang_dnode_exists(dnode
, "./route-map"))
1071 vty_out(vty
, " route-map %s",
1072 yang_dnode_get_string(dnode
, "./route-map"));
1073 if (show_defaults
|| !yang_dnode_is_default(dnode
, "./metric"))
1074 vty_out(vty
, " metric %s",
1075 yang_dnode_get_string(dnode
, "./metric"));
1080 void cli_show_isis_def_origin_ipv4(struct vty
*vty
, struct lyd_node
*dnode
,
1083 const char *level
= yang_dnode_get_string(dnode
, "./level");
1085 vty_print_def_origin(vty
, dnode
, "ipv4", level
, show_defaults
);
1088 void cli_show_isis_def_origin_ipv6(struct vty
*vty
, struct lyd_node
*dnode
,
1091 const char *level
= yang_dnode_get_string(dnode
, "./level");
1093 vty_print_def_origin(vty
, dnode
, "ipv6", level
, show_defaults
);
1097 * XPath: /frr-isisd:isis/instance/redistribute
1099 DEFPY(isis_redistribute
, isis_redistribute_cmd
,
1100 "[no] redistribute <ipv4|ipv6>$ip " PROTO_REDIST_STR
1102 " <level-1|level-2>$level"
1103 " [{metric (0-16777215)|route-map WORD}]",
1105 "Redistribute IPv4 routes\n"
1106 "Redistribute IPv6 routes\n" PROTO_REDIST_HELP
1107 "Redistribute into level-1\n"
1108 "Redistribute into level-2\n"
1109 "Metric for redistributed routes\n"
1110 "ISIS default metric\n"
1111 "Route map reference\n"
1112 "Pointer to route-map entries\n")
1115 nb_cli_enqueue_change(vty
, ".", NB_OP_DESTROY
, NULL
);
1117 nb_cli_enqueue_change(vty
, ".", NB_OP_CREATE
, NULL
);
1118 nb_cli_enqueue_change(vty
, "./route-map",
1119 route_map
? NB_OP_MODIFY
: NB_OP_DESTROY
,
1120 route_map
? route_map
: NULL
);
1121 nb_cli_enqueue_change(vty
, "./metric", NB_OP_MODIFY
,
1122 metric_str
? metric_str
: NULL
);
1125 return nb_cli_apply_changes(
1126 vty
, "./redistribute/%s[protocol='%s'][level='%s']", ip
, proto
,
1130 static void vty_print_redistribute(struct vty
*vty
, struct lyd_node
*dnode
,
1131 bool show_defaults
, const char *family
)
1133 const char *level
= yang_dnode_get_string(dnode
, "./level");
1134 const char *protocol
= yang_dnode_get_string(dnode
, "./protocol");
1136 vty_out(vty
, " redistribute %s %s %s", family
, protocol
, level
);
1137 if (show_defaults
|| !yang_dnode_is_default(dnode
, "./metric"))
1138 vty_out(vty
, " metric %s",
1139 yang_dnode_get_string(dnode
, "./metric"));
1140 if (yang_dnode_exists(dnode
, "./route-map"))
1141 vty_out(vty
, " route-map %s",
1142 yang_dnode_get_string(dnode
, "./route-map"));
1146 void cli_show_isis_redistribute_ipv4(struct vty
*vty
, struct lyd_node
*dnode
,
1149 vty_print_redistribute(vty
, dnode
, show_defaults
, "ipv4");
1151 void cli_show_isis_redistribute_ipv6(struct vty
*vty
, struct lyd_node
*dnode
,
1154 vty_print_redistribute(vty
, dnode
, show_defaults
, "ipv6");
1158 * XPath: /frr-isisd:isis/instance/multi-topology
1160 DEFPY(isis_topology
, isis_topology_cmd
,
1168 "|ipv6-dstsrc>$topology "
1169 "[overload]$overload",
1171 "Configure IS-IS topologies\n"
1172 "IPv4 unicast topology\n"
1173 "IPv4 management topology\n"
1174 "IPv6 unicast topology\n"
1175 "IPv4 multicast topology\n"
1176 "IPv6 multicast topology\n"
1177 "IPv6 management topology\n"
1178 "IPv6 dst-src topology\n"
1179 "Set overload bit for topology\n")
1181 char base_xpath
[XPATH_MAXLEN
];
1183 /* Since IPv4-unicast is not configurable it is not present in the
1184 * YANG model, so we need to validate it here
1186 if (strmatch(topology
, "ipv4-unicast")) {
1187 vty_out(vty
, "Cannot configure IPv4 unicast topology\n");
1188 return CMD_WARNING_CONFIG_FAILED
;
1191 if (strmatch(topology
, "ipv4-mgmt"))
1192 snprintf(base_xpath
, XPATH_MAXLEN
,
1193 "./multi-topology/ipv4-management");
1194 else if (strmatch(topology
, "ipv6-mgmt"))
1195 snprintf(base_xpath
, XPATH_MAXLEN
,
1196 "./multi-topology/ipv6-management");
1198 snprintf(base_xpath
, XPATH_MAXLEN
, "./multi-topology/%s",
1202 nb_cli_enqueue_change(vty
, ".", NB_OP_DESTROY
, NULL
);
1204 nb_cli_enqueue_change(vty
, ".", NB_OP_CREATE
, NULL
);
1205 nb_cli_enqueue_change(vty
, "./overload", NB_OP_MODIFY
,
1206 overload
? "true" : "false");
1209 return nb_cli_apply_changes(vty
, base_xpath
);
1212 void cli_show_isis_mt_ipv4_multicast(struct vty
*vty
, struct lyd_node
*dnode
,
1215 vty_out(vty
, " topology ipv4-multicast");
1216 if (yang_dnode_get_bool(dnode
, "./overload"))
1217 vty_out(vty
, " overload");
1221 void cli_show_isis_mt_ipv4_mgmt(struct vty
*vty
, struct lyd_node
*dnode
,
1224 vty_out(vty
, " topology ipv4-mgmt");
1225 if (yang_dnode_get_bool(dnode
, "./overload"))
1226 vty_out(vty
, " overload");
1230 void cli_show_isis_mt_ipv6_unicast(struct vty
*vty
, struct lyd_node
*dnode
,
1233 vty_out(vty
, " topology ipv6-unicast");
1234 if (yang_dnode_get_bool(dnode
, "./overload"))
1235 vty_out(vty
, " overload");
1239 void cli_show_isis_mt_ipv6_multicast(struct vty
*vty
, struct lyd_node
*dnode
,
1242 vty_out(vty
, " topology ipv6-multicast");
1243 if (yang_dnode_get_bool(dnode
, "./overload"))
1244 vty_out(vty
, " overload");
1248 void cli_show_isis_mt_ipv6_mgmt(struct vty
*vty
, struct lyd_node
*dnode
,
1251 vty_out(vty
, " topology ipv6-mgmt");
1252 if (yang_dnode_get_bool(dnode
, "./overload"))
1253 vty_out(vty
, " overload");
1257 void cli_show_isis_mt_ipv6_dstsrc(struct vty
*vty
, struct lyd_node
*dnode
,
1260 vty_out(vty
, " topology ipv6-dstsrc");
1261 if (yang_dnode_get_bool(dnode
, "./overload"))
1262 vty_out(vty
, " overload");
1267 * XPath: /frr-interface:lib/interface/frr-isisd:isis/passive
1269 DEFPY(isis_passive
, isis_passive_cmd
, "[no] isis passive",
1271 "IS-IS routing protocol\n"
1272 "Configure the passive mode for interface\n")
1274 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/passive", NB_OP_MODIFY
,
1275 no
? "false" : "true");
1277 return nb_cli_apply_changes(vty
, NULL
);
1280 void cli_show_ip_isis_passive(struct vty
*vty
, struct lyd_node
*dnode
,
1283 if (!yang_dnode_get_bool(dnode
, NULL
))
1284 vty_out(vty
, " no");
1285 vty_out(vty
, " isis passive\n");
1289 * XPath: /frr-interface:lib/interface/frr-isisd:isis/password
1292 DEFPY(isis_passwd
, isis_passwd_cmd
, "isis password <md5|clear>$type WORD$pwd",
1293 "IS-IS routing protocol\n"
1294 "Configure the authentication password for a circuit\n"
1295 "HMAC-MD5 authentication\n"
1296 "Cleartext password\n"
1297 "Circuit password\n")
1299 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/password", NB_OP_CREATE
,
1301 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/password/password",
1303 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/password/password-type",
1304 NB_OP_MODIFY
, type
);
1306 return nb_cli_apply_changes(vty
, NULL
);
1309 DEFPY(no_isis_passwd
, no_isis_passwd_cmd
, "no isis password [<md5|clear> WORD]",
1311 "IS-IS routing protocol\n"
1312 "Configure the authentication password for a circuit\n"
1313 "HMAC-MD5 authentication\n"
1314 "Cleartext password\n"
1315 "Circuit password\n")
1317 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/password", NB_OP_DESTROY
,
1320 return nb_cli_apply_changes(vty
, NULL
);
1323 void cli_show_ip_isis_password(struct vty
*vty
, struct lyd_node
*dnode
,
1326 vty_out(vty
, " isis password %s %s\n",
1327 yang_dnode_get_string(dnode
, "./password-type"),
1328 yang_dnode_get_string(dnode
, "./password"));
1332 * XPath: /frr-interface:lib/interface/frr-isisd:isis/metric
1334 DEFPY(isis_metric
, isis_metric_cmd
,
1335 "isis metric [level-1|level-2]$level (0-16777215)$met",
1336 "IS-IS routing protocol\n"
1337 "Set default metric for circuit\n"
1338 "Specify metric for level-1 routing\n"
1339 "Specify metric for level-2 routing\n"
1340 "Default metric value\n")
1342 if (!level
|| strmatch(level
, "level-1"))
1343 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/metric/level-1",
1344 NB_OP_MODIFY
, met_str
);
1345 if (!level
|| strmatch(level
, "level-2"))
1346 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/metric/level-2",
1347 NB_OP_MODIFY
, met_str
);
1349 return nb_cli_apply_changes(vty
, NULL
);
1352 DEFPY(no_isis_metric
, no_isis_metric_cmd
,
1353 "no isis metric [level-1|level-2]$level [(0-16777215)]",
1355 "IS-IS routing protocol\n"
1356 "Set default metric for circuit\n"
1357 "Specify metric for level-1 routing\n"
1358 "Specify metric for level-2 routing\n"
1359 "Default metric value\n")
1361 if (!level
|| strmatch(level
, "level-1"))
1362 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/metric/level-1",
1363 NB_OP_MODIFY
, NULL
);
1364 if (!level
|| strmatch(level
, "level-2"))
1365 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/metric/level-2",
1366 NB_OP_MODIFY
, NULL
);
1368 return nb_cli_apply_changes(vty
, NULL
);
1371 void cli_show_ip_isis_metric(struct vty
*vty
, struct lyd_node
*dnode
,
1374 const char *l1
= yang_dnode_get_string(dnode
, "./level-1");
1375 const char *l2
= yang_dnode_get_string(dnode
, "./level-2");
1377 if (strmatch(l1
, l2
))
1378 vty_out(vty
, " isis metric %s\n", l1
);
1380 vty_out(vty
, " isis metric %s level-1\n", l1
);
1381 vty_out(vty
, " isis metric %s level-2\n", l2
);
1386 * XPath: /frr-interface:lib/interface/frr-isisd:isis/hello/interval
1388 DEFPY(isis_hello_interval
, isis_hello_interval_cmd
,
1389 "isis hello-interval [level-1|level-2]$level (1-600)$intv",
1390 "IS-IS routing protocol\n"
1391 "Set Hello interval\n"
1392 "Specify hello-interval for level-1 IIHs\n"
1393 "Specify hello-interval for level-2 IIHs\n"
1394 "Holdtime 1 seconds, interval depends on multiplier\n")
1396 if (!level
|| strmatch(level
, "level-1"))
1397 nb_cli_enqueue_change(vty
,
1398 "./frr-isisd:isis/hello/interval/level-1",
1399 NB_OP_MODIFY
, intv_str
);
1400 if (!level
|| strmatch(level
, "level-2"))
1401 nb_cli_enqueue_change(vty
,
1402 "./frr-isisd:isis/hello/interval/level-2",
1403 NB_OP_MODIFY
, intv_str
);
1405 return nb_cli_apply_changes(vty
, NULL
);
1408 DEFPY(no_isis_hello_interval
, no_isis_hello_interval_cmd
,
1409 "no isis hello-interval [level-1|level-2]$level [(1-600)]",
1411 "IS-IS routing protocol\n"
1412 "Set Hello interval\n"
1413 "Specify hello-interval for level-1 IIHs\n"
1414 "Specify hello-interval for level-2 IIHs\n"
1415 "Holdtime 1 second, interval depends on multiplier\n")
1417 if (!level
|| strmatch(level
, "level-1"))
1418 nb_cli_enqueue_change(vty
,
1419 "./frr-isisd:isis/hello/interval/level-1",
1420 NB_OP_MODIFY
, NULL
);
1421 if (!level
|| strmatch(level
, "level-2"))
1422 nb_cli_enqueue_change(vty
,
1423 "./frr-isisd:isis/hello/interval/level-2",
1424 NB_OP_MODIFY
, NULL
);
1426 return nb_cli_apply_changes(vty
, NULL
);
1429 void cli_show_ip_isis_hello_interval(struct vty
*vty
, struct lyd_node
*dnode
,
1432 const char *l1
= yang_dnode_get_string(dnode
, "./level-1");
1433 const char *l2
= yang_dnode_get_string(dnode
, "./level-2");
1435 if (strmatch(l1
, l2
))
1436 vty_out(vty
, " isis hello-interval %s\n", l1
);
1438 vty_out(vty
, " isis hello-interval %s level-1\n", l1
);
1439 vty_out(vty
, " isis hello-interval %s level-2\n", l2
);
1444 * XPath: /frr-interface:lib/interface/frr-isisd:isis/hello/multiplier
1446 DEFPY(isis_hello_multiplier
, isis_hello_multiplier_cmd
,
1447 "isis hello-multiplier [level-1|level-2]$level (2-100)$mult",
1448 "IS-IS routing protocol\n"
1449 "Set multiplier for Hello holding time\n"
1450 "Specify hello multiplier for level-1 IIHs\n"
1451 "Specify hello multiplier for level-2 IIHs\n"
1452 "Hello multiplier value\n")
1454 if (!level
|| strmatch(level
, "level-1"))
1455 nb_cli_enqueue_change(
1456 vty
, "./frr-isisd:isis/hello/multiplier/level-1",
1457 NB_OP_MODIFY
, mult_str
);
1458 if (!level
|| strmatch(level
, "level-2"))
1459 nb_cli_enqueue_change(
1460 vty
, "./frr-isisd:isis/hello/multiplier/level-2",
1461 NB_OP_MODIFY
, mult_str
);
1463 return nb_cli_apply_changes(vty
, NULL
);
1466 DEFPY(no_isis_hello_multiplier
, no_isis_hello_multiplier_cmd
,
1467 "no isis hello-multiplier [level-1|level-2]$level [(2-100)]",
1469 "IS-IS routing protocol\n"
1470 "Set multiplier for Hello holding time\n"
1471 "Specify hello multiplier for level-1 IIHs\n"
1472 "Specify hello multiplier for level-2 IIHs\n"
1473 "Hello multiplier value\n")
1475 if (!level
|| strmatch(level
, "level-1"))
1476 nb_cli_enqueue_change(
1477 vty
, "./frr-isisd:isis/hello/multiplier/level-1",
1478 NB_OP_MODIFY
, NULL
);
1479 if (!level
|| strmatch(level
, "level-2"))
1480 nb_cli_enqueue_change(
1481 vty
, "./frr-isisd:isis/hello/multiplier/level-2",
1482 NB_OP_MODIFY
, NULL
);
1484 return nb_cli_apply_changes(vty
, NULL
);
1487 void cli_show_ip_isis_hello_multi(struct vty
*vty
, struct lyd_node
*dnode
,
1490 const char *l1
= yang_dnode_get_string(dnode
, "./level-1");
1491 const char *l2
= yang_dnode_get_string(dnode
, "./level-2");
1493 if (strmatch(l1
, l2
))
1494 vty_out(vty
, " isis hello-multiplier %s\n", l1
);
1496 vty_out(vty
, " isis hello-multiplier %s level-1\n", l1
);
1497 vty_out(vty
, " isis hello-multiplier %s level-2\n", l2
);
1503 * /frr-interface:lib/interface/frr-isisd:isis/disable-three-way-handshake
1505 DEFPY(isis_threeway_adj
, isis_threeway_adj_cmd
, "[no] isis three-way-handshake",
1508 "Enable/Disable three-way handshake\n")
1510 nb_cli_enqueue_change(vty
,
1511 "./frr-isisd:isis/disable-three-way-handshake",
1512 NB_OP_MODIFY
, no
? "true" : "false");
1514 return nb_cli_apply_changes(vty
, NULL
);
1517 void cli_show_ip_isis_threeway_shake(struct vty
*vty
, struct lyd_node
*dnode
,
1520 if (yang_dnode_get_bool(dnode
, NULL
))
1521 vty_out(vty
, " no");
1522 vty_out(vty
, " isis three-way-handshake\n");
1526 * XPath: /frr-interface:lib/interface/frr-isisd:isis/hello/padding
1528 DEFPY(isis_hello_padding
, isis_hello_padding_cmd
, "[no] isis hello padding",
1530 "IS-IS routing protocol\n"
1531 "Add padding to IS-IS hello packets\n"
1532 "Pad hello packets\n")
1534 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/hello/padding",
1535 NB_OP_MODIFY
, no
? "false" : "true");
1537 return nb_cli_apply_changes(vty
, NULL
);
1540 void cli_show_ip_isis_hello_padding(struct vty
*vty
, struct lyd_node
*dnode
,
1543 if (!yang_dnode_get_bool(dnode
, NULL
))
1544 vty_out(vty
, " no");
1546 vty_out(vty
, " isis hello padding\n");
1550 * XPath: /frr-interface:lib/interface/frr-isisd:isis/csnp-interval
1552 DEFPY(csnp_interval
, csnp_interval_cmd
,
1553 "isis csnp-interval (1-600)$intv [level-1|level-2]$level",
1554 "IS-IS routing protocol\n"
1555 "Set CSNP interval in seconds\n"
1556 "CSNP interval value\n"
1557 "Specify interval for level-1 CSNPs\n"
1558 "Specify interval for level-2 CSNPs\n")
1560 if (!level
|| strmatch(level
, "level-1"))
1561 nb_cli_enqueue_change(vty
,
1562 "./frr-isisd:isis/csnp-interval/level-1",
1563 NB_OP_MODIFY
, intv_str
);
1564 if (!level
|| strmatch(level
, "level-2"))
1565 nb_cli_enqueue_change(vty
,
1566 "./frr-isisd:isis/csnp-interval/level-2",
1567 NB_OP_MODIFY
, intv_str
);
1569 return nb_cli_apply_changes(vty
, NULL
);
1572 DEFPY(no_csnp_interval
, no_csnp_interval_cmd
,
1573 "no isis csnp-interval [(1-600)] [level-1|level-2]$level",
1575 "IS-IS routing protocol\n"
1576 "Set CSNP interval in seconds\n"
1577 "CSNP interval value\n"
1578 "Specify interval for level-1 CSNPs\n"
1579 "Specify interval for level-2 CSNPs\n")
1581 if (!level
|| strmatch(level
, "level-1"))
1582 nb_cli_enqueue_change(vty
,
1583 "./frr-isisd:isis/csnp-interval/level-1",
1584 NB_OP_MODIFY
, NULL
);
1585 if (!level
|| strmatch(level
, "level-2"))
1586 nb_cli_enqueue_change(vty
,
1587 "./frr-isisd:isis/csnp-interval/level-2",
1588 NB_OP_MODIFY
, NULL
);
1590 return nb_cli_apply_changes(vty
, NULL
);
1593 void cli_show_ip_isis_csnp_interval(struct vty
*vty
, struct lyd_node
*dnode
,
1596 const char *l1
= yang_dnode_get_string(dnode
, "./level-1");
1597 const char *l2
= yang_dnode_get_string(dnode
, "./level-2");
1599 if (strmatch(l1
, l2
))
1600 vty_out(vty
, " isis csnp-interval %s\n", l1
);
1602 vty_out(vty
, " isis csnp-interval %s level-1\n", l1
);
1603 vty_out(vty
, " isis csnp-interval %s level-2\n", l2
);
1608 * XPath: /frr-interface:lib/interface/frr-isisd:isis/psnp-interval
1610 DEFPY(psnp_interval
, psnp_interval_cmd
,
1611 "isis psnp-interval (1-120)$intv [level-1|level-2]$level",
1612 "IS-IS routing protocol\n"
1613 "Set PSNP interval in seconds\n"
1614 "PSNP interval value\n"
1615 "Specify interval for level-1 PSNPs\n"
1616 "Specify interval for level-2 PSNPs\n")
1618 if (!level
|| strmatch(level
, "level-1"))
1619 nb_cli_enqueue_change(vty
,
1620 "./frr-isisd:isis/psnp-interval/level-1",
1621 NB_OP_MODIFY
, intv_str
);
1622 if (!level
|| strmatch(level
, "level-2"))
1623 nb_cli_enqueue_change(vty
,
1624 "./frr-isisd:isis/psnp-interval/level-2",
1625 NB_OP_MODIFY
, intv_str
);
1627 return nb_cli_apply_changes(vty
, NULL
);
1630 DEFPY(no_psnp_interval
, no_psnp_interval_cmd
,
1631 "no isis psnp-interval [(1-120)] [level-1|level-2]$level",
1633 "IS-IS routing protocol\n"
1634 "Set PSNP interval in seconds\n"
1635 "PSNP interval value\n"
1636 "Specify interval for level-1 PSNPs\n"
1637 "Specify interval for level-2 PSNPs\n")
1639 if (!level
|| strmatch(level
, "level-1"))
1640 nb_cli_enqueue_change(vty
,
1641 "./frr-isisd:isis/psnp-interval/level-1",
1642 NB_OP_MODIFY
, NULL
);
1643 if (!level
|| strmatch(level
, "level-2"))
1644 nb_cli_enqueue_change(vty
,
1645 "./frr-isisd:isis/psnp-interval/level-2",
1646 NB_OP_MODIFY
, NULL
);
1648 return nb_cli_apply_changes(vty
, NULL
);
1651 void cli_show_ip_isis_psnp_interval(struct vty
*vty
, struct lyd_node
*dnode
,
1654 const char *l1
= yang_dnode_get_string(dnode
, "./level-1");
1655 const char *l2
= yang_dnode_get_string(dnode
, "./level-2");
1657 if (strmatch(l1
, l2
))
1658 vty_out(vty
, " isis psnp-interval %s\n", l1
);
1660 vty_out(vty
, " isis psnp-interval %s level-1\n", l1
);
1661 vty_out(vty
, " isis psnp-interval %s level-2\n", l2
);
1666 * XPath: /frr-interface:lib/interface/frr-isisd:isis/multi-topology
1668 DEFPY(circuit_topology
, circuit_topology_cmd
,
1669 "[no] isis topology"
1679 "IS-IS routing protocol\n"
1680 "Configure interface IS-IS topologies\n"
1681 "IPv4 unicast topology\n"
1682 "IPv4 management topology\n"
1683 "IPv6 unicast topology\n"
1684 "IPv4 multicast topology\n"
1685 "IPv6 multicast topology\n"
1686 "IPv6 management topology\n"
1687 "IPv6 dst-src topology\n")
1689 nb_cli_enqueue_change(vty
, ".", NB_OP_MODIFY
, no
? "false" : "true");
1691 if (strmatch(topology
, "ipv4-mgmt"))
1692 return nb_cli_apply_changes(
1693 vty
, "./frr-isisd:isis/multi-topology/ipv4-management");
1694 else if (strmatch(topology
, "ipv6-mgmt"))
1695 return nb_cli_apply_changes(
1696 vty
, "./frr-isisd:isis/multi-topology/ipv6-management");
1698 return nb_cli_apply_changes(
1699 vty
, "./frr-isisd:isis/multi-topology/%s", topology
);
1702 void cli_show_ip_isis_mt_ipv4_unicast(struct vty
*vty
, struct lyd_node
*dnode
,
1705 if (!yang_dnode_get_bool(dnode
, NULL
))
1706 vty_out(vty
, " no");
1707 vty_out(vty
, " isis topology ipv4-unicast\n");
1710 void cli_show_ip_isis_mt_ipv4_multicast(struct vty
*vty
, struct lyd_node
*dnode
,
1713 if (!yang_dnode_get_bool(dnode
, NULL
))
1714 vty_out(vty
, " no");
1715 vty_out(vty
, " isis topology ipv4-multicast\n");
1718 void cli_show_ip_isis_mt_ipv4_mgmt(struct vty
*vty
, struct lyd_node
*dnode
,
1721 if (!yang_dnode_get_bool(dnode
, NULL
))
1722 vty_out(vty
, " no");
1723 vty_out(vty
, " isis topology ipv4-mgmt\n");
1726 void cli_show_ip_isis_mt_ipv6_unicast(struct vty
*vty
, struct lyd_node
*dnode
,
1729 if (!yang_dnode_get_bool(dnode
, NULL
))
1730 vty_out(vty
, " no");
1731 vty_out(vty
, " isis topology ipv6-unicast\n");
1734 void cli_show_ip_isis_mt_ipv6_multicast(struct vty
*vty
, struct lyd_node
*dnode
,
1737 if (!yang_dnode_get_bool(dnode
, NULL
))
1738 vty_out(vty
, " no");
1739 vty_out(vty
, " isis topology ipv6-multicast\n");
1742 void cli_show_ip_isis_mt_ipv6_mgmt(struct vty
*vty
, struct lyd_node
*dnode
,
1745 if (!yang_dnode_get_bool(dnode
, NULL
))
1746 vty_out(vty
, " no");
1747 vty_out(vty
, " isis topology ipv6-mgmt\n");
1750 void cli_show_ip_isis_mt_ipv6_dstsrc(struct vty
*vty
, struct lyd_node
*dnode
,
1753 if (!yang_dnode_get_bool(dnode
, NULL
))
1754 vty_out(vty
, " no");
1755 vty_out(vty
, " isis topology ipv6-dstsrc\n");
1759 * XPath: /frr-interface:lib/interface/frr-isisd:isis/circuit-type
1761 DEFPY(isis_circuit_type
, isis_circuit_type_cmd
,
1762 "isis circuit-type <level-1|level-1-2|level-2-only>$type",
1763 "IS-IS routing protocol\n"
1764 "Configure circuit type for interface\n"
1765 "Level-1 only adjacencies are formed\n"
1766 "Level-1-2 adjacencies are formed\n"
1767 "Level-2 only adjacencies are formed\n")
1769 nb_cli_enqueue_change(
1770 vty
, "./frr-isisd:isis/circuit-type", NB_OP_MODIFY
,
1771 strmatch(type
, "level-2-only") ? "level-2" : type
);
1773 return nb_cli_apply_changes(vty
, NULL
);
1776 DEFPY(no_isis_circuit_type
, no_isis_circuit_type_cmd
,
1777 "no isis circuit-type [level-1|level-1-2|level-2-only]",
1779 "IS-IS routing protocol\n"
1780 "Configure circuit type for interface\n"
1781 "Level-1 only adjacencies are formed\n"
1782 "Level-1-2 adjacencies are formed\n"
1783 "Level-2 only adjacencies are formed\n")
1785 const char *circ_type
= NULL
;
1788 * Default value depends on whether the circuit is part of an area,
1789 * and the is-type of the area if there is one. So we need to do this
1792 pthread_rwlock_rdlock(&running_config
->lock
);
1794 struct interface
*ifp
;
1795 struct isis_circuit
*circuit
;
1797 ifp
= nb_running_get_entry(NULL
, VTY_CURR_XPATH
, false);
1801 circuit
= circuit_scan_by_ifp(ifp
);
1802 if (!circuit
|| circuit
->state
!= C_STATE_UP
)
1805 switch (circuit
->area
->is_type
) {
1807 circ_type
= "level-1";
1810 circ_type
= "level-2";
1812 case IS_LEVEL_1_AND_2
:
1813 circ_type
= "level-1-2";
1818 pthread_rwlock_unlock(&running_config
->lock
);
1820 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/circuit-type",
1821 NB_OP_MODIFY
, circ_type
);
1823 return nb_cli_apply_changes(vty
, NULL
);
1826 void cli_show_ip_isis_circ_type(struct vty
*vty
, struct lyd_node
*dnode
,
1829 int level
= yang_dnode_get_enum(dnode
, NULL
);
1833 vty_out(vty
, " isis circuit-type level-1\n");
1836 vty_out(vty
, " isis circuit-type level-2-only\n");
1838 case IS_LEVEL_1_AND_2
:
1839 vty_out(vty
, " isis circuit-type level-1-2\n");
1845 * XPath: /frr-interface:lib/interface/frr-isisd:isis/network-type
1847 DEFPY(isis_network
, isis_network_cmd
, "[no] isis network point-to-point",
1849 "IS-IS routing protocol\n"
1850 "Set network type\n"
1851 "point-to-point network type\n")
1853 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/network-type",
1855 no
? "broadcast" : "point-to-point");
1857 return nb_cli_apply_changes(vty
, NULL
);
1860 void cli_show_ip_isis_network_type(struct vty
*vty
, struct lyd_node
*dnode
,
1863 if (yang_dnode_get_enum(dnode
, NULL
) != CIRCUIT_T_P2P
)
1864 vty_out(vty
, " no");
1866 vty_out(vty
, " isis network point-to-point\n");
1870 * XPath: /frr-interface:lib/interface/frr-isisd:isis/priority
1872 DEFPY(isis_priority
, isis_priority_cmd
,
1873 "isis priority (0-127)$prio [level-1|level-2]$level",
1874 "IS-IS routing protocol\n"
1875 "Set priority for Designated Router election\n"
1877 "Specify priority for level-1 routing\n"
1878 "Specify priority for level-2 routing\n")
1880 if (!level
|| strmatch(level
, "level-1"))
1881 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/priority/level-1",
1882 NB_OP_MODIFY
, prio_str
);
1883 if (!level
|| strmatch(level
, "level-2"))
1884 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/priority/level-2",
1885 NB_OP_MODIFY
, prio_str
);
1887 return nb_cli_apply_changes(vty
, NULL
);
1890 DEFPY(no_isis_priority
, no_isis_priority_cmd
,
1891 "no isis priority [(0-127)] [level-1|level-2]$level",
1893 "IS-IS routing protocol\n"
1894 "Set priority for Designated Router election\n"
1896 "Specify priority for level-1 routing\n"
1897 "Specify priority for level-2 routing\n")
1899 if (!level
|| strmatch(level
, "level-1"))
1900 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/priority/level-1",
1901 NB_OP_MODIFY
, NULL
);
1902 if (!level
|| strmatch(level
, "level-2"))
1903 nb_cli_enqueue_change(vty
, "./frr-isisd:isis/priority/level-2",
1904 NB_OP_MODIFY
, NULL
);
1906 return nb_cli_apply_changes(vty
, NULL
);
1909 void cli_show_ip_isis_priority(struct vty
*vty
, struct lyd_node
*dnode
,
1912 const char *l1
= yang_dnode_get_string(dnode
, "./level-1");
1913 const char *l2
= yang_dnode_get_string(dnode
, "./level-2");
1915 if (strmatch(l1
, l2
))
1916 vty_out(vty
, " isis priority %s\n", l1
);
1918 vty_out(vty
, " isis priority %s level-1\n", l1
);
1919 vty_out(vty
, " isis priority %s level-2\n", l2
);
1924 * XPath: /frr-isisd:isis/instance/log-adjacency-changes
1926 DEFPY(log_adj_changes
, log_adj_changes_cmd
, "[no] log-adjacency-changes",
1927 NO_STR
"Log changes in adjacency state\n")
1929 nb_cli_enqueue_change(vty
, "./log-adjacency-changes", NB_OP_MODIFY
,
1930 no
? "false" : "true");
1932 return nb_cli_apply_changes(vty
, NULL
);
1935 void cli_show_isis_log_adjacency(struct vty
*vty
, struct lyd_node
*dnode
,
1938 if (!yang_dnode_get_bool(dnode
, NULL
))
1939 vty_out(vty
, " no");
1940 vty_out(vty
, " log-adjacency-changes\n");
1943 void isis_cli_init(void)
1945 install_element(CONFIG_NODE
, &router_isis_cmd
);
1946 install_element(CONFIG_NODE
, &no_router_isis_cmd
);
1948 install_element(INTERFACE_NODE
, &ip_router_isis_cmd
);
1949 install_element(INTERFACE_NODE
, &ip6_router_isis_cmd
);
1950 install_element(INTERFACE_NODE
, &no_ip_router_isis_cmd
);
1952 install_element(ISIS_NODE
, &net_cmd
);
1954 install_element(ISIS_NODE
, &is_type_cmd
);
1955 install_element(ISIS_NODE
, &no_is_type_cmd
);
1957 install_element(ISIS_NODE
, &dynamic_hostname_cmd
);
1959 install_element(ISIS_NODE
, &set_overload_bit_cmd
);
1960 install_element(ISIS_NODE
, &set_attached_bit_cmd
);
1962 install_element(ISIS_NODE
, &metric_style_cmd
);
1963 install_element(ISIS_NODE
, &no_metric_style_cmd
);
1965 install_element(ISIS_NODE
, &area_passwd_cmd
);
1966 install_element(ISIS_NODE
, &domain_passwd_cmd
);
1967 install_element(ISIS_NODE
, &no_area_passwd_cmd
);
1969 install_element(ISIS_NODE
, &lsp_gen_interval_cmd
);
1970 install_element(ISIS_NODE
, &no_lsp_gen_interval_cmd
);
1971 install_element(ISIS_NODE
, &lsp_refresh_interval_cmd
);
1972 install_element(ISIS_NODE
, &no_lsp_refresh_interval_cmd
);
1973 install_element(ISIS_NODE
, &max_lsp_lifetime_cmd
);
1974 install_element(ISIS_NODE
, &no_max_lsp_lifetime_cmd
);
1975 install_element(ISIS_NODE
, &area_lsp_mtu_cmd
);
1976 install_element(ISIS_NODE
, &no_area_lsp_mtu_cmd
);
1978 install_element(ISIS_NODE
, &spf_interval_cmd
);
1979 install_element(ISIS_NODE
, &no_spf_interval_cmd
);
1980 install_element(ISIS_NODE
, &spf_delay_ietf_cmd
);
1981 install_element(ISIS_NODE
, &no_spf_delay_ietf_cmd
);
1983 install_element(ISIS_NODE
, &area_purge_originator_cmd
);
1985 install_element(ISIS_NODE
, &isis_mpls_te_on_cmd
);
1986 install_element(ISIS_NODE
, &no_isis_mpls_te_on_cmd
);
1987 install_element(ISIS_NODE
, &isis_mpls_te_router_addr_cmd
);
1988 install_element(ISIS_NODE
, &no_isis_mpls_te_router_addr_cmd
);
1989 install_element(ISIS_NODE
, &isis_mpls_te_inter_as_cmd
);
1991 install_element(ISIS_NODE
, &isis_default_originate_cmd
);
1992 install_element(ISIS_NODE
, &isis_redistribute_cmd
);
1994 install_element(ISIS_NODE
, &isis_topology_cmd
);
1996 install_element(INTERFACE_NODE
, &isis_passive_cmd
);
1998 install_element(INTERFACE_NODE
, &isis_passwd_cmd
);
1999 install_element(INTERFACE_NODE
, &no_isis_passwd_cmd
);
2001 install_element(INTERFACE_NODE
, &isis_metric_cmd
);
2002 install_element(INTERFACE_NODE
, &no_isis_metric_cmd
);
2004 install_element(INTERFACE_NODE
, &isis_hello_interval_cmd
);
2005 install_element(INTERFACE_NODE
, &no_isis_hello_interval_cmd
);
2007 install_element(INTERFACE_NODE
, &isis_hello_multiplier_cmd
);
2008 install_element(INTERFACE_NODE
, &no_isis_hello_multiplier_cmd
);
2010 install_element(INTERFACE_NODE
, &isis_threeway_adj_cmd
);
2012 install_element(INTERFACE_NODE
, &isis_hello_padding_cmd
);
2014 install_element(INTERFACE_NODE
, &csnp_interval_cmd
);
2015 install_element(INTERFACE_NODE
, &no_csnp_interval_cmd
);
2017 install_element(INTERFACE_NODE
, &psnp_interval_cmd
);
2018 install_element(INTERFACE_NODE
, &no_psnp_interval_cmd
);
2020 install_element(INTERFACE_NODE
, &circuit_topology_cmd
);
2022 install_element(INTERFACE_NODE
, &isis_circuit_type_cmd
);
2023 install_element(INTERFACE_NODE
, &no_isis_circuit_type_cmd
);
2025 install_element(INTERFACE_NODE
, &isis_network_cmd
);
2027 install_element(INTERFACE_NODE
, &isis_priority_cmd
);
2028 install_element(INTERFACE_NODE
, &no_isis_priority_cmd
);
2030 install_element(ISIS_NODE
, &log_adj_changes_cmd
);
2033 #endif /* ifndef FABRICD */