The additional match option will match the given address to the destination
of the routes, and return the result accordingly.
+.. index:: show ipv6 ospf6 interface [IFNAME] prefix [detail|<X:X::X:X|X:X::X:X/M> [<match|detail>]] [json]
+.. clicmd:: show ipv6 ospf6 interface [IFNAME] prefix [detail|<X:X::X:X|X:X::X:X/M> [<match|detail>]] [json]
+
+ This command shows the prefixes present in the interface routing table.
+ Interface name can also be given. JSON output can be obtained by appending
+ 'json' to the end of command.
+
OSPF6 Configuration Examples
============================
[<\
detail\
|<X:X::X:X|X:X::X:X/M> [<match|detail>]\
- >]",
+ >] [json]",
SHOW_STR
IP6_STR
OSPF6_STR
OSPF6_ROUTE_ADDRESS_STR
OSPF6_ROUTE_PREFIX_STR
OSPF6_ROUTE_MATCH_STR
- "Display details of the prefixes\n")
+ "Display details of the prefixes\n"
+ JSON_STR)
{
int idx_ifname = 4;
int idx_prefix = 6;
struct interface *ifp;
struct ospf6_interface *oi;
+ bool uj = use_json(argc, argv);
ifp = if_lookup_by_name(argv[idx_ifname]->arg, VRF_DEFAULT);
if (ifp == NULL) {
}
ospf6_route_table_show(vty, idx_prefix, argc, argv, oi->route_connected,
- false);
+ uj);
return CMD_SUCCESS;
}
[<\
detail\
|<X:X::X:X|X:X::X:X/M> [<match|detail>]\
- >]",
+ >] [json]",
SHOW_STR
IP6_STR
OSPF6_STR
OSPF6_ROUTE_ADDRESS_STR
OSPF6_ROUTE_PREFIX_STR
OSPF6_ROUTE_MATCH_STR
- "Display details of the prefixes\n")
+ "Display details of the prefixes\n"
+ JSON_STR)
{
struct vrf *vrf = vrf_lookup_by_id(VRF_DEFAULT);
int idx_prefix = 5;
struct ospf6_interface *oi;
struct interface *ifp;
+ bool uj = use_json(argc, argv);
FOR_ALL_INTERFACES (vrf, ifp) {
oi = (struct ospf6_interface *)ifp->info;
continue;
ospf6_route_table_show(vty, idx_prefix, argc, argv,
- oi->route_connected, false);
+ oi->route_connected, uj);
}
return CMD_SUCCESS;