From af2e707d0fc447b84699eb10928a71507e90a02e Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Sun, 10 Jan 2021 10:26:43 +0100 Subject: Debian: vyos-1x depends on python3-spinx for "make docs" --- debian/control | 1 + sphinx/source/.gitignore | 1 + 2 files changed, 2 insertions(+) create mode 100644 sphinx/source/.gitignore diff --git a/debian/control b/debian/control index f7d9fccf6..d0ba72bcf 100644 --- a/debian/control +++ b/debian/control @@ -21,6 +21,7 @@ Build-Depends: python3-jinja2, python3-psutil, python3-setuptools, + python3-sphinx, python3-xmltodict, quilt, whois diff --git a/sphinx/source/.gitignore b/sphinx/source/.gitignore new file mode 100644 index 000000000..30d85567b --- /dev/null +++ b/sphinx/source/.gitignore @@ -0,0 +1 @@ +*.rst -- cgit v1.2.3 From e982b78f24d1dca3d2bc92a39b8e9fcf35b39a37 Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Sat, 9 Jan 2021 14:31:48 +0100 Subject: xml: op-mode: add preprocessor support as known from configuration mode --- Makefile | 21 +- op-mode-definitions/add-system-image.xml | 62 -- op-mode-definitions/add-system-image.xml.in | 62 ++ op-mode-definitions/clear-ip.xml | 40 -- op-mode-definitions/clear-ip.xml.in | 40 ++ op-mode-definitions/clear-ipv6.xml | 40 -- op-mode-definitions/clear-ipv6.xml.in | 40 ++ op-mode-definitions/configure.xml | 24 - op-mode-definitions/configure.xml.in | 24 + op-mode-definitions/connect.xml | 29 - op-mode-definitions/connect.xml.in | 29 + op-mode-definitions/date.xml | 64 -- op-mode-definitions/date.xml.in | 64 ++ op-mode-definitions/dhcp.xml | 203 ------ op-mode-definitions/dhcp.xml.in | 203 ++++++ op-mode-definitions/disconnect.xml | 20 - op-mode-definitions/disconnect.xml.in | 20 + op-mode-definitions/disks.xml | 50 -- op-mode-definitions/disks.xml.in | 50 ++ op-mode-definitions/dns-dynamic.xml | 75 -- op-mode-definitions/dns-dynamic.xml.in | 75 ++ op-mode-definitions/dns-forwarding.xml | 94 --- op-mode-definitions/dns-forwarding.xml.in | 94 +++ op-mode-definitions/flow-accounting-op.xml | 81 --- op-mode-definitions/flow-accounting-op.xml.in | 81 +++ op-mode-definitions/force-arp.xml | 103 --- op-mode-definitions/force-arp.xml.in | 103 +++ op-mode-definitions/force-ipv6-nd.xml | 33 - op-mode-definitions/force-ipv6-nd.xml.in | 33 + op-mode-definitions/force-ipv6-rd.xml | 34 - op-mode-definitions/force-ipv6-rd.xml.in | 34 + op-mode-definitions/force-mtu-host.xml | 34 - op-mode-definitions/force-mtu-host.xml.in | 34 + op-mode-definitions/generate-macsec-key.xml | 26 - op-mode-definitions/generate-macsec-key.xml.in | 26 + op-mode-definitions/generate-ssh-server-key.xml | 16 - op-mode-definitions/generate-ssh-server-key.xml.in | 16 + op-mode-definitions/igmp-proxy.xml | 13 - op-mode-definitions/igmp-proxy.xml.in | 13 + op-mode-definitions/ipoe-server.xml | 81 --- op-mode-definitions/ipoe-server.xml.in | 81 +++ op-mode-definitions/ipv4-route.xml | 87 --- op-mode-definitions/ipv4-route.xml.in | 87 +++ op-mode-definitions/ipv6-route.xml | 133 ---- op-mode-definitions/ipv6-route.xml.in | 133 ++++ op-mode-definitions/l2tp-server.xml | 26 - op-mode-definitions/l2tp-server.xml.in | 26 + op-mode-definitions/lldp.xml | 37 - op-mode-definitions/lldp.xml.in | 37 + op-mode-definitions/monitor-bandwidth-test.xml | 29 - op-mode-definitions/monitor-bandwidth-test.xml.in | 29 + op-mode-definitions/monitor-bandwidth.xml | 23 - op-mode-definitions/monitor-bandwidth.xml.in | 23 + op-mode-definitions/monitor-log.xml | 13 - op-mode-definitions/monitor-log.xml.in | 13 + op-mode-definitions/monitor-ndp.xml | 44 -- op-mode-definitions/monitor-ndp.xml.in | 44 ++ op-mode-definitions/nat.xml | 98 --- op-mode-definitions/nat.xml.in | 98 +++ op-mode-definitions/openconnect.xml | 20 - op-mode-definitions/openconnect.xml.in | 20 + op-mode-definitions/openvpn.xml | 140 ---- op-mode-definitions/openvpn.xml.in | 139 ++++ op-mode-definitions/ping.xml | 23 - op-mode-definitions/ping.xml.in | 23 + op-mode-definitions/poweroff.xml | 52 -- op-mode-definitions/poweroff.xml.in | 52 ++ op-mode-definitions/pppoe-server.xml | 104 --- op-mode-definitions/pppoe-server.xml.in | 104 +++ op-mode-definitions/pptp-server.xml | 26 - op-mode-definitions/pptp-server.xml.in | 26 + op-mode-definitions/reboot.xml | 52 -- op-mode-definitions/reboot.xml.in | 52 ++ op-mode-definitions/reset-conntrack.xml | 16 - op-mode-definitions/reset-conntrack.xml.in | 16 + op-mode-definitions/reset-ip-bgp.xml | 203 ------ op-mode-definitions/reset-ip-bgp.xml.in | 203 ++++++ op-mode-definitions/reset-ip-igmp.xml | 24 - op-mode-definitions/reset-ip-igmp.xml.in | 24 + op-mode-definitions/reset-ip-multicast.xml | 24 - op-mode-definitions/reset-ip-multicast.xml.in | 24 + op-mode-definitions/reset-ipv6-bgp.xml | 62 -- op-mode-definitions/reset-ipv6-bgp.xml.in | 62 ++ op-mode-definitions/reset-mpls.xml | 31 - op-mode-definitions/reset-mpls.xml.in | 31 + op-mode-definitions/reset-vpn.xml | 96 --- op-mode-definitions/reset-vpn.xml.in | 96 +++ op-mode-definitions/restart-frr.xml | 63 -- op-mode-definitions/restart-frr.xml.in | 63 ++ op-mode-definitions/restart.xml | 8 - op-mode-definitions/restart.xml.in | 8 + op-mode-definitions/show-acceleration.xml | 63 -- op-mode-definitions/show-acceleration.xml.in | 63 ++ op-mode-definitions/show-bridge.xml | 36 - op-mode-definitions/show-bridge.xml.in | 36 + op-mode-definitions/show-configuration.xml | 37 - op-mode-definitions/show-configuration.xml.in | 37 + op-mode-definitions/show-console-server.xml | 36 - op-mode-definitions/show-console-server.xml.in | 36 + op-mode-definitions/show-environment.xml | 21 - op-mode-definitions/show-environment.xml.in | 21 + op-mode-definitions/show-hardware.xml | 94 --- op-mode-definitions/show-hardware.xml.in | 94 +++ op-mode-definitions/show-history.xml | 31 - op-mode-definitions/show-history.xml.in | 31 + op-mode-definitions/show-host.xml | 44 -- op-mode-definitions/show-host.xml.in | 44 ++ op-mode-definitions/show-interfaces-bonding.xml | 71 -- op-mode-definitions/show-interfaces-bonding.xml.in | 71 ++ op-mode-definitions/show-interfaces-bridge.xml | 48 -- op-mode-definitions/show-interfaces-bridge.xml.in | 48 ++ op-mode-definitions/show-interfaces-dummy.xml | 42 -- op-mode-definitions/show-interfaces-dummy.xml.in | 42 ++ op-mode-definitions/show-interfaces-ethernet.xml | 97 --- .../show-interfaces-ethernet.xml.in | 97 +++ op-mode-definitions/show-interfaces-input.xml | 42 -- op-mode-definitions/show-interfaces-input.xml.in | 42 ++ op-mode-definitions/show-interfaces-l2tpv3.xml | 42 -- op-mode-definitions/show-interfaces-l2tpv3.xml.in | 42 ++ op-mode-definitions/show-interfaces-loopback.xml | 42 -- .../show-interfaces-loopback.xml.in | 42 ++ op-mode-definitions/show-interfaces-macsec.xml | 29 - op-mode-definitions/show-interfaces-macsec.xml.in | 29 + op-mode-definitions/show-interfaces-pppoe.xml | 51 -- op-mode-definitions/show-interfaces-pppoe.xml.in | 51 ++ .../show-interfaces-pseudo-ethernet.xml | 42 -- .../show-interfaces-pseudo-ethernet.xml.in | 42 ++ op-mode-definitions/show-interfaces-tunnel.xml | 42 -- op-mode-definitions/show-interfaces-tunnel.xml.in | 42 ++ op-mode-definitions/show-interfaces-vti.xml | 42 -- op-mode-definitions/show-interfaces-vti.xml.in | 42 ++ op-mode-definitions/show-interfaces-vxlan.xml | 42 -- op-mode-definitions/show-interfaces-vxlan.xml.in | 42 ++ .../show-interfaces-wirelessmodem.xml | 51 -- .../show-interfaces-wirelessmodem.xml.in | 51 ++ op-mode-definitions/show-interfaces.xml | 27 - op-mode-definitions/show-interfaces.xml.in | 27 + ...show-ip-access-paths-prefix-community-lists.xml | 116 --- ...w-ip-access-paths-prefix-community-lists.xml.in | 116 +++ op-mode-definitions/show-ip-bgp.xml | 342 --------- op-mode-definitions/show-ip-bgp.xml.in | 342 +++++++++ op-mode-definitions/show-ip-igmp.xml | 48 -- op-mode-definitions/show-ip-igmp.xml.in | 48 ++ op-mode-definitions/show-ip-multicast.xml | 42 -- op-mode-definitions/show-ip-multicast.xml.in | 42 ++ op-mode-definitions/show-ip-ospf.xml | 579 --------------- op-mode-definitions/show-ip-ospf.xml.in | 579 +++++++++++++++ op-mode-definitions/show-ip-pim.xml | 72 -- op-mode-definitions/show-ip-pim.xml.in | 72 ++ op-mode-definitions/show-ip-ports.xml | 17 - op-mode-definitions/show-ip-ports.xml.in | 17 + op-mode-definitions/show-ip-rip.xml | 28 - op-mode-definitions/show-ip-rip.xml.in | 28 + op-mode-definitions/show-ip-route.xml | 166 ----- op-mode-definitions/show-ip-route.xml.in | 166 +++++ op-mode-definitions/show-ipv6-bgp.xml | 203 ------ op-mode-definitions/show-ipv6-bgp.xml.in | 203 ++++++ op-mode-definitions/show-ipv6-ospfv3.xml | 777 --------------------- op-mode-definitions/show-ipv6-ospfv3.xml.in | 777 +++++++++++++++++++++ op-mode-definitions/show-ipv6-prefix-list.xml | 92 --- op-mode-definitions/show-ipv6-prefix-list.xml.in | 92 +++ op-mode-definitions/show-ipv6-route.xml | 117 ---- op-mode-definitions/show-ipv6-route.xml.in | 117 ++++ op-mode-definitions/show-ipv6.xml | 49 -- op-mode-definitions/show-ipv6.xml.in | 49 ++ op-mode-definitions/show-isis.xml | 191 ----- op-mode-definitions/show-isis.xml.in | 191 +++++ op-mode-definitions/show-license.xml | 13 - op-mode-definitions/show-license.xml.in | 13 + op-mode-definitions/show-log.xml | 218 ------ op-mode-definitions/show-log.xml.in | 218 ++++++ op-mode-definitions/show-login.xml | 33 - op-mode-definitions/show-login.xml.in | 33 + op-mode-definitions/show-monitoring.xml | 13 - op-mode-definitions/show-monitoring.xml.in | 13 + op-mode-definitions/show-mpls.xml | 218 ------ op-mode-definitions/show-mpls.xml.in | 218 ++++++ op-mode-definitions/show-ntp.xml | 31 - op-mode-definitions/show-ntp.xml.in | 31 + op-mode-definitions/show-poweroff.xml | 13 - op-mode-definitions/show-poweroff.xml.in | 13 + op-mode-definitions/show-protocols-bfd.xml | 55 -- op-mode-definitions/show-protocols-bfd.xml.in | 55 ++ op-mode-definitions/show-protocols-static.xml | 49 -- op-mode-definitions/show-protocols-static.xml.in | 49 ++ op-mode-definitions/show-raid.xml | 16 - op-mode-definitions/show-raid.xml.in | 16 + op-mode-definitions/show-reboot.xml | 13 - op-mode-definitions/show-reboot.xml.in | 13 + op-mode-definitions/show-route-map.xml | 22 - op-mode-definitions/show-route-map.xml.in | 22 + op-mode-definitions/show-rpki.xml | 32 - op-mode-definitions/show-rpki.xml.in | 32 + op-mode-definitions/show-system.xml | 183 ----- op-mode-definitions/show-system.xml.in | 183 +++++ op-mode-definitions/show-table.xml | 13 - op-mode-definitions/show-table.xml.in | 13 + op-mode-definitions/show-users.xml | 30 - op-mode-definitions/show-users.xml.in | 30 + op-mode-definitions/show-version.xml | 33 - op-mode-definitions/show-version.xml.in | 33 + op-mode-definitions/show-vpn.xml | 20 - op-mode-definitions/show-vpn.xml.in | 20 + op-mode-definitions/show-vrf.xml | 30 - op-mode-definitions/show-vrf.xml.in | 30 + op-mode-definitions/snmp.xml | 111 --- op-mode-definitions/snmp.xml.in | 111 +++ op-mode-definitions/sstp-server.xml | 26 - op-mode-definitions/sstp-server.xml.in | 26 + op-mode-definitions/telnet.xml | 30 - op-mode-definitions/telnet.xml.in | 30 + op-mode-definitions/terminal.xml | 122 ---- op-mode-definitions/terminal.xml.in | 122 ++++ op-mode-definitions/traceroute.xml | 227 ------ op-mode-definitions/traceroute.xml.in | 227 ++++++ op-mode-definitions/traffic-dump.xml | 45 -- op-mode-definitions/traffic-dump.xml.in | 45 ++ op-mode-definitions/vrrp.xml | 37 - op-mode-definitions/vrrp.xml.in | 37 + op-mode-definitions/wake-on-lan.xml | 26 - op-mode-definitions/wake-on-lan.xml.in | 26 + op-mode-definitions/webproxy.xml | 110 --- op-mode-definitions/webproxy.xml.in | 110 +++ op-mode-definitions/wireguard.xml | 138 ---- op-mode-definitions/wireguard.xml.in | 137 ++++ op-mode-definitions/wireless.xml | 119 ---- op-mode-definitions/wireless.xml.in | 119 ++++ 227 files changed, 8501 insertions(+), 8504 deletions(-) delete mode 100644 op-mode-definitions/add-system-image.xml create mode 100644 op-mode-definitions/add-system-image.xml.in delete mode 100644 op-mode-definitions/clear-ip.xml create mode 100644 op-mode-definitions/clear-ip.xml.in delete mode 100644 op-mode-definitions/clear-ipv6.xml create mode 100644 op-mode-definitions/clear-ipv6.xml.in delete mode 100644 op-mode-definitions/configure.xml create mode 100644 op-mode-definitions/configure.xml.in delete mode 100644 op-mode-definitions/connect.xml create mode 100644 op-mode-definitions/connect.xml.in delete mode 100644 op-mode-definitions/date.xml create mode 100644 op-mode-definitions/date.xml.in delete mode 100644 op-mode-definitions/dhcp.xml create mode 100644 op-mode-definitions/dhcp.xml.in delete mode 100644 op-mode-definitions/disconnect.xml create mode 100644 op-mode-definitions/disconnect.xml.in delete mode 100644 op-mode-definitions/disks.xml create mode 100644 op-mode-definitions/disks.xml.in delete mode 100644 op-mode-definitions/dns-dynamic.xml create mode 100644 op-mode-definitions/dns-dynamic.xml.in delete mode 100644 op-mode-definitions/dns-forwarding.xml create mode 100644 op-mode-definitions/dns-forwarding.xml.in delete mode 100644 op-mode-definitions/flow-accounting-op.xml create mode 100644 op-mode-definitions/flow-accounting-op.xml.in delete mode 100644 op-mode-definitions/force-arp.xml create mode 100644 op-mode-definitions/force-arp.xml.in delete mode 100644 op-mode-definitions/force-ipv6-nd.xml create mode 100644 op-mode-definitions/force-ipv6-nd.xml.in delete mode 100644 op-mode-definitions/force-ipv6-rd.xml create mode 100644 op-mode-definitions/force-ipv6-rd.xml.in delete mode 100644 op-mode-definitions/force-mtu-host.xml create mode 100644 op-mode-definitions/force-mtu-host.xml.in delete mode 100644 op-mode-definitions/generate-macsec-key.xml create mode 100644 op-mode-definitions/generate-macsec-key.xml.in delete mode 100644 op-mode-definitions/generate-ssh-server-key.xml create mode 100644 op-mode-definitions/generate-ssh-server-key.xml.in delete mode 100644 op-mode-definitions/igmp-proxy.xml create mode 100644 op-mode-definitions/igmp-proxy.xml.in delete mode 100644 op-mode-definitions/ipoe-server.xml create mode 100644 op-mode-definitions/ipoe-server.xml.in delete mode 100644 op-mode-definitions/ipv4-route.xml create mode 100644 op-mode-definitions/ipv4-route.xml.in delete mode 100644 op-mode-definitions/ipv6-route.xml create mode 100644 op-mode-definitions/ipv6-route.xml.in delete mode 100644 op-mode-definitions/l2tp-server.xml create mode 100644 op-mode-definitions/l2tp-server.xml.in delete mode 100644 op-mode-definitions/lldp.xml create mode 100644 op-mode-definitions/lldp.xml.in delete mode 100644 op-mode-definitions/monitor-bandwidth-test.xml create mode 100644 op-mode-definitions/monitor-bandwidth-test.xml.in delete mode 100644 op-mode-definitions/monitor-bandwidth.xml create mode 100644 op-mode-definitions/monitor-bandwidth.xml.in delete mode 100644 op-mode-definitions/monitor-log.xml create mode 100644 op-mode-definitions/monitor-log.xml.in delete mode 100644 op-mode-definitions/monitor-ndp.xml create mode 100644 op-mode-definitions/monitor-ndp.xml.in delete mode 100644 op-mode-definitions/nat.xml create mode 100644 op-mode-definitions/nat.xml.in delete mode 100644 op-mode-definitions/openconnect.xml create mode 100644 op-mode-definitions/openconnect.xml.in delete mode 100644 op-mode-definitions/openvpn.xml create mode 100644 op-mode-definitions/openvpn.xml.in delete mode 100644 op-mode-definitions/ping.xml create mode 100644 op-mode-definitions/ping.xml.in delete mode 100644 op-mode-definitions/poweroff.xml create mode 100644 op-mode-definitions/poweroff.xml.in delete mode 100644 op-mode-definitions/pppoe-server.xml create mode 100644 op-mode-definitions/pppoe-server.xml.in delete mode 100644 op-mode-definitions/pptp-server.xml create mode 100644 op-mode-definitions/pptp-server.xml.in delete mode 100644 op-mode-definitions/reboot.xml create mode 100644 op-mode-definitions/reboot.xml.in delete mode 100644 op-mode-definitions/reset-conntrack.xml create mode 100644 op-mode-definitions/reset-conntrack.xml.in delete mode 100644 op-mode-definitions/reset-ip-bgp.xml create mode 100644 op-mode-definitions/reset-ip-bgp.xml.in delete mode 100644 op-mode-definitions/reset-ip-igmp.xml create mode 100644 op-mode-definitions/reset-ip-igmp.xml.in delete mode 100644 op-mode-definitions/reset-ip-multicast.xml create mode 100644 op-mode-definitions/reset-ip-multicast.xml.in delete mode 100644 op-mode-definitions/reset-ipv6-bgp.xml create mode 100644 op-mode-definitions/reset-ipv6-bgp.xml.in delete mode 100644 op-mode-definitions/reset-mpls.xml create mode 100644 op-mode-definitions/reset-mpls.xml.in delete mode 100644 op-mode-definitions/reset-vpn.xml create mode 100644 op-mode-definitions/reset-vpn.xml.in delete mode 100644 op-mode-definitions/restart-frr.xml create mode 100644 op-mode-definitions/restart-frr.xml.in delete mode 100644 op-mode-definitions/restart.xml create mode 100644 op-mode-definitions/restart.xml.in delete mode 100644 op-mode-definitions/show-acceleration.xml create mode 100644 op-mode-definitions/show-acceleration.xml.in delete mode 100644 op-mode-definitions/show-bridge.xml create mode 100644 op-mode-definitions/show-bridge.xml.in delete mode 100644 op-mode-definitions/show-configuration.xml create mode 100644 op-mode-definitions/show-configuration.xml.in delete mode 100644 op-mode-definitions/show-console-server.xml create mode 100644 op-mode-definitions/show-console-server.xml.in delete mode 100644 op-mode-definitions/show-environment.xml create mode 100644 op-mode-definitions/show-environment.xml.in delete mode 100644 op-mode-definitions/show-hardware.xml create mode 100644 op-mode-definitions/show-hardware.xml.in delete mode 100644 op-mode-definitions/show-history.xml create mode 100644 op-mode-definitions/show-history.xml.in delete mode 100644 op-mode-definitions/show-host.xml create mode 100644 op-mode-definitions/show-host.xml.in delete mode 100644 op-mode-definitions/show-interfaces-bonding.xml create mode 100644 op-mode-definitions/show-interfaces-bonding.xml.in delete mode 100644 op-mode-definitions/show-interfaces-bridge.xml create mode 100644 op-mode-definitions/show-interfaces-bridge.xml.in delete mode 100644 op-mode-definitions/show-interfaces-dummy.xml create mode 100644 op-mode-definitions/show-interfaces-dummy.xml.in delete mode 100644 op-mode-definitions/show-interfaces-ethernet.xml create mode 100644 op-mode-definitions/show-interfaces-ethernet.xml.in delete mode 100644 op-mode-definitions/show-interfaces-input.xml create mode 100644 op-mode-definitions/show-interfaces-input.xml.in delete mode 100644 op-mode-definitions/show-interfaces-l2tpv3.xml create mode 100644 op-mode-definitions/show-interfaces-l2tpv3.xml.in delete mode 100644 op-mode-definitions/show-interfaces-loopback.xml create mode 100644 op-mode-definitions/show-interfaces-loopback.xml.in delete mode 100644 op-mode-definitions/show-interfaces-macsec.xml create mode 100644 op-mode-definitions/show-interfaces-macsec.xml.in delete mode 100644 op-mode-definitions/show-interfaces-pppoe.xml create mode 100644 op-mode-definitions/show-interfaces-pppoe.xml.in delete mode 100644 op-mode-definitions/show-interfaces-pseudo-ethernet.xml create mode 100644 op-mode-definitions/show-interfaces-pseudo-ethernet.xml.in delete mode 100644 op-mode-definitions/show-interfaces-tunnel.xml create mode 100644 op-mode-definitions/show-interfaces-tunnel.xml.in delete mode 100644 op-mode-definitions/show-interfaces-vti.xml create mode 100644 op-mode-definitions/show-interfaces-vti.xml.in delete mode 100644 op-mode-definitions/show-interfaces-vxlan.xml create mode 100644 op-mode-definitions/show-interfaces-vxlan.xml.in delete mode 100644 op-mode-definitions/show-interfaces-wirelessmodem.xml create mode 100644 op-mode-definitions/show-interfaces-wirelessmodem.xml.in delete mode 100644 op-mode-definitions/show-interfaces.xml create mode 100644 op-mode-definitions/show-interfaces.xml.in delete mode 100644 op-mode-definitions/show-ip-access-paths-prefix-community-lists.xml create mode 100644 op-mode-definitions/show-ip-access-paths-prefix-community-lists.xml.in delete mode 100644 op-mode-definitions/show-ip-bgp.xml create mode 100644 op-mode-definitions/show-ip-bgp.xml.in delete mode 100644 op-mode-definitions/show-ip-igmp.xml create mode 100644 op-mode-definitions/show-ip-igmp.xml.in delete mode 100644 op-mode-definitions/show-ip-multicast.xml create mode 100644 op-mode-definitions/show-ip-multicast.xml.in delete mode 100644 op-mode-definitions/show-ip-ospf.xml create mode 100644 op-mode-definitions/show-ip-ospf.xml.in delete mode 100644 op-mode-definitions/show-ip-pim.xml create mode 100644 op-mode-definitions/show-ip-pim.xml.in delete mode 100644 op-mode-definitions/show-ip-ports.xml create mode 100644 op-mode-definitions/show-ip-ports.xml.in delete mode 100644 op-mode-definitions/show-ip-rip.xml create mode 100644 op-mode-definitions/show-ip-rip.xml.in delete mode 100644 op-mode-definitions/show-ip-route.xml create mode 100644 op-mode-definitions/show-ip-route.xml.in delete mode 100644 op-mode-definitions/show-ipv6-bgp.xml create mode 100644 op-mode-definitions/show-ipv6-bgp.xml.in delete mode 100644 op-mode-definitions/show-ipv6-ospfv3.xml create mode 100644 op-mode-definitions/show-ipv6-ospfv3.xml.in delete mode 100644 op-mode-definitions/show-ipv6-prefix-list.xml create mode 100644 op-mode-definitions/show-ipv6-prefix-list.xml.in delete mode 100644 op-mode-definitions/show-ipv6-route.xml create mode 100644 op-mode-definitions/show-ipv6-route.xml.in delete mode 100644 op-mode-definitions/show-ipv6.xml create mode 100644 op-mode-definitions/show-ipv6.xml.in delete mode 100644 op-mode-definitions/show-isis.xml create mode 100644 op-mode-definitions/show-isis.xml.in delete mode 100644 op-mode-definitions/show-license.xml create mode 100644 op-mode-definitions/show-license.xml.in delete mode 100644 op-mode-definitions/show-log.xml create mode 100644 op-mode-definitions/show-log.xml.in delete mode 100644 op-mode-definitions/show-login.xml create mode 100644 op-mode-definitions/show-login.xml.in delete mode 100644 op-mode-definitions/show-monitoring.xml create mode 100644 op-mode-definitions/show-monitoring.xml.in delete mode 100644 op-mode-definitions/show-mpls.xml create mode 100644 op-mode-definitions/show-mpls.xml.in delete mode 100644 op-mode-definitions/show-ntp.xml create mode 100644 op-mode-definitions/show-ntp.xml.in delete mode 100644 op-mode-definitions/show-poweroff.xml create mode 100644 op-mode-definitions/show-poweroff.xml.in delete mode 100644 op-mode-definitions/show-protocols-bfd.xml create mode 100644 op-mode-definitions/show-protocols-bfd.xml.in delete mode 100644 op-mode-definitions/show-protocols-static.xml create mode 100644 op-mode-definitions/show-protocols-static.xml.in delete mode 100644 op-mode-definitions/show-raid.xml create mode 100644 op-mode-definitions/show-raid.xml.in delete mode 100644 op-mode-definitions/show-reboot.xml create mode 100644 op-mode-definitions/show-reboot.xml.in delete mode 100644 op-mode-definitions/show-route-map.xml create mode 100644 op-mode-definitions/show-route-map.xml.in delete mode 100644 op-mode-definitions/show-rpki.xml create mode 100644 op-mode-definitions/show-rpki.xml.in delete mode 100644 op-mode-definitions/show-system.xml create mode 100644 op-mode-definitions/show-system.xml.in delete mode 100644 op-mode-definitions/show-table.xml create mode 100644 op-mode-definitions/show-table.xml.in delete mode 100644 op-mode-definitions/show-users.xml create mode 100644 op-mode-definitions/show-users.xml.in delete mode 100644 op-mode-definitions/show-version.xml create mode 100644 op-mode-definitions/show-version.xml.in delete mode 100644 op-mode-definitions/show-vpn.xml create mode 100644 op-mode-definitions/show-vpn.xml.in delete mode 100644 op-mode-definitions/show-vrf.xml create mode 100644 op-mode-definitions/show-vrf.xml.in delete mode 100644 op-mode-definitions/snmp.xml create mode 100644 op-mode-definitions/snmp.xml.in delete mode 100644 op-mode-definitions/sstp-server.xml create mode 100644 op-mode-definitions/sstp-server.xml.in delete mode 100644 op-mode-definitions/telnet.xml create mode 100644 op-mode-definitions/telnet.xml.in delete mode 100644 op-mode-definitions/terminal.xml create mode 100644 op-mode-definitions/terminal.xml.in delete mode 100644 op-mode-definitions/traceroute.xml create mode 100644 op-mode-definitions/traceroute.xml.in delete mode 100644 op-mode-definitions/traffic-dump.xml create mode 100644 op-mode-definitions/traffic-dump.xml.in delete mode 100644 op-mode-definitions/vrrp.xml create mode 100644 op-mode-definitions/vrrp.xml.in delete mode 100644 op-mode-definitions/wake-on-lan.xml create mode 100644 op-mode-definitions/wake-on-lan.xml.in delete mode 100644 op-mode-definitions/webproxy.xml create mode 100644 op-mode-definitions/webproxy.xml.in delete mode 100644 op-mode-definitions/wireguard.xml create mode 100644 op-mode-definitions/wireguard.xml.in delete mode 100644 op-mode-definitions/wireless.xml create mode 100644 op-mode-definitions/wireless.xml.in diff --git a/Makefile b/Makefile index 588595e42..3f13c66a0 100644 --- a/Makefile +++ b/Makefile @@ -8,8 +8,10 @@ CC := gcc LIBS := -lzmq CFLAGS := -src = $(wildcard interface-definitions/*.xml.in) -obj = $(src:.xml.in=.xml) +config_xml_src = $(wildcard interface-definitions/*.xml.in) +config_xml_obj = $(config_xml_src:.xml.in=.xml) +op_xml_src = $(wildcard op-mode-definitions/*.xml.in) +op_xml_obj = $(op_xml_src:.xml.in=.xml) %.xml: %.xml.in @echo Generating $(BUILD_DIR)/$@ from $< @@ -23,15 +25,12 @@ obj = $(src:.xml.in=.xml) # -nostdinc Do not search the standard system directories for header files # -P Inhibit generation of linemarkers in the output from the # preprocessor - @$(CC) -x c-header -E -undef -nostdinc -P -I$(CURDIR)/interface-definitions -o $(BUILD_DIR)/$@ -c $< - -$(BUILD_DIR): - install -d -m 0755 $(BUILD_DIR)/interface-definitions - install -d -m 0755 $(BUILD_DIR)/op-mode-definitions + mkdir -p $(BUILD_DIR)/$(dir $@) + @$(CC) -x c-header -E -undef -nostdinc -P -I$(CURDIR)/$(dir $<) -o $(BUILD_DIR)/$@ -c $< .PHONY: interface_definitions .ONESHELL: -interface_definitions: $(BUILD_DIR) $(obj) +interface_definitions: $(config_xml_obj) mkdir -p $(TMPL_DIR) find $(BUILD_DIR)/interface-definitions -type f -name "*.xml" | xargs -I {} $(CURDIR)/scripts/build-command-templates {} $(CURDIR)/schema/interface_definition.rng $(TMPL_DIR) || exit 1 @@ -62,10 +61,10 @@ interface_definitions: $(BUILD_DIR) $(obj) .PHONY: op_mode_definitions .ONESHELL: -op_mode_definitions: +op_mode_definitions: $(op_xml_obj) mkdir -p $(OP_TMPL_DIR) - find $(CURDIR)/op-mode-definitions/ -type f -name "*.xml" | xargs -I {} $(CURDIR)/scripts/build-command-op-templates {} $(CURDIR)/schema/op-mode-definition.rng $(OP_TMPL_DIR) || exit 1 + find $(BUILD_DIR)/op-mode-definitions/ -type f -name "*.xml" | xargs -I {} $(CURDIR)/scripts/build-command-op-templates {} $(CURDIR)/schema/op-mode-definition.rng $(OP_TMPL_DIR) || exit 1 # XXX: delete top level op mode node.def's that now live in other packages rm -f $(OP_TMPL_DIR)/add/node.def @@ -87,7 +86,7 @@ op_mode_definitions: .PHONY: component_versions .ONESHELL: -component_versions: $(BUILD_DIR) $(obj) +component_versions: interface_definitions $(CURDIR)/scripts/build-component-versions $(BUILD_DIR)/interface-definitions $(DATA_DIR) .PHONY: vyshim diff --git a/op-mode-definitions/add-system-image.xml b/op-mode-definitions/add-system-image.xml deleted file mode 100644 index 3dc1c67ab..000000000 --- a/op-mode-definitions/add-system-image.xml +++ /dev/null @@ -1,62 +0,0 @@ - - - - - - - Add item to a system facility - - - - - Add a new image to the system - - /path/to/vyos-image.iso http://example.com/vyos-image.iso - - - sudo ${vyatta_sbindir}/install-image --url "${4}" - - - - Download image via specified VRF - - vrf name - - - sudo ${vyatta_sbindir}/install-image --url "${4}" --vrf "${6}" - - - - Username for authentication - - - - - Password to use with authentication - - sudo ${vyatta_sbindir}/install-image --url "${4}" --vrf "${6}" --username "${8}" --password "${10}" - - - - - - - - Username for authentication - - - - - Password to use with authentication - - sudo ${vyatta_sbindir}/install-image --url "${4}" --username "${6}" --password "${8}" - - - - - - - - - - diff --git a/op-mode-definitions/add-system-image.xml.in b/op-mode-definitions/add-system-image.xml.in new file mode 100644 index 000000000..67d8aa3b4 --- /dev/null +++ b/op-mode-definitions/add-system-image.xml.in @@ -0,0 +1,62 @@ + + + + + + + Add item to a system facility + + + + + Add a new image to the system + + /path/to/vyos-image.iso "http://example.com/vyos-image.iso" + + + sudo ${vyatta_sbindir}/install-image --url "${4}" + + + + Download image via specified VRF + + vrf name + + + sudo ${vyatta_sbindir}/install-image --url "${4}" --vrf "${6}" + + + + Username for authentication + + + + + Password to use with authentication + + sudo ${vyatta_sbindir}/install-image --url "${4}" --vrf "${6}" --username "${8}" --password "${10}" + + + + + + + + Username for authentication + + + + + Password to use with authentication + + sudo ${vyatta_sbindir}/install-image --url "${4}" --username "${6}" --password "${8}" + + + + + + + + + + diff --git a/op-mode-definitions/clear-ip.xml b/op-mode-definitions/clear-ip.xml deleted file mode 100644 index 3c75ed11b..000000000 --- a/op-mode-definitions/clear-ip.xml +++ /dev/null @@ -1,40 +0,0 @@ - - - - - - - Clear Internet Protocol (IP) statistics or status - - - - - Clear prefix-list statistics or status - - vtysh -c "$*" - - - - Clear prefix-list statistics or status for specified word - - <WORD> - - - vtysh -c "$*" - - - - Clear prefix-list statistics or status for given word|network - - <x.x.x.x/x> - - - vtysh -c "$*" - - - - - - - - diff --git a/op-mode-definitions/clear-ip.xml.in b/op-mode-definitions/clear-ip.xml.in new file mode 100644 index 000000000..3c75ed11b --- /dev/null +++ b/op-mode-definitions/clear-ip.xml.in @@ -0,0 +1,40 @@ + + + + + + + Clear Internet Protocol (IP) statistics or status + + + + + Clear prefix-list statistics or status + + vtysh -c "$*" + + + + Clear prefix-list statistics or status for specified word + + <WORD> + + + vtysh -c "$*" + + + + Clear prefix-list statistics or status for given word|network + + <x.x.x.x/x> + + + vtysh -c "$*" + + + + + + + + diff --git a/op-mode-definitions/clear-ipv6.xml b/op-mode-definitions/clear-ipv6.xml deleted file mode 100644 index c062102fc..000000000 --- a/op-mode-definitions/clear-ipv6.xml +++ /dev/null @@ -1,40 +0,0 @@ - - - - - - - Clear Internet Protocol (IPv6) statistics or status - - - - - Clear prefix-list statistics or status - - vtysh -c "$*" - - - - Clear prefix-list statistics or status for specified word - - WORD - - - vtysh -c "$*" - - - - Clear prefix-list statistics or status for given word|network - - <h:h:h:h:h:h:h:h/x> - - - vtysh -c "$*" - - - - - - - - diff --git a/op-mode-definitions/clear-ipv6.xml.in b/op-mode-definitions/clear-ipv6.xml.in new file mode 100644 index 000000000..c062102fc --- /dev/null +++ b/op-mode-definitions/clear-ipv6.xml.in @@ -0,0 +1,40 @@ + + + + + + + Clear Internet Protocol (IPv6) statistics or status + + + + + Clear prefix-list statistics or status + + vtysh -c "$*" + + + + Clear prefix-list statistics or status for specified word + + WORD + + + vtysh -c "$*" + + + + Clear prefix-list statistics or status for given word|network + + <h:h:h:h:h:h:h:h/x> + + + vtysh -c "$*" + + + + + + + + diff --git a/op-mode-definitions/configure.xml b/op-mode-definitions/configure.xml deleted file mode 100644 index 3dd5a0f45..000000000 --- a/op-mode-definitions/configure.xml +++ /dev/null @@ -1,24 +0,0 @@ - - - - - Enter configuration mode - - if [ `id -u` == 0 ]; then - echo "You are attempting to enter configuration mode as root." - echo "It may have unintended consequences and render your system" - echo "unusable until restart." - echo "Please do it as an administrator level VyOS user instead." - else - if grep -q -e '^overlay.*/filesystem.squashfs' /proc/mounts; then - echo "WARNING: You are currently configuring a live-ISO environment, changes will not persist until installed" - fi - history -w - export _OFR_CONFIGURE=ok - newgrp vyattacfg - unset _OFR_CONFIGURE - _vyatta_op_do_key_bindings - history -r - fi - - diff --git a/op-mode-definitions/configure.xml.in b/op-mode-definitions/configure.xml.in new file mode 100644 index 000000000..3dd5a0f45 --- /dev/null +++ b/op-mode-definitions/configure.xml.in @@ -0,0 +1,24 @@ + + + + + Enter configuration mode + + if [ `id -u` == 0 ]; then + echo "You are attempting to enter configuration mode as root." + echo "It may have unintended consequences and render your system" + echo "unusable until restart." + echo "Please do it as an administrator level VyOS user instead." + else + if grep -q -e '^overlay.*/filesystem.squashfs' /proc/mounts; then + echo "WARNING: You are currently configuring a live-ISO environment, changes will not persist until installed" + fi + history -w + export _OFR_CONFIGURE=ok + newgrp vyattacfg + unset _OFR_CONFIGURE + _vyatta_op_do_key_bindings + history -r + fi + + diff --git a/op-mode-definitions/connect.xml b/op-mode-definitions/connect.xml deleted file mode 100644 index 1ec62949a..000000000 --- a/op-mode-definitions/connect.xml +++ /dev/null @@ -1,29 +0,0 @@ - - - - - Establish connection - - - - - Connect to device attached to serial console server - - service console-server device - - - /usr/bin/console "$3" - - - - Bring up a connection-oriented network interface - - interfaces pppoe - interfaces wirelessmodem - - - sudo ${vyos_op_scripts_dir}/connect_disconnect.py --connect "$3" - - - - diff --git a/op-mode-definitions/connect.xml.in b/op-mode-definitions/connect.xml.in new file mode 100644 index 000000000..1ec62949a --- /dev/null +++ b/op-mode-definitions/connect.xml.in @@ -0,0 +1,29 @@ + + + + + Establish connection + + + + + Connect to device attached to serial console server + + service console-server device + + + /usr/bin/console "$3" + + + + Bring up a connection-oriented network interface + + interfaces pppoe + interfaces wirelessmodem + + + sudo ${vyos_op_scripts_dir}/connect_disconnect.py --connect "$3" + + + + diff --git a/op-mode-definitions/date.xml b/op-mode-definitions/date.xml deleted file mode 100644 index 15a69dbd9..000000000 --- a/op-mode-definitions/date.xml +++ /dev/null @@ -1,64 +0,0 @@ - - - - - - - Show system time and date - - /bin/date - - - - Show system date and time as Coordinated Universal Time - - /bin/date -u - - - - Show UTC date in Maya calendar format - - ${vyos_op_scripts_dir}/maya_date.py $(date +%s) - - - - - - - - - - - - Set system date and time - - <MMDDhhmm> <MMDDhhmmYY> <MMDDhhmmCCYY> <MMDDhhmmCCYY.ss> - - - /bin/date "$3" - - - - Set system date and time - - - - - Set system date and time from NTP server (default: 0.pool.ntp.org) - - /usr/sbin/ntpdate -u 0.pool.ntp.org - - - - Set system date and time from NTP server - - - - - /usr/sbin/ntpdate -u "$4" - - - - - - diff --git a/op-mode-definitions/date.xml.in b/op-mode-definitions/date.xml.in new file mode 100644 index 000000000..15a69dbd9 --- /dev/null +++ b/op-mode-definitions/date.xml.in @@ -0,0 +1,64 @@ + + + + + + + Show system time and date + + /bin/date + + + + Show system date and time as Coordinated Universal Time + + /bin/date -u + + + + Show UTC date in Maya calendar format + + ${vyos_op_scripts_dir}/maya_date.py $(date +%s) + + + + + + + + + + + + Set system date and time + + <MMDDhhmm> <MMDDhhmmYY> <MMDDhhmmCCYY> <MMDDhhmmCCYY.ss> + + + /bin/date "$3" + + + + Set system date and time + + + + + Set system date and time from NTP server (default: 0.pool.ntp.org) + + /usr/sbin/ntpdate -u 0.pool.ntp.org + + + + Set system date and time from NTP server + + + + + /usr/sbin/ntpdate -u "$4" + + + + + + diff --git a/op-mode-definitions/dhcp.xml b/op-mode-definitions/dhcp.xml deleted file mode 100644 index 48752cfd5..000000000 --- a/op-mode-definitions/dhcp.xml +++ /dev/null @@ -1,203 +0,0 @@ - - - - - - - Show DHCP (Dynamic Host Configuration Protocol) information - - - - - Show DHCP server information - - - - - Show DHCP server leases - - sudo ${vyos_op_scripts_dir}/show_dhcp.py --leases - - - - Show DHCP server leases for a specific pool - - - - - sudo ${vyos_op_scripts_dir}/show_dhcp.py --leases --pool $6 - - - - Show DHCP server leases sorted by the specified key - - - - - sudo ${vyos_op_scripts_dir}/show_dhcp.py --leases --sort $6 - - - - Show DHCP server leases with a specific state (can be multiple, comma-separated) - - - - - sudo ${vyos_op_scripts_dir}/show_dhcp.py --leases --state $(echo $6 | tr , " ") - - - - - - Show DHCP server statistics - - sudo ${vyos_op_scripts_dir}/show_dhcp.py --statistics - - - - Show DHCP server statistics for a specific pool - - - - - sudo ${vyos_op_scripts_dir}/show_dhcp.py --statistics --pool $6 - - - - - - - - - - Show DHCPv6 (IPv6 Dynamic Host Configuration Protocol) information - - - - - Show DHCPv6 server information - - - - - Show DHCPv6 server leases - - sudo ${vyos_op_scripts_dir}/show_dhcpv6.py --leases - - - - Show DHCPv6 server leases for a specific pool - - - - - sudo ${vyos_op_scripts_dir}/show_dhcpv6.py --leases --pool $6 - - - - Show DHCPv6 server leases sorted by the specified key - - - - - sudo ${vyos_op_scripts_dir}/show_dhcpv6.py --leases --sort $6 - - - - Show DHCPv6 server leases with a specific state (can be multiple, comma-separated) - - - - - sudo ${vyos_op_scripts_dir}/show_dhcpv6.py --leases --state $(echo $6 | tr , " ") - - - - - - - - - - - - - - Restart DHCP processes - - - - - Restart the DHCP server process - - sudo systemctl restart isc-dhcp-server.service - - - - Restart the DHCP server process - - sudo ${vyos_op_scripts_dir}/restart_dhcp_relay.py --ipv4 - - - - - - Restart DHCPv6 processes - - - - - Restart the DHCPv6 server process - - sudo systemctl restart isc-dhcp-server6.service - - - - Restart the DHCP server process - - sudo ${vyos_op_scripts_dir}/restart_dhcp_relay.py --ipv6 - - - - - - - - Renew specified variable - - - - - Renew DHCP client lease - - - - - Renew DHCP client lease for specified interface - - - - - sudo systemctl restart "dhclient@$4.service" - - - - - - Renew DHCPv6 client lease - - - - - Renew DHCPv6 client lease for specified interface - - - - - sudo systemctl restart "dhcp6c@$4.service" - - - - - - diff --git a/op-mode-definitions/dhcp.xml.in b/op-mode-definitions/dhcp.xml.in new file mode 100644 index 000000000..48752cfd5 --- /dev/null +++ b/op-mode-definitions/dhcp.xml.in @@ -0,0 +1,203 @@ + + + + + + + Show DHCP (Dynamic Host Configuration Protocol) information + + + + + Show DHCP server information + + + + + Show DHCP server leases + + sudo ${vyos_op_scripts_dir}/show_dhcp.py --leases + + + + Show DHCP server leases for a specific pool + + + + + sudo ${vyos_op_scripts_dir}/show_dhcp.py --leases --pool $6 + + + + Show DHCP server leases sorted by the specified key + + + + + sudo ${vyos_op_scripts_dir}/show_dhcp.py --leases --sort $6 + + + + Show DHCP server leases with a specific state (can be multiple, comma-separated) + + + + + sudo ${vyos_op_scripts_dir}/show_dhcp.py --leases --state $(echo $6 | tr , " ") + + + + + + Show DHCP server statistics + + sudo ${vyos_op_scripts_dir}/show_dhcp.py --statistics + + + + Show DHCP server statistics for a specific pool + + + + + sudo ${vyos_op_scripts_dir}/show_dhcp.py --statistics --pool $6 + + + + + + + + + + Show DHCPv6 (IPv6 Dynamic Host Configuration Protocol) information + + + + + Show DHCPv6 server information + + + + + Show DHCPv6 server leases + + sudo ${vyos_op_scripts_dir}/show_dhcpv6.py --leases + + + + Show DHCPv6 server leases for a specific pool + + + + + sudo ${vyos_op_scripts_dir}/show_dhcpv6.py --leases --pool $6 + + + + Show DHCPv6 server leases sorted by the specified key + + + + + sudo ${vyos_op_scripts_dir}/show_dhcpv6.py --leases --sort $6 + + + + Show DHCPv6 server leases with a specific state (can be multiple, comma-separated) + + + + + sudo ${vyos_op_scripts_dir}/show_dhcpv6.py --leases --state $(echo $6 | tr , " ") + + + + + + + + + + + + + + Restart DHCP processes + + + + + Restart the DHCP server process + + sudo systemctl restart isc-dhcp-server.service + + + + Restart the DHCP server process + + sudo ${vyos_op_scripts_dir}/restart_dhcp_relay.py --ipv4 + + + + + + Restart DHCPv6 processes + + + + + Restart the DHCPv6 server process + + sudo systemctl restart isc-dhcp-server6.service + + + + Restart the DHCP server process + + sudo ${vyos_op_scripts_dir}/restart_dhcp_relay.py --ipv6 + + + + + + + + Renew specified variable + + + + + Renew DHCP client lease + + + + + Renew DHCP client lease for specified interface + + + + + sudo systemctl restart "dhclient@$4.service" + + + + + + Renew DHCPv6 client lease + + + + + Renew DHCPv6 client lease for specified interface + + + + + sudo systemctl restart "dhcp6c@$4.service" + + + + + + diff --git a/op-mode-definitions/disconnect.xml b/op-mode-definitions/disconnect.xml deleted file mode 100644 index bf2c37b89..000000000 --- a/op-mode-definitions/disconnect.xml +++ /dev/null @@ -1,20 +0,0 @@ - - - - - Take down a connection - - - - - Take down a connection-oriented network interface - - interfaces pppoe - interfaces wirelessmodem - - - sudo ${vyos_op_scripts_dir}/connect_disconnect.py --disconnect "$3" - - - - diff --git a/op-mode-definitions/disconnect.xml.in b/op-mode-definitions/disconnect.xml.in new file mode 100644 index 000000000..bf2c37b89 --- /dev/null +++ b/op-mode-definitions/disconnect.xml.in @@ -0,0 +1,20 @@ + + + + + Take down a connection + + + + + Take down a connection-oriented network interface + + interfaces pppoe + interfaces wirelessmodem + + + sudo ${vyos_op_scripts_dir}/connect_disconnect.py --disconnect "$3" + + + + diff --git a/op-mode-definitions/disks.xml b/op-mode-definitions/disks.xml deleted file mode 100644 index fb39c4f3c..000000000 --- a/op-mode-definitions/disks.xml +++ /dev/null @@ -1,50 +0,0 @@ - - - - - Format a device - - - - - Format a disk drive - - - - - - - - Format this disk the same as another disk - - - - - ${vyos_op_scripts_dir}/format_disk.py --target $3 --proto $5 - - - - - - - - - - - Show status of disk device - - - - - - - - Show disk drive formatting - - ${vyos_op_scripts_dir}/show_disk_format.sh $3 - - - - - - diff --git a/op-mode-definitions/disks.xml.in b/op-mode-definitions/disks.xml.in new file mode 100644 index 000000000..fb39c4f3c --- /dev/null +++ b/op-mode-definitions/disks.xml.in @@ -0,0 +1,50 @@ + + + + + Format a device + + + + + Format a disk drive + + + + + + + + Format this disk the same as another disk + + + + + ${vyos_op_scripts_dir}/format_disk.py --target $3 --proto $5 + + + + + + + + + + + Show status of disk device + + + + + + + + Show disk drive formatting + + ${vyos_op_scripts_dir}/show_disk_format.sh $3 + + + + + + diff --git a/op-mode-definitions/dns-dynamic.xml b/op-mode-definitions/dns-dynamic.xml deleted file mode 100644 index 9c37874fb..000000000 --- a/op-mode-definitions/dns-dynamic.xml +++ /dev/null @@ -1,75 +0,0 @@ - - - - - - - - - - - Show log for dynamic DNS - - cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e "ddclient" - - - - - - - - Show DNS information - - - - - Show Dynamic DNS information - - - - - Show Dynamic DNS status - - sudo ${vyos_op_scripts_dir}/dynamic_dns.py --status - - - - - - - - - - - - - - Restart Dynamic DNS service - - sudo ${vyos_op_scripts_dir}/dynamic_dns.py --update - - - - - - - - Update data for a service - - - - - Update DNS information - - - - - Update Dynamic DNS information - - sudo ${vyos_op_scripts_dir}/dynamic_dns.py --update - - - - - - diff --git a/op-mode-definitions/dns-dynamic.xml.in b/op-mode-definitions/dns-dynamic.xml.in new file mode 100644 index 000000000..9c37874fb --- /dev/null +++ b/op-mode-definitions/dns-dynamic.xml.in @@ -0,0 +1,75 @@ + + + + + + + + + + + Show log for dynamic DNS + + cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e "ddclient" + + + + + + + + Show DNS information + + + + + Show Dynamic DNS information + + + + + Show Dynamic DNS status + + sudo ${vyos_op_scripts_dir}/dynamic_dns.py --status + + + + + + + + + + + + + + Restart Dynamic DNS service + + sudo ${vyos_op_scripts_dir}/dynamic_dns.py --update + + + + + + + + Update data for a service + + + + + Update DNS information + + + + + Update Dynamic DNS information + + sudo ${vyos_op_scripts_dir}/dynamic_dns.py --update + + + + + + diff --git a/op-mode-definitions/dns-forwarding.xml b/op-mode-definitions/dns-forwarding.xml deleted file mode 100644 index 23de97704..000000000 --- a/op-mode-definitions/dns-forwarding.xml +++ /dev/null @@ -1,94 +0,0 @@ - - - - - - - - - Show log for Domain Name Service (DNS) - - - - - Show log for DNS Forwarding - - cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e "pdns_recursor" - - - - - - - - Show DNS information - - - - - Show DNS forwarding information - - - - - Show DNS forwarding statistics - - sudo ${vyos_op_scripts_dir}/dns_forwarding_statistics.py - - - - - - - - - - - - Restart a DNS service - - - - - Restart DNS forwarding service - - sudo ${vyos_op_scripts_dir}/dns_forwarding_restart.sh - - - - - - - - Reset a service - - - - - Reset a DNS service state - - - - - Reset DNS forwarding cache - - - - sudo ${vyos_op_scripts_dir}/dns_forwarding_reset.py $5 - - Reset DNS forwarding cache for a domain - - - - sudo ${vyos_op_scripts_dir}/dns_forwarding_reset.py --all - - Reset DNS forwarding cache - - - - - - - - - diff --git a/op-mode-definitions/dns-forwarding.xml.in b/op-mode-definitions/dns-forwarding.xml.in new file mode 100644 index 000000000..23de97704 --- /dev/null +++ b/op-mode-definitions/dns-forwarding.xml.in @@ -0,0 +1,94 @@ + + + + + + + + + Show log for Domain Name Service (DNS) + + + + + Show log for DNS Forwarding + + cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e "pdns_recursor" + + + + + + + + Show DNS information + + + + + Show DNS forwarding information + + + + + Show DNS forwarding statistics + + sudo ${vyos_op_scripts_dir}/dns_forwarding_statistics.py + + + + + + + + + + + + Restart a DNS service + + + + + Restart DNS forwarding service + + sudo ${vyos_op_scripts_dir}/dns_forwarding_restart.sh + + + + + + + + Reset a service + + + + + Reset a DNS service state + + + + + Reset DNS forwarding cache + + + + sudo ${vyos_op_scripts_dir}/dns_forwarding_reset.py $5 + + Reset DNS forwarding cache for a domain + + + + sudo ${vyos_op_scripts_dir}/dns_forwarding_reset.py --all + + Reset DNS forwarding cache + + + + + + + + + diff --git a/op-mode-definitions/flow-accounting-op.xml b/op-mode-definitions/flow-accounting-op.xml deleted file mode 100644 index 912805d59..000000000 --- a/op-mode-definitions/flow-accounting-op.xml +++ /dev/null @@ -1,81 +0,0 @@ - - - - - - - - Show flow accounting statistics - - ${vyos_op_scripts_dir}/flow_accounting_op.py --action show - - - - Show flow accounting statistics for specified interface - - - - - ${vyos_op_scripts_dir}/flow_accounting_op.py --action show --interface $4 - - - - Show flow accounting statistics for specified interface/host - - <x.x.x.x> <h:h:h:h:h:h:h:h> - - - ${vyos_op_scripts_dir}/flow_accounting_op.py --action show --interface $4 --host $6 - - - - Show flow accounting statistics for specified interface/port - - 1-65535 - - - ${vyos_op_scripts_dir}/flow_accounting_op.py --action show --interface $4 --ports $6 - - - - Show top N flows for specified interface - - 1-100 - - - ${vyos_op_scripts_dir}/flow_accounting_op.py --action show --interface $4 --top $6 - - - - - - - - - - - - Restart flow-accounting service - - ${vyos_op_scripts_dir}/flow_accounting_op.py --action restart - - - - - - - - Clear flow accounting - - - - - Clear flow accounting statistics - - ${vyos_op_scripts_dir}/flow_accounting_op.py --action clear - - - - - - diff --git a/op-mode-definitions/flow-accounting-op.xml.in b/op-mode-definitions/flow-accounting-op.xml.in new file mode 100644 index 000000000..912805d59 --- /dev/null +++ b/op-mode-definitions/flow-accounting-op.xml.in @@ -0,0 +1,81 @@ + + + + + + + + Show flow accounting statistics + + ${vyos_op_scripts_dir}/flow_accounting_op.py --action show + + + + Show flow accounting statistics for specified interface + + + + + ${vyos_op_scripts_dir}/flow_accounting_op.py --action show --interface $4 + + + + Show flow accounting statistics for specified interface/host + + <x.x.x.x> <h:h:h:h:h:h:h:h> + + + ${vyos_op_scripts_dir}/flow_accounting_op.py --action show --interface $4 --host $6 + + + + Show flow accounting statistics for specified interface/port + + 1-65535 + + + ${vyos_op_scripts_dir}/flow_accounting_op.py --action show --interface $4 --ports $6 + + + + Show top N flows for specified interface + + 1-100 + + + ${vyos_op_scripts_dir}/flow_accounting_op.py --action show --interface $4 --top $6 + + + + + + + + + + + + Restart flow-accounting service + + ${vyos_op_scripts_dir}/flow_accounting_op.py --action restart + + + + + + + + Clear flow accounting + + + + + Clear flow accounting statistics + + ${vyos_op_scripts_dir}/flow_accounting_op.py --action clear + + + + + + diff --git a/op-mode-definitions/force-arp.xml b/op-mode-definitions/force-arp.xml deleted file mode 100644 index f9f7c7643..000000000 --- a/op-mode-definitions/force-arp.xml +++ /dev/null @@ -1,103 +0,0 @@ - - - - - Force an operation - - - - - Send gratuitous ARP request or reply - - - - - Send gratuitous ARP reply - - - - - Send gratuitous ARP reply on specified interface - - - - - - - - Send gratuitous ARP reply for specified address - - sudo /usr/bin/arping -I $5 -c 1 -A $7 - - - - Send specified number of ARP replies - - sudo /usr/bin/arping -I $5 -c $9 -A $7 - - - - - - - - - - Send gratuitous ARP request - - - - - Send gratuitous ARP request on specified interface - - - - - - - - Send gratuitous ARP request for specified address - - sudo /usr/bin/arping -I $5 -c 1 -U $7 - - - - Send specified number of ARP requests - - sudo /usr/bin/arping -I $5 -c $9 -U $7 - - - - - - - - - - Send ARP for DAD detection - - - - - Send ARP for DAD detection on specified interface - - - - - - - - Send ARP for DAD detection for specified address - - sudo /usr/bin/arping -I $5 -c 1 -D $7 - - - - - - - - - - - diff --git a/op-mode-definitions/force-arp.xml.in b/op-mode-definitions/force-arp.xml.in new file mode 100644 index 000000000..f9f7c7643 --- /dev/null +++ b/op-mode-definitions/force-arp.xml.in @@ -0,0 +1,103 @@ + + + + + Force an operation + + + + + Send gratuitous ARP request or reply + + + + + Send gratuitous ARP reply + + + + + Send gratuitous ARP reply on specified interface + + + + + + + + Send gratuitous ARP reply for specified address + + sudo /usr/bin/arping -I $5 -c 1 -A $7 + + + + Send specified number of ARP replies + + sudo /usr/bin/arping -I $5 -c $9 -A $7 + + + + + + + + + + Send gratuitous ARP request + + + + + Send gratuitous ARP request on specified interface + + + + + + + + Send gratuitous ARP request for specified address + + sudo /usr/bin/arping -I $5 -c 1 -U $7 + + + + Send specified number of ARP requests + + sudo /usr/bin/arping -I $5 -c $9 -U $7 + + + + + + + + + + Send ARP for DAD detection + + + + + Send ARP for DAD detection on specified interface + + + + + + + + Send ARP for DAD detection for specified address + + sudo /usr/bin/arping -I $5 -c 1 -D $7 + + + + + + + + + + + diff --git a/op-mode-definitions/force-ipv6-nd.xml b/op-mode-definitions/force-ipv6-nd.xml deleted file mode 100644 index 49de097f6..000000000 --- a/op-mode-definitions/force-ipv6-nd.xml +++ /dev/null @@ -1,33 +0,0 @@ - - - - - - - IPv6 Neighbor Discovery - - - - - IPv6 Neighbor Discovery on specified interface - - - - - - - - IPv6 address of node to lookup - - <h:h:h:h:h:h:h:h> - - - /usr/bin/ndisc6 -m "$6" "$4" - - - - - - - - diff --git a/op-mode-definitions/force-ipv6-nd.xml.in b/op-mode-definitions/force-ipv6-nd.xml.in new file mode 100644 index 000000000..49de097f6 --- /dev/null +++ b/op-mode-definitions/force-ipv6-nd.xml.in @@ -0,0 +1,33 @@ + + + + + + + IPv6 Neighbor Discovery + + + + + IPv6 Neighbor Discovery on specified interface + + + + + + + + IPv6 address of node to lookup + + <h:h:h:h:h:h:h:h> + + + /usr/bin/ndisc6 -m "$6" "$4" + + + + + + + + diff --git a/op-mode-definitions/force-ipv6-rd.xml b/op-mode-definitions/force-ipv6-rd.xml deleted file mode 100644 index 8c901af25..000000000 --- a/op-mode-definitions/force-ipv6-rd.xml +++ /dev/null @@ -1,34 +0,0 @@ - - - - - - - IPv6 Router Discovery - - - - - IPv6 Router Discovery on specified interface - - - - - /usr/bin/rdisc6 "$4" - - - - IPv6 address of target - - <h:h:h:h:h:h:h:h> - - - /usr/bin/rdisc6 -m "$6" "$4" - - - - - - - - diff --git a/op-mode-definitions/force-ipv6-rd.xml.in b/op-mode-definitions/force-ipv6-rd.xml.in new file mode 100644 index 000000000..8c901af25 --- /dev/null +++ b/op-mode-definitions/force-ipv6-rd.xml.in @@ -0,0 +1,34 @@ + + + + + + + IPv6 Router Discovery + + + + + IPv6 Router Discovery on specified interface + + + + + /usr/bin/rdisc6 "$4" + + + + IPv6 address of target + + <h:h:h:h:h:h:h:h> + + + /usr/bin/rdisc6 -m "$6" "$4" + + + + + + + + diff --git a/op-mode-definitions/force-mtu-host.xml b/op-mode-definitions/force-mtu-host.xml deleted file mode 100644 index b92179f11..000000000 --- a/op-mode-definitions/force-mtu-host.xml +++ /dev/null @@ -1,34 +0,0 @@ - - - - - - - Show MTU max value for remote host protocol TCP - - - - - IP address of the remote host - - <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> - - - ${vyos_op_scripts_dir}/force_mtu_host.sh $4 - - - - Source interface - - - - - ${vyos_op_scripts_dir}/force_mtu_host.sh $4 $6 - - - - - - - - diff --git a/op-mode-definitions/force-mtu-host.xml.in b/op-mode-definitions/force-mtu-host.xml.in new file mode 100644 index 000000000..b92179f11 --- /dev/null +++ b/op-mode-definitions/force-mtu-host.xml.in @@ -0,0 +1,34 @@ + + + + + + + Show MTU max value for remote host protocol TCP + + + + + IP address of the remote host + + <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> + + + ${vyos_op_scripts_dir}/force_mtu_host.sh $4 + + + + Source interface + + + + + ${vyos_op_scripts_dir}/force_mtu_host.sh $4 $6 + + + + + + + + diff --git a/op-mode-definitions/generate-macsec-key.xml b/op-mode-definitions/generate-macsec-key.xml deleted file mode 100644 index 40d2b9061..000000000 --- a/op-mode-definitions/generate-macsec-key.xml +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - Generate MACsec Key - - - - - Generate MACsec connectivity association key (CAK) - - /usr/bin/hexdump -n 16 -e '4/4 "%08x" 1 "\n"' /dev/random - - - - Generate MACsec connectivity association name (CKN) - - /usr/bin/hexdump -n 32 -e '8/4 "%08x" 1 "\n"' /dev/random - - - - - - diff --git a/op-mode-definitions/generate-macsec-key.xml.in b/op-mode-definitions/generate-macsec-key.xml.in new file mode 100644 index 000000000..40d2b9061 --- /dev/null +++ b/op-mode-definitions/generate-macsec-key.xml.in @@ -0,0 +1,26 @@ + + + + + + + Generate MACsec Key + + + + + Generate MACsec connectivity association key (CAK) + + /usr/bin/hexdump -n 16 -e '4/4 "%08x" 1 "\n"' /dev/random + + + + Generate MACsec connectivity association name (CKN) + + /usr/bin/hexdump -n 32 -e '8/4 "%08x" 1 "\n"' /dev/random + + + + + + diff --git a/op-mode-definitions/generate-ssh-server-key.xml b/op-mode-definitions/generate-ssh-server-key.xml deleted file mode 100644 index a6ebf1b78..000000000 --- a/op-mode-definitions/generate-ssh-server-key.xml +++ /dev/null @@ -1,16 +0,0 @@ - - - - - Generate an object - - - - - Regenerate the host SSH keys and restart the SSH server - - ${vyos_op_scripts_dir}/generate_ssh_server_key.py - - - - diff --git a/op-mode-definitions/generate-ssh-server-key.xml.in b/op-mode-definitions/generate-ssh-server-key.xml.in new file mode 100644 index 000000000..a6ebf1b78 --- /dev/null +++ b/op-mode-definitions/generate-ssh-server-key.xml.in @@ -0,0 +1,16 @@ + + + + + Generate an object + + + + + Regenerate the host SSH keys and restart the SSH server + + ${vyos_op_scripts_dir}/generate_ssh_server_key.py + + + + diff --git a/op-mode-definitions/igmp-proxy.xml b/op-mode-definitions/igmp-proxy.xml deleted file mode 100644 index 8533138d7..000000000 --- a/op-mode-definitions/igmp-proxy.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - Restart the IGMP proxy process - - sudo systemctl restart igmpproxy.service - - - - diff --git a/op-mode-definitions/igmp-proxy.xml.in b/op-mode-definitions/igmp-proxy.xml.in new file mode 100644 index 000000000..8533138d7 --- /dev/null +++ b/op-mode-definitions/igmp-proxy.xml.in @@ -0,0 +1,13 @@ + + + + + + + Restart the IGMP proxy process + + sudo systemctl restart igmpproxy.service + + + + diff --git a/op-mode-definitions/ipoe-server.xml b/op-mode-definitions/ipoe-server.xml deleted file mode 100644 index c20d3aa2a..000000000 --- a/op-mode-definitions/ipoe-server.xml +++ /dev/null @@ -1,81 +0,0 @@ - - - - - - - Clear ipoe-server sessions or process - - - - - Clear ipoe-server session - - - - - Clear ipoe-server session by username - - - - - ${vyos_op_scripts_dir}/ipoe-control.py --action="terminate" --selector="username" --target="$5" - - - - Clear ipoe-server session by Session ID - - - - - ${vyos_op_scripts_dir}/ipoe-control.py --action="terminate" --selector="sid" --target="$5" - - - - Clear ipoe-server session by interface - - - - - ${vyos_op_scripts_dir}/ipoe-control.py --action="terminate" --selector="if" --target="$5" - - - - - - - - - - - - show ipoe-server status - - - - - Show active IPoE server sessions - - ${vyos_op_scripts_dir}/ipoe-control.py --action="show_sessions" - - - - Show IPoE server statistics - - ${vyos_op_scripts_dir}/ipoe-control.py --action="show_stat" - - - - - - - - - - show ipoe-server status - - ${vyos_op_scripts_dir}/ipoe-control.py --action="restart" - - - - diff --git a/op-mode-definitions/ipoe-server.xml.in b/op-mode-definitions/ipoe-server.xml.in new file mode 100644 index 000000000..c20d3aa2a --- /dev/null +++ b/op-mode-definitions/ipoe-server.xml.in @@ -0,0 +1,81 @@ + + + + + + + Clear ipoe-server sessions or process + + + + + Clear ipoe-server session + + + + + Clear ipoe-server session by username + + + + + ${vyos_op_scripts_dir}/ipoe-control.py --action="terminate" --selector="username" --target="$5" + + + + Clear ipoe-server session by Session ID + + + + + ${vyos_op_scripts_dir}/ipoe-control.py --action="terminate" --selector="sid" --target="$5" + + + + Clear ipoe-server session by interface + + + + + ${vyos_op_scripts_dir}/ipoe-control.py --action="terminate" --selector="if" --target="$5" + + + + + + + + + + + + show ipoe-server status + + + + + Show active IPoE server sessions + + ${vyos_op_scripts_dir}/ipoe-control.py --action="show_sessions" + + + + Show IPoE server statistics + + ${vyos_op_scripts_dir}/ipoe-control.py --action="show_stat" + + + + + + + + + + show ipoe-server status + + ${vyos_op_scripts_dir}/ipoe-control.py --action="restart" + + + + diff --git a/op-mode-definitions/ipv4-route.xml b/op-mode-definitions/ipv4-route.xml deleted file mode 100644 index 1bda3ac11..000000000 --- a/op-mode-definitions/ipv4-route.xml +++ /dev/null @@ -1,87 +0,0 @@ - - - - - Show system information - - - - - Show IPv4 information - - - - - Show IP multicast group membership - - netstat -gn4 - - - - - - - - - Reset a service - - - - - Reset Internet Protocol (IP) parameters - - - - - Reset Address Resolution Protocol (ARP) cache - - - - - Reset ARP cache for an IPv4 address - - <x.x.x.x> - - - sudo /sbin/ip neigh flush to "$5" - - - - Reset ARP cache for interface - - - - - sudo /sbin/ip neigh flush dev "$5" - - - - - - - Reset IP route - - - - - Flush the kernel route cache - - sudo /sbin/ip route flush cache - - - - - Flush the kernel route cache for a given route - - <x.x.x.x> <x.x.x.x/x> - - - sudo /sbin/ip route flush cache "$5" - - - - - - - - diff --git a/op-mode-definitions/ipv4-route.xml.in b/op-mode-definitions/ipv4-route.xml.in new file mode 100644 index 000000000..1bda3ac11 --- /dev/null +++ b/op-mode-definitions/ipv4-route.xml.in @@ -0,0 +1,87 @@ + + + + + Show system information + + + + + Show IPv4 information + + + + + Show IP multicast group membership + + netstat -gn4 + + + + + + + + + Reset a service + + + + + Reset Internet Protocol (IP) parameters + + + + + Reset Address Resolution Protocol (ARP) cache + + + + + Reset ARP cache for an IPv4 address + + <x.x.x.x> + + + sudo /sbin/ip neigh flush to "$5" + + + + Reset ARP cache for interface + + + + + sudo /sbin/ip neigh flush dev "$5" + + + + + + + Reset IP route + + + + + Flush the kernel route cache + + sudo /sbin/ip route flush cache + + + + + Flush the kernel route cache for a given route + + <x.x.x.x> <x.x.x.x/x> + + + sudo /sbin/ip route flush cache "$5" + + + + + + + + diff --git a/op-mode-definitions/ipv6-route.xml b/op-mode-definitions/ipv6-route.xml deleted file mode 100644 index fbf6489ba..000000000 --- a/op-mode-definitions/ipv6-route.xml +++ /dev/null @@ -1,133 +0,0 @@ - - - - - Show system information - - - - - Show IPv6 routing information - - - - - Show IPv6 multicast group membership - - netstat -gn6 - - - - - Show IPv6 Neighbor Discovery (ND) information - - ip -f inet6 neigh list - - - - - Show IPv6 routes - - - - - Show kernel IPv6 route cache - - ip -s -f inet6 route list cache - - - - Show kernel IPv6 route cache for a given route - - <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> - - - ip -s -f inet6 route list cache $5 - - - - Show kernel IPv6 route table - - ip -f inet6 route list - - - - Show kernel IPv6 route table for a given route - - <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> - - - ip -s -f inet6 route list $5 - - - - - - - - - - - - Reset a service - - - - - Reset Internet Protocol version 6 (IPv6) parameters - - - - - Reset IPv6 Neighbor Discovery (ND) cache - - - - - Reset ND cache for an IPv6 address - - <h:h:h:h:h:h:h:h> - - - sudo ip -f inet6 neigh flush to "$5" - - - - Reset IPv6 ND cache for interface - - - - - sudo ip -f inet6 neigh flush dev "$5" - - - - - - - Reset IPv6 route - - - - - Flush the kernel IPv6 route cache - - sudo ip -f inet6 route flush cache - - - - - Flush the kernel IPv6 route cache for a given route - - <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> - - - sudo ip -f inet6 route flush cache "$5" - - - - - - - - diff --git a/op-mode-definitions/ipv6-route.xml.in b/op-mode-definitions/ipv6-route.xml.in new file mode 100644 index 000000000..fbf6489ba --- /dev/null +++ b/op-mode-definitions/ipv6-route.xml.in @@ -0,0 +1,133 @@ + + + + + Show system information + + + + + Show IPv6 routing information + + + + + Show IPv6 multicast group membership + + netstat -gn6 + + + + + Show IPv6 Neighbor Discovery (ND) information + + ip -f inet6 neigh list + + + + + Show IPv6 routes + + + + + Show kernel IPv6 route cache + + ip -s -f inet6 route list cache + + + + Show kernel IPv6 route cache for a given route + + <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> + + + ip -s -f inet6 route list cache $5 + + + + Show kernel IPv6 route table + + ip -f inet6 route list + + + + Show kernel IPv6 route table for a given route + + <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> + + + ip -s -f inet6 route list $5 + + + + + + + + + + + + Reset a service + + + + + Reset Internet Protocol version 6 (IPv6) parameters + + + + + Reset IPv6 Neighbor Discovery (ND) cache + + + + + Reset ND cache for an IPv6 address + + <h:h:h:h:h:h:h:h> + + + sudo ip -f inet6 neigh flush to "$5" + + + + Reset IPv6 ND cache for interface + + + + + sudo ip -f inet6 neigh flush dev "$5" + + + + + + + Reset IPv6 route + + + + + Flush the kernel IPv6 route cache + + sudo ip -f inet6 route flush cache + + + + + Flush the kernel IPv6 route cache for a given route + + <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> + + + sudo ip -f inet6 route flush cache "$5" + + + + + + + + diff --git a/op-mode-definitions/l2tp-server.xml b/op-mode-definitions/l2tp-server.xml deleted file mode 100644 index 3e96b9365..000000000 --- a/op-mode-definitions/l2tp-server.xml +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - Show L2TP server information - - - - - Show active L2TP server sessions - - ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="l2tp" --action="show sessions" - - - - Show L2TP server statistics - - ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="l2tp" --action="show stat" - - - - - - diff --git a/op-mode-definitions/l2tp-server.xml.in b/op-mode-definitions/l2tp-server.xml.in new file mode 100644 index 000000000..3e96b9365 --- /dev/null +++ b/op-mode-definitions/l2tp-server.xml.in @@ -0,0 +1,26 @@ + + + + + + + Show L2TP server information + + + + + Show active L2TP server sessions + + ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="l2tp" --action="show sessions" + + + + Show L2TP server statistics + + ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="l2tp" --action="show stat" + + + + + + diff --git a/op-mode-definitions/lldp.xml b/op-mode-definitions/lldp.xml deleted file mode 100644 index 297ccf1f4..000000000 --- a/op-mode-definitions/lldp.xml +++ /dev/null @@ -1,37 +0,0 @@ - - - - - - - Show LLDP (Link Layer Discovery Protocol) - - - - - Show LLDP neighbors - - ${vyos_op_scripts_dir}/lldp_op.py --all - - - - Show LLDP neighbor details - - ${vyos_op_scripts_dir}/lldp_op.py --detail - - - - Show LLDP for specified interface - - - - - ${vyos_op_scripts_dir}/lldp_op.py --interface $5 - - - - - - - - diff --git a/op-mode-definitions/lldp.xml.in b/op-mode-definitions/lldp.xml.in new file mode 100644 index 000000000..297ccf1f4 --- /dev/null +++ b/op-mode-definitions/lldp.xml.in @@ -0,0 +1,37 @@ + + + + + + + Show LLDP (Link Layer Discovery Protocol) + + + + + Show LLDP neighbors + + ${vyos_op_scripts_dir}/lldp_op.py --all + + + + Show LLDP neighbor details + + ${vyos_op_scripts_dir}/lldp_op.py --detail + + + + Show LLDP for specified interface + + + + + ${vyos_op_scripts_dir}/lldp_op.py --interface $5 + + + + + + + + diff --git a/op-mode-definitions/monitor-bandwidth-test.xml b/op-mode-definitions/monitor-bandwidth-test.xml deleted file mode 100644 index 5b36b1da5..000000000 --- a/op-mode-definitions/monitor-bandwidth-test.xml +++ /dev/null @@ -1,29 +0,0 @@ - - - - - - - Initiate or wait for bandwidth test - - - - - Wait for bandwidth test connections (port TCP/5001) - - /usr/bin/iperf -V -s - - - - Initiate a bandwidth test to specified host (port TCP/5001) - - <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> - - - ${vyos_op_scripts_dir}/monitor_bandwidth_test.sh "$4" - - - - - - diff --git a/op-mode-definitions/monitor-bandwidth-test.xml.in b/op-mode-definitions/monitor-bandwidth-test.xml.in new file mode 100644 index 000000000..5b36b1da5 --- /dev/null +++ b/op-mode-definitions/monitor-bandwidth-test.xml.in @@ -0,0 +1,29 @@ + + + + + + + Initiate or wait for bandwidth test + + + + + Wait for bandwidth test connections (port TCP/5001) + + /usr/bin/iperf -V -s + + + + Initiate a bandwidth test to specified host (port TCP/5001) + + <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> + + + ${vyos_op_scripts_dir}/monitor_bandwidth_test.sh "$4" + + + + + + diff --git a/op-mode-definitions/monitor-bandwidth.xml b/op-mode-definitions/monitor-bandwidth.xml deleted file mode 100644 index 9af0a9e70..000000000 --- a/op-mode-definitions/monitor-bandwidth.xml +++ /dev/null @@ -1,23 +0,0 @@ - - - - - - - Monitor interface bandwidth in real time - - - - bmon -b -p $4 - - Monitor bandwidth usage on specified interface - - - - - - - - - - diff --git a/op-mode-definitions/monitor-bandwidth.xml.in b/op-mode-definitions/monitor-bandwidth.xml.in new file mode 100644 index 000000000..9af0a9e70 --- /dev/null +++ b/op-mode-definitions/monitor-bandwidth.xml.in @@ -0,0 +1,23 @@ + + + + + + + Monitor interface bandwidth in real time + + + + bmon -b -p $4 + + Monitor bandwidth usage on specified interface + + + + + + + + + + diff --git a/op-mode-definitions/monitor-log.xml b/op-mode-definitions/monitor-log.xml deleted file mode 100644 index 99efe5306..000000000 --- a/op-mode-definitions/monitor-log.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - Monitor last lines of messages file - - tail --follow=name /var/log/messages - - - - diff --git a/op-mode-definitions/monitor-log.xml.in b/op-mode-definitions/monitor-log.xml.in new file mode 100644 index 000000000..99efe5306 --- /dev/null +++ b/op-mode-definitions/monitor-log.xml.in @@ -0,0 +1,13 @@ + + + + + + + Monitor last lines of messages file + + tail --follow=name /var/log/messages + + + + diff --git a/op-mode-definitions/monitor-ndp.xml b/op-mode-definitions/monitor-ndp.xml deleted file mode 100644 index 1ac6ce39b..000000000 --- a/op-mode-definitions/monitor-ndp.xml +++ /dev/null @@ -1,44 +0,0 @@ - - - - - - - Monitor the NDP information received by the router through the device - - sudo ndptool monitor - - - sudo ndptool monitor --ifname=$4 - - Monitor ndp protocol on specified interface - - - - - - - sudo ndptool monitor --ifname=$4 --msg-type=$6 - - Monitor specific types of NDP protocols - - rs ra ns na - - - - - - - sudo ndptool monitor --msg-type=$4 - - Monitor specific types of NDP protocols - - rs ra ns na - - - - - - - - diff --git a/op-mode-definitions/monitor-ndp.xml.in b/op-mode-definitions/monitor-ndp.xml.in new file mode 100644 index 000000000..1ac6ce39b --- /dev/null +++ b/op-mode-definitions/monitor-ndp.xml.in @@ -0,0 +1,44 @@ + + + + + + + Monitor the NDP information received by the router through the device + + sudo ndptool monitor + + + sudo ndptool monitor --ifname=$4 + + Monitor ndp protocol on specified interface + + + + + + + sudo ndptool monitor --ifname=$4 --msg-type=$6 + + Monitor specific types of NDP protocols + + rs ra ns na + + + + + + + sudo ndptool monitor --msg-type=$4 + + Monitor specific types of NDP protocols + + rs ra ns na + + + + + + + + diff --git a/op-mode-definitions/nat.xml b/op-mode-definitions/nat.xml deleted file mode 100644 index f6c0fa748..000000000 --- a/op-mode-definitions/nat.xml +++ /dev/null @@ -1,98 +0,0 @@ - - - - - - - Show Network Address Translation (NAT) information - - - - - Show source Network Address Translation (NAT) information - - - - - Show configured source NAT rules - - echo To be migrated to Python - https://phabricator.vyos.net/T2459 - - - - Show statistics for configured source NAT rules - - ${vyos_op_scripts_dir}/show_nat_statistics.py --source - - - - Show active source NAT translations - - - - - Show active source NAT translations for an IP address - - <x.x.x.x> - - - ${vyos_op_scripts_dir}/show_nat_translations.py --type=source --verbose --ipaddr="$6" - - - - Show active source NAT translations detail - - ${vyos_op_scripts_dir}/show_nat_translations.py --type=source --verbose - - - ${vyos_op_scripts_dir}/show_nat_translations.py --type=source - - - - - - Show destination Network Address Translation (NAT) information - - - - - Show configured destination NAT rules - - echo To be migrated to Python - https://phabricator.vyos.net/T2459 - - - - Show statistics for configured destination NAT rules - - ${vyos_op_scripts_dir}/show_nat_statistics.py --destination - - - - Show active destination NAT translations - - - - - Show active NAT destination translations for an IP address - - <x.x.x.x> - - - ${vyos_op_scripts_dir}/show_nat_translations.py --type=destination --verbose --ipaddr="$6" - - - - Show active destination NAT translations detail - - ${vyos_op_scripts_dir}/show_nat_translations.py --type=destination --verbose - - - ${vyos_op_scripts_dir}/show_nat_translations.py --type=destination - - - - - - - - diff --git a/op-mode-definitions/nat.xml.in b/op-mode-definitions/nat.xml.in new file mode 100644 index 000000000..4b09816f9 --- /dev/null +++ b/op-mode-definitions/nat.xml.in @@ -0,0 +1,98 @@ + + + + + + + Show Network Address Translation (NAT) information + + + + + Show source Network Address Translation (NAT) information + + + + + Show configured source NAT rules + + echo To be migrated to Python - Phabricator T2459 + + + + Show statistics for configured source NAT rules + + ${vyos_op_scripts_dir}/show_nat_statistics.py --source + + + + Show active source NAT translations + + + + + Show active source NAT translations for an IP address + + <x.x.x.x> + + + ${vyos_op_scripts_dir}/show_nat_translations.py --type=source --verbose --ipaddr="$6" + + + + Show active source NAT translations detail + + ${vyos_op_scripts_dir}/show_nat_translations.py --type=source --verbose + + + ${vyos_op_scripts_dir}/show_nat_translations.py --type=source + + + + + + Show destination Network Address Translation (NAT) information + + + + + Show configured destination NAT rules + + echo To be migrated to Python - Phabricator T2459 + + + + Show statistics for configured destination NAT rules + + ${vyos_op_scripts_dir}/show_nat_statistics.py --destination + + + + Show active destination NAT translations + + + + + Show active NAT destination translations for an IP address + + <x.x.x.x> + + + ${vyos_op_scripts_dir}/show_nat_translations.py --type=destination --verbose --ipaddr="$6" + + + + Show active destination NAT translations detail + + ${vyos_op_scripts_dir}/show_nat_translations.py --type=destination --verbose + + + ${vyos_op_scripts_dir}/show_nat_translations.py --type=destination + + + + + + + + diff --git a/op-mode-definitions/openconnect.xml b/op-mode-definitions/openconnect.xml deleted file mode 100644 index 9b82b114e..000000000 --- a/op-mode-definitions/openconnect.xml +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - - show openconnect-server information - - - - - Show active openconnect server sessions - - ${vyos_op_scripts_dir}/openconnect-control.py --action="show_sessions" - - - - - - diff --git a/op-mode-definitions/openconnect.xml.in b/op-mode-definitions/openconnect.xml.in new file mode 100644 index 000000000..9b82b114e --- /dev/null +++ b/op-mode-definitions/openconnect.xml.in @@ -0,0 +1,20 @@ + + + + + + + show openconnect-server information + + + + + Show active openconnect server sessions + + ${vyos_op_scripts_dir}/openconnect-control.py --action="show_sessions" + + + + + + diff --git a/op-mode-definitions/openvpn.xml b/op-mode-definitions/openvpn.xml deleted file mode 100644 index b9cb06dca..000000000 --- a/op-mode-definitions/openvpn.xml +++ /dev/null @@ -1,140 +0,0 @@ - - - - - - - OpenVPN key generation tool - - - - - Generate shared-secret key with specified file name - - <filename> - - - - result=1; - key_path=$4 - full_path= - - # Prepend /config/auth if the path is not absolute - if echo $key_path | egrep -ve '^/.*' > /dev/null; then - full_path=/config/auth/$key_path - else - full_path=$key_path - fi - - key_dir=`dirname $full_path` - if [ ! -d $key_dir ]; then - echo "Directory $key_dir does not exist!" - exit 1 - fi - - echo "Generating OpenVPN key to $full_path" - sudo /usr/sbin/openvpn --genkey --secret "$full_path" - result=$? - if [ $result = 0 ]; then - echo "Your new local OpenVPN key has been generated" - fi - /usr/libexec/vyos/validators/file-exists --directory /config/auth "$full_path" - - - - - - - - - Reset a service - - - - - - - Reset specified OpenVPN client - - - - - echo kill $4 | socat - UNIX-CONNECT:/run/openvpn/openvpn-mgmt-intf > /dev/null - - - - Reset OpenVPN process on interface - - - - - sudo ${vyos_op_scripts_dir}/reset_openvpn.py $4 - - - - - - - - - - - - Show OpenVPN interface information - - - - - Show detailed OpenVPN interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=openvpn --action=show - - - - - - Show OpenVPN interface information - - - - - ${vyos_op_scripts_dir}/show_interfaces.py --intf=$4 - - - - Show summary of specified OpenVPN interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief - - - - - - - - Show OpenVPN information - - - - - Show tunnel status for OpenVPN client interfaces - - sudo ${vyos_op_scripts_dir}/show_openvpn.py --mode=client - - - - Show tunnel status for OpenVPN server interfaces - - sudo ${vyos_op_scripts_dir}/show_openvpn.py --mode=server - - - - Show tunnel status for OpenVPN site-to-site interfaces - - sudo ${vyos_op_scripts_dir}/show_openvpn.py --mode=site-to-site - - - - - - diff --git a/op-mode-definitions/openvpn.xml.in b/op-mode-definitions/openvpn.xml.in new file mode 100644 index 000000000..e9420904a --- /dev/null +++ b/op-mode-definitions/openvpn.xml.in @@ -0,0 +1,139 @@ + + + + + + + OpenVPN key generation tool + + + + + Generate shared-secret key with specified file name + + <filename> + + + + result=1; + key_path=$4 + full_path= + + if echo $key_path | egrep -ve '^/.*' > /dev/null; then + full_path=/config/auth/$key_path + else + full_path=$key_path + fi + + key_dir=`dirname $full_path` + if [ ! -d $key_dir ]; then + echo "Directory $key_dir does not exist!" + exit 1 + fi + + echo "Generating OpenVPN key to $full_path" + sudo /usr/sbin/openvpn --genkey --secret "$full_path" + result=$? + if [ $result = 0 ]; then + echo "Your new local OpenVPN key has been generated" + fi + /usr/libexec/vyos/validators/file-exists --directory /config/auth "$full_path" + + + + + + + + + Reset a service + + + + + + + Reset specified OpenVPN client + + + + + echo kill $4 | socat - UNIX-CONNECT:/run/openvpn/openvpn-mgmt-intf > /dev/null + + + + Reset OpenVPN process on interface + + + + + sudo ${vyos_op_scripts_dir}/reset_openvpn.py $4 + + + + + + + + + + + + Show OpenVPN interface information + + + + + Show detailed OpenVPN interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=openvpn --action=show + + + + + + Show OpenVPN interface information + + + + + ${vyos_op_scripts_dir}/show_interfaces.py --intf=$4 + + + + Show summary of specified OpenVPN interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief + + + + + + + + Show OpenVPN information + + + + + Show tunnel status for OpenVPN client interfaces + + sudo ${vyos_op_scripts_dir}/show_openvpn.py --mode=client + + + + Show tunnel status for OpenVPN server interfaces + + sudo ${vyos_op_scripts_dir}/show_openvpn.py --mode=server + + + + Show tunnel status for OpenVPN site-to-site interfaces + + sudo ${vyos_op_scripts_dir}/show_openvpn.py --mode=site-to-site + + + + + + diff --git a/op-mode-definitions/ping.xml b/op-mode-definitions/ping.xml deleted file mode 100644 index 4c25a59ab..000000000 --- a/op-mode-definitions/ping.xml +++ /dev/null @@ -1,23 +0,0 @@ - - - - - Send Internet Control Message Protocol (ICMP) echo request - - <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> - - - ${vyos_op_scripts_dir}/ping.py ${@:2} - - - - Ping options - - - - - ${vyos_op_scripts_dir}/ping.py ${@:2} - - - - diff --git a/op-mode-definitions/ping.xml.in b/op-mode-definitions/ping.xml.in new file mode 100644 index 000000000..4c25a59ab --- /dev/null +++ b/op-mode-definitions/ping.xml.in @@ -0,0 +1,23 @@ + + + + + Send Internet Control Message Protocol (ICMP) echo request + + <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> + + + ${vyos_op_scripts_dir}/ping.py ${@:2} + + + + Ping options + + + + + ${vyos_op_scripts_dir}/ping.py ${@:2} + + + + diff --git a/op-mode-definitions/poweroff.xml b/op-mode-definitions/poweroff.xml deleted file mode 100644 index b4163bcb9..000000000 --- a/op-mode-definitions/poweroff.xml +++ /dev/null @@ -1,52 +0,0 @@ - - - - - Poweroff the system - - sudo ${vyos_op_scripts_dir}/powerctrl.py --poweroff - - - - Poweroff the system without confirmation - - sudo ${vyos_op_scripts_dir}/powerctrl.py --yes --poweroff - - - - Cancel a pending poweroff - - sudo ${vyos_op_scripts_dir}/powerctrl.py --cancel - - - - Poweroff in X minutes - - <Minutes> - - - sudo ${vyos_op_scripts_dir}/powerctrl.py --yes --poweroff $3 $4 - - - - Poweroff at a specific time - - <HH:MM> - - - sudo ${vyos_op_scripts_dir}/powerctrl.py --yes --poweroff $3 - - - - Poweroff at a specific date - - <DDMMYYYY> <DD/MM/YYYY> <DD.MM.YYYY> <DD:MM:YYYY> - - - sudo ${vyos_op_scripts_dir}/powerctrl.py --yes --poweroff $3 $5 - - - - - - diff --git a/op-mode-definitions/poweroff.xml.in b/op-mode-definitions/poweroff.xml.in new file mode 100644 index 000000000..b4163bcb9 --- /dev/null +++ b/op-mode-definitions/poweroff.xml.in @@ -0,0 +1,52 @@ + + + + + Poweroff the system + + sudo ${vyos_op_scripts_dir}/powerctrl.py --poweroff + + + + Poweroff the system without confirmation + + sudo ${vyos_op_scripts_dir}/powerctrl.py --yes --poweroff + + + + Cancel a pending poweroff + + sudo ${vyos_op_scripts_dir}/powerctrl.py --cancel + + + + Poweroff in X minutes + + <Minutes> + + + sudo ${vyos_op_scripts_dir}/powerctrl.py --yes --poweroff $3 $4 + + + + Poweroff at a specific time + + <HH:MM> + + + sudo ${vyos_op_scripts_dir}/powerctrl.py --yes --poweroff $3 + + + + Poweroff at a specific date + + <DDMMYYYY> <DD/MM/YYYY> <DD.MM.YYYY> <DD:MM:YYYY> + + + sudo ${vyos_op_scripts_dir}/powerctrl.py --yes --poweroff $3 $5 + + + + + + diff --git a/op-mode-definitions/pppoe-server.xml b/op-mode-definitions/pppoe-server.xml deleted file mode 100644 index 5ac9d9497..000000000 --- a/op-mode-definitions/pppoe-server.xml +++ /dev/null @@ -1,104 +0,0 @@ - - - - - - - Show pppoe-server status - - - - - Show active PPPoE server sessions - - ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="show sessions" - - - - Show PPPoE server statistics - - ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="show stat" - - - - Show interfaces where pppoe-server listens on - - ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="pppoe interface show" - - - - - - - - - - Restarts pppoe-server - - ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="restart" - - - - - - Reset a service - - - - - Reset PPPoE server sessions - - - - - Terminate all pppoe-server users - - ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="terminate all" - - - - Terminate a ppp interface - - ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="terminate if $4" - - - - Terminate specified users - - ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="terminate username $4" - - - - - - - - - - Set PPPoE server maintenance mode - - - - - Set PPPoE server maintenance mode - - - - - Deny new connections and stop to serve pppoe after disconnect last session - - ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="shutdown soft" - - - - Cancel maintenance mode - - ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="shutdown cancel" - - - - - - - - diff --git a/op-mode-definitions/pppoe-server.xml.in b/op-mode-definitions/pppoe-server.xml.in new file mode 100644 index 000000000..5ac9d9497 --- /dev/null +++ b/op-mode-definitions/pppoe-server.xml.in @@ -0,0 +1,104 @@ + + + + + + + Show pppoe-server status + + + + + Show active PPPoE server sessions + + ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="show sessions" + + + + Show PPPoE server statistics + + ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="show stat" + + + + Show interfaces where pppoe-server listens on + + ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="pppoe interface show" + + + + + + + + + + Restarts pppoe-server + + ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="restart" + + + + + + Reset a service + + + + + Reset PPPoE server sessions + + + + + Terminate all pppoe-server users + + ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="terminate all" + + + + Terminate a ppp interface + + ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="terminate if $4" + + + + Terminate specified users + + ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="terminate username $4" + + + + + + + + + + Set PPPoE server maintenance mode + + + + + Set PPPoE server maintenance mode + + + + + Deny new connections and stop to serve pppoe after disconnect last session + + ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="shutdown soft" + + + + Cancel maintenance mode + + ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pppoe" --action="shutdown cancel" + + + + + + + + diff --git a/op-mode-definitions/pptp-server.xml b/op-mode-definitions/pptp-server.xml deleted file mode 100644 index 59be68611..000000000 --- a/op-mode-definitions/pptp-server.xml +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - Show PPTP server information - - - - - Show active PPTP server sessions - - ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pptp" --action="show sessions" - - - - Show PPTP server statistics - - ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pptp" --action="show stat" - - - - - - diff --git a/op-mode-definitions/pptp-server.xml.in b/op-mode-definitions/pptp-server.xml.in new file mode 100644 index 000000000..59be68611 --- /dev/null +++ b/op-mode-definitions/pptp-server.xml.in @@ -0,0 +1,26 @@ + + + + + + + Show PPTP server information + + + + + Show active PPTP server sessions + + ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pptp" --action="show sessions" + + + + Show PPTP server statistics + + ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="pptp" --action="show stat" + + + + + + diff --git a/op-mode-definitions/reboot.xml b/op-mode-definitions/reboot.xml deleted file mode 100644 index 2c8daec5d..000000000 --- a/op-mode-definitions/reboot.xml +++ /dev/null @@ -1,52 +0,0 @@ - - - - - Reboot the system - - sudo ${vyos_op_scripts_dir}/powerctrl.py --reboot - - - - Reboot the system without confirmation - - sudo ${vyos_op_scripts_dir}/powerctrl.py --yes --reboot - - - - Cancel a pending reboot - - sudo ${vyos_op_scripts_dir}/powerctrl.py --cancel - - - - Reboot in X minutes - - <Minutes> - - - sudo ${vyos_op_scripts_dir}/powerctrl.py --yes --reboot $3 $4 - - - - Reboot at a specific time - - <HH:MM> - - - sudo ${vyos_op_scripts_dir}/powerctrl.py --yes --reboot $3 - - - - Reboot at a specific date - - <DDMMYYYY> <DD/MM/YYYY> <DD.MM.YYYY> <DD:MM:YYYY> - - - sudo ${vyos_op_scripts_dir}/powerctrl.py --yes --reboot $3 $5 - - - - - - diff --git a/op-mode-definitions/reboot.xml.in b/op-mode-definitions/reboot.xml.in new file mode 100644 index 000000000..2c8daec5d --- /dev/null +++ b/op-mode-definitions/reboot.xml.in @@ -0,0 +1,52 @@ + + + + + Reboot the system + + sudo ${vyos_op_scripts_dir}/powerctrl.py --reboot + + + + Reboot the system without confirmation + + sudo ${vyos_op_scripts_dir}/powerctrl.py --yes --reboot + + + + Cancel a pending reboot + + sudo ${vyos_op_scripts_dir}/powerctrl.py --cancel + + + + Reboot in X minutes + + <Minutes> + + + sudo ${vyos_op_scripts_dir}/powerctrl.py --yes --reboot $3 $4 + + + + Reboot at a specific time + + <HH:MM> + + + sudo ${vyos_op_scripts_dir}/powerctrl.py --yes --reboot $3 + + + + Reboot at a specific date + + <DDMMYYYY> <DD/MM/YYYY> <DD.MM.YYYY> <DD:MM:YYYY> + + + sudo ${vyos_op_scripts_dir}/powerctrl.py --yes --reboot $3 $5 + + + + + + diff --git a/op-mode-definitions/reset-conntrack.xml b/op-mode-definitions/reset-conntrack.xml deleted file mode 100644 index 827ba4af4..000000000 --- a/op-mode-definitions/reset-conntrack.xml +++ /dev/null @@ -1,16 +0,0 @@ - - - - - Reset a service - - - - - Reset all currently tracked connections - - sudo ${vyos_op_scripts_dir}/clear_conntrack.py - - - - diff --git a/op-mode-definitions/reset-conntrack.xml.in b/op-mode-definitions/reset-conntrack.xml.in new file mode 100644 index 000000000..827ba4af4 --- /dev/null +++ b/op-mode-definitions/reset-conntrack.xml.in @@ -0,0 +1,16 @@ + + + + + Reset a service + + + + + Reset all currently tracked connections + + sudo ${vyos_op_scripts_dir}/clear_conntrack.py + + + + diff --git a/op-mode-definitions/reset-ip-bgp.xml b/op-mode-definitions/reset-ip-bgp.xml deleted file mode 100644 index 931a2a9bc..000000000 --- a/op-mode-definitions/reset-ip-bgp.xml +++ /dev/null @@ -1,203 +0,0 @@ - - - - - - - - - Clear Border Gateway Protocol (BGP) statistics or status - - - - - Clear all BGP peering sessions - - vtysh -c "clear bgp ipv4 *" - - - - Clear BGP route flap dampening information - - vtysh -c "clear ip bgp dampening" - - - - Clear BGP route flap dampening information for given host|network address - - <x.x.x.x> <x.x.x.x/x> - - - vtysh -c "clear ip bgp dampening $5" - - - - Clear BGP route flap dampening information for given network address - - <x.x.x.x> - - - vtysh -c "clear ip bgp dampening $5 $6" - - - - - - Clear all external peers - - WORD - - - vtysh -c "clear bgp ipv4 external" - - - - Send route-refresh unless using 'soft-reconfiguration inbound' - - vtysh -c "clear bgp ipv4 external in" - - - - Push out prefix-list ORF and do inbound soft reconfig - - vtysh -c "clear bgp ipv4 external in prefix-filter" - - - - - - Resend all outbound updates - - vtysh -c "clear bgp ipv4 external out" - - - - Soft reconfig inbound and outbound updates - - vtysh -c "clear bgp ipv4 external soft" - - - - Clear via soft reconfig of inbound update - - vtysh -c "clear bgp ipv4 external soft in" - - - - Resend all outbound updates - - vtysh -c "clear bgp ipv4 external soft out" - - - - - - - - Clear BGP statistics or status for given peer-group - - WORD - - - vtysh -c "clear bgp ipv4 peer-group $5" - - - - Send route-refresh unless using 'soft-reconfiguration inbound' - - vtysh -c "clear bgp ipv4 peer-group $5 in" - - - - Push out prefix-list ORF and do inbound soft reconfig - - vtysh -c "clear bgp ipv4 peer-group $5 in prefix-filter" - - - - - - Resend all outbound updates - - vtysh -c "clear bgp ipv4 peer-group $5 out" - - - - Soft reconfig inbound and outbound updates - - vtysh -c "clear bgp ipv4 peer-group $5 soft" - - - - Clear via soft reconfig of inbound update - - vtysh -c "clear bgp ipv4 peer-group $5 soft in" - - - - Resend all outbound updates - - vtysh -c "clear bgp ipv4 peer-group $5 soft out" - - - - - - - - - - Clear BGP neighbor IP address - - - - - vtysh -c "clear bgp ipv4 $4" - - - - Send route-refresh unless using 'soft-reconfiguration inbound' - - vtysh -c "clear bgp ipv4 $4 in" - - - - Push out prefix-list ORF and do inbound soft reconfig - - vtysh -c "clear bgp ipv4 $4 in prefix-filter" - - - - - - Resend all outbound updates - - vtysh -c "clear bgp ipv4 $4 out" - - - - Soft reconfig inbound and outbound updates - - vtysh -c "clear bgp ipv4 $4 soft" - - - - Clear via soft reconfig of inbound update - - vtysh -c "clear bgp ipv4 $4 soft in" - - - - Resend all outbound updates - - vtysh -c "clear bgp ipv4 $4 soft out" - - - - - - - - - - diff --git a/op-mode-definitions/reset-ip-bgp.xml.in b/op-mode-definitions/reset-ip-bgp.xml.in new file mode 100644 index 000000000..931a2a9bc --- /dev/null +++ b/op-mode-definitions/reset-ip-bgp.xml.in @@ -0,0 +1,203 @@ + + + + + + + + + Clear Border Gateway Protocol (BGP) statistics or status + + + + + Clear all BGP peering sessions + + vtysh -c "clear bgp ipv4 *" + + + + Clear BGP route flap dampening information + + vtysh -c "clear ip bgp dampening" + + + + Clear BGP route flap dampening information for given host|network address + + <x.x.x.x> <x.x.x.x/x> + + + vtysh -c "clear ip bgp dampening $5" + + + + Clear BGP route flap dampening information for given network address + + <x.x.x.x> + + + vtysh -c "clear ip bgp dampening $5 $6" + + + + + + Clear all external peers + + WORD + + + vtysh -c "clear bgp ipv4 external" + + + + Send route-refresh unless using 'soft-reconfiguration inbound' + + vtysh -c "clear bgp ipv4 external in" + + + + Push out prefix-list ORF and do inbound soft reconfig + + vtysh -c "clear bgp ipv4 external in prefix-filter" + + + + + + Resend all outbound updates + + vtysh -c "clear bgp ipv4 external out" + + + + Soft reconfig inbound and outbound updates + + vtysh -c "clear bgp ipv4 external soft" + + + + Clear via soft reconfig of inbound update + + vtysh -c "clear bgp ipv4 external soft in" + + + + Resend all outbound updates + + vtysh -c "clear bgp ipv4 external soft out" + + + + + + + + Clear BGP statistics or status for given peer-group + + WORD + + + vtysh -c "clear bgp ipv4 peer-group $5" + + + + Send route-refresh unless using 'soft-reconfiguration inbound' + + vtysh -c "clear bgp ipv4 peer-group $5 in" + + + + Push out prefix-list ORF and do inbound soft reconfig + + vtysh -c "clear bgp ipv4 peer-group $5 in prefix-filter" + + + + + + Resend all outbound updates + + vtysh -c "clear bgp ipv4 peer-group $5 out" + + + + Soft reconfig inbound and outbound updates + + vtysh -c "clear bgp ipv4 peer-group $5 soft" + + + + Clear via soft reconfig of inbound update + + vtysh -c "clear bgp ipv4 peer-group $5 soft in" + + + + Resend all outbound updates + + vtysh -c "clear bgp ipv4 peer-group $5 soft out" + + + + + + + + + + Clear BGP neighbor IP address + + + + + vtysh -c "clear bgp ipv4 $4" + + + + Send route-refresh unless using 'soft-reconfiguration inbound' + + vtysh -c "clear bgp ipv4 $4 in" + + + + Push out prefix-list ORF and do inbound soft reconfig + + vtysh -c "clear bgp ipv4 $4 in prefix-filter" + + + + + + Resend all outbound updates + + vtysh -c "clear bgp ipv4 $4 out" + + + + Soft reconfig inbound and outbound updates + + vtysh -c "clear bgp ipv4 $4 soft" + + + + Clear via soft reconfig of inbound update + + vtysh -c "clear bgp ipv4 $4 soft in" + + + + Resend all outbound updates + + vtysh -c "clear bgp ipv4 $4 soft out" + + + + + + + + + + diff --git a/op-mode-definitions/reset-ip-igmp.xml b/op-mode-definitions/reset-ip-igmp.xml deleted file mode 100644 index 143553d33..000000000 --- a/op-mode-definitions/reset-ip-igmp.xml +++ /dev/null @@ -1,24 +0,0 @@ - - - - - - - - - IGMP clear commands - - - - - Reset IGMP interfaces - - /usr/bin/vtysh -c "clear ip igmp interfaces" - - - - - - - - diff --git a/op-mode-definitions/reset-ip-igmp.xml.in b/op-mode-definitions/reset-ip-igmp.xml.in new file mode 100644 index 000000000..143553d33 --- /dev/null +++ b/op-mode-definitions/reset-ip-igmp.xml.in @@ -0,0 +1,24 @@ + + + + + + + + + IGMP clear commands + + + + + Reset IGMP interfaces + + /usr/bin/vtysh -c "clear ip igmp interfaces" + + + + + + + + diff --git a/op-mode-definitions/reset-ip-multicast.xml b/op-mode-definitions/reset-ip-multicast.xml deleted file mode 100644 index d610add16..000000000 --- a/op-mode-definitions/reset-ip-multicast.xml +++ /dev/null @@ -1,24 +0,0 @@ - - - - - - - - - IP multicast routing table - - - - - Clear multicast routing table - - /usr/bin/vtysh -c "clear ip mroute" - - - - - - - - diff --git a/op-mode-definitions/reset-ip-multicast.xml.in b/op-mode-definitions/reset-ip-multicast.xml.in new file mode 100644 index 000000000..d610add16 --- /dev/null +++ b/op-mode-definitions/reset-ip-multicast.xml.in @@ -0,0 +1,24 @@ + + + + + + + + + IP multicast routing table + + + + + Clear multicast routing table + + /usr/bin/vtysh -c "clear ip mroute" + + + + + + + + diff --git a/op-mode-definitions/reset-ipv6-bgp.xml b/op-mode-definitions/reset-ipv6-bgp.xml deleted file mode 100644 index 3c4275331..000000000 --- a/op-mode-definitions/reset-ipv6-bgp.xml +++ /dev/null @@ -1,62 +0,0 @@ - - - - - - - - - Clear BGP neighbor IP address - - - - - vtysh -c "clear bgp ipv6 $4" - - - - Send route-refresh unless using 'soft-reconfiguration inbound' - - vtysh -c "clear bgp ipv6 $4 in" - - - - Push out prefix-list ORF and do inbound soft reconfig - - vtysh -c "clear bgp ipv6 $4 in prefix-filter" - - - - - - Resend all outbound updates - - vtysh -c "clear bgp ipv6 $4 out" - - - - Soft reconfig inbound and outbound updates - - vtysh -c "clear bgp ipv6 $4 soft" - - - - Clear via soft reconfig of inbound update - - vtysh -c "clear bgp ipv6 $4 soft in" - - - - Resend all outbound updates - - vtysh -c "clear bgp ipv6 $4 soft out" - - - - - - - - - - diff --git a/op-mode-definitions/reset-ipv6-bgp.xml.in b/op-mode-definitions/reset-ipv6-bgp.xml.in new file mode 100644 index 000000000..3c4275331 --- /dev/null +++ b/op-mode-definitions/reset-ipv6-bgp.xml.in @@ -0,0 +1,62 @@ + + + + + + + + + Clear BGP neighbor IP address + + + + + vtysh -c "clear bgp ipv6 $4" + + + + Send route-refresh unless using 'soft-reconfiguration inbound' + + vtysh -c "clear bgp ipv6 $4 in" + + + + Push out prefix-list ORF and do inbound soft reconfig + + vtysh -c "clear bgp ipv6 $4 in prefix-filter" + + + + + + Resend all outbound updates + + vtysh -c "clear bgp ipv6 $4 out" + + + + Soft reconfig inbound and outbound updates + + vtysh -c "clear bgp ipv6 $4 soft" + + + + Clear via soft reconfig of inbound update + + vtysh -c "clear bgp ipv6 $4 soft in" + + + + Resend all outbound updates + + vtysh -c "clear bgp ipv6 $4 soft out" + + + + + + + + + + diff --git a/op-mode-definitions/reset-mpls.xml b/op-mode-definitions/reset-mpls.xml deleted file mode 100644 index 4e5d37d5b..000000000 --- a/op-mode-definitions/reset-mpls.xml +++ /dev/null @@ -1,31 +0,0 @@ - - - - - - - Reset MPLS and related protocol commands - - - - - Reset LDP commands - - - - - Reset MPLS LDP neighbor/session - - <x.x.x.x> <h:h:h:h:h:h:h:h> - - - - /usr/bin/vtysh -c "clear mpls ldp neighbor $5" - - - - - - - - \ No newline at end of file diff --git a/op-mode-definitions/reset-mpls.xml.in b/op-mode-definitions/reset-mpls.xml.in new file mode 100644 index 000000000..4e5d37d5b --- /dev/null +++ b/op-mode-definitions/reset-mpls.xml.in @@ -0,0 +1,31 @@ + + + + + + + Reset MPLS and related protocol commands + + + + + Reset LDP commands + + + + + Reset MPLS LDP neighbor/session + + <x.x.x.x> <h:h:h:h:h:h:h:h> + + + + /usr/bin/vtysh -c "clear mpls ldp neighbor $5" + + + + + + + + \ No newline at end of file diff --git a/op-mode-definitions/reset-vpn.xml b/op-mode-definitions/reset-vpn.xml deleted file mode 100644 index ae553c272..000000000 --- a/op-mode-definitions/reset-vpn.xml +++ /dev/null @@ -1,96 +0,0 @@ - - - - - Reset a service - - - - - Reset Virtual Private Network (VPN) information - - - - - Reset remote access VPN connections - - - - - Terminate all user's current remote access VPN session(s) - - - - - Terminate specified user's current remote access VPN session(s) with specified protocol - - - - - Terminate all user's current remote access VPN session(s) with L2TP protocol - - sudo ${vyos_op_scripts_dir}/reset_vpn.py --username="all_users" --protocol="l2tp" - - - - Terminate all user's current remote access VPN session(s) with PPTP protocol - - sudo ${vyos_op_scripts_dir}/reset_vpn.py --username="all_users" --protocol="pptp" - - - - Terminate all user's current remote access VPN session(s) with SSTP protocol - - sudo ${vyos_op_scripts_dir}/reset_vpn.py --username="all_users" --protocol="sstp" - - - - - sudo ${vyos_op_scripts_dir}/reset_vpn.py --username="all_users" - - - - Terminate a remote access VPN interface - - sudo ${vyos_op_scripts_dir}/reset_vpn.py --interface="$5" - - - - Terminate specified user's current remote access VPN session(s) - - - - - Terminate specified user's current remote access VPN session(s) with specified protocol - - - - - Terminate all user's current remote access VPN session(s) with L2TP protocol - - sudo ${vyos_op_scripts_dir}/reset_vpn.py --username="$5" --protocol="l2tp" - - - - Terminate all user's current remote access VPN session(s) with PPTP protocol - - sudo ${vyos_op_scripts_dir}/reset_vpn.py --username="$5" --protocol="pptp" - - - - Terminate all user's current remote access VPN session(s) with SSTP protocol - - sudo ${vyos_op_scripts_dir}/reset_vpn.py --username="$5" --protocol="sstp" - - - - - sudo ${vyos_op_scripts_dir}/reset_vpn.py --username="$5" - - - - - - - - diff --git a/op-mode-definitions/reset-vpn.xml.in b/op-mode-definitions/reset-vpn.xml.in new file mode 100644 index 000000000..71dbb4ed9 --- /dev/null +++ b/op-mode-definitions/reset-vpn.xml.in @@ -0,0 +1,96 @@ + + + + + Reset a service + + + + + Reset Virtual Private Network (VPN) information + + + + + Reset remote access VPN connections + + + + + Terminate all users current remote access VPN session(s) + + + + + Terminate specified users current remote access VPN session(s) with specified protocol + + + + + Terminate all users current remote access VPN session(s) with L2TP protocol + + sudo ${vyos_op_scripts_dir}/reset_vpn.py --username="all_users" --protocol="l2tp" + + + + Terminate all users current remote access VPN session(s) with PPTP protocol + + sudo ${vyos_op_scripts_dir}/reset_vpn.py --username="all_users" --protocol="pptp" + + + + Terminate all users current remote access VPN session(s) with SSTP protocol + + sudo ${vyos_op_scripts_dir}/reset_vpn.py --username="all_users" --protocol="sstp" + + + + + sudo ${vyos_op_scripts_dir}/reset_vpn.py --username="all_users" + + + + Terminate a remote access VPN interface + + sudo ${vyos_op_scripts_dir}/reset_vpn.py --interface="$5" + + + + Terminate specified users current remote access VPN session(s) + + + + + Terminate specified users current remote access VPN session(s) with specified protocol + + + + + Terminate all users current remote access VPN session(s) with L2TP protocol + + sudo ${vyos_op_scripts_dir}/reset_vpn.py --username="$5" --protocol="l2tp" + + + + Terminate all users current remote access VPN session(s) with PPTP protocol + + sudo ${vyos_op_scripts_dir}/reset_vpn.py --username="$5" --protocol="pptp" + + + + Terminate all users current remote access VPN session(s) with SSTP protocol + + sudo ${vyos_op_scripts_dir}/reset_vpn.py --username="$5" --protocol="sstp" + + + + + sudo ${vyos_op_scripts_dir}/reset_vpn.py --username="$5" + + + + + + + + diff --git a/op-mode-definitions/restart-frr.xml b/op-mode-definitions/restart-frr.xml deleted file mode 100644 index 96ad1a650..000000000 --- a/op-mode-definitions/restart-frr.xml +++ /dev/null @@ -1,63 +0,0 @@ - - - - - - - Restart FRRouting daemons - - sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart - - - - Restart Bidirectional Forwarding Detection daemon - - sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon bfdd - - - - Restart Border Gateway Protocol daemon - - sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon bgpd - - - - Restart OSPFv2 daemon - - sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon ospfd - - - - Restart OSPFv3 daemon - - sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon ospf6d - - - - Restart Routing Information Protocol daemon - - sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon ripd - - - - Restart RIPng daemon - - sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon ripngd - - - - Restart Static Route daemon - - sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon staticd - - - - Restart IP routing manager daemon - - sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon zebra - - - - - - diff --git a/op-mode-definitions/restart-frr.xml.in b/op-mode-definitions/restart-frr.xml.in new file mode 100644 index 000000000..96ad1a650 --- /dev/null +++ b/op-mode-definitions/restart-frr.xml.in @@ -0,0 +1,63 @@ + + + + + + + Restart FRRouting daemons + + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart + + + + Restart Bidirectional Forwarding Detection daemon + + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon bfdd + + + + Restart Border Gateway Protocol daemon + + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon bgpd + + + + Restart OSPFv2 daemon + + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon ospfd + + + + Restart OSPFv3 daemon + + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon ospf6d + + + + Restart Routing Information Protocol daemon + + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon ripd + + + + Restart RIPng daemon + + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon ripngd + + + + Restart Static Route daemon + + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon staticd + + + + Restart IP routing manager daemon + + sudo ${vyos_op_scripts_dir}/restart_frr.py --action restart --daemon zebra + + + + + + diff --git a/op-mode-definitions/restart.xml b/op-mode-definitions/restart.xml deleted file mode 100644 index c74ec9013..000000000 --- a/op-mode-definitions/restart.xml +++ /dev/null @@ -1,8 +0,0 @@ - - - - - Restart individual service - - - diff --git a/op-mode-definitions/restart.xml.in b/op-mode-definitions/restart.xml.in new file mode 100644 index 000000000..c74ec9013 --- /dev/null +++ b/op-mode-definitions/restart.xml.in @@ -0,0 +1,8 @@ + + + + + Restart individual service + + + diff --git a/op-mode-definitions/show-acceleration.xml b/op-mode-definitions/show-acceleration.xml deleted file mode 100644 index d0dcea2d6..000000000 --- a/op-mode-definitions/show-acceleration.xml +++ /dev/null @@ -1,63 +0,0 @@ - - - - - - - Show system information - - - - - Acceleration components - - - - - Intel QAT (Quick Assist Technology) Devices - - - - - Show QAT information for a given acceleration device - - - - - - - - Intel QAT flows - - ${vyos_op_scripts_dir}/show_acceleration.py --flow --dev $6 - - - - Intel QAT configuration - - ${vyos_op_scripts_dir}/show_acceleration.py --conf --dev $6 - - - - - - Intel QAT status - - ${vyos_op_scripts_dir}/show_acceleration.py --status - - - - Intel QAT interrupts - - ${vyos_op_scripts_dir}/show_acceleration.py --interrupts - - - ${vyos_op_scripts_dir}/show_acceleration.py --hw - - - - - - - - diff --git a/op-mode-definitions/show-acceleration.xml.in b/op-mode-definitions/show-acceleration.xml.in new file mode 100644 index 000000000..d0dcea2d6 --- /dev/null +++ b/op-mode-definitions/show-acceleration.xml.in @@ -0,0 +1,63 @@ + + + + + + + Show system information + + + + + Acceleration components + + + + + Intel QAT (Quick Assist Technology) Devices + + + + + Show QAT information for a given acceleration device + + + + + + + + Intel QAT flows + + ${vyos_op_scripts_dir}/show_acceleration.py --flow --dev $6 + + + + Intel QAT configuration + + ${vyos_op_scripts_dir}/show_acceleration.py --conf --dev $6 + + + + + + Intel QAT status + + ${vyos_op_scripts_dir}/show_acceleration.py --status + + + + Intel QAT interrupts + + ${vyos_op_scripts_dir}/show_acceleration.py --interrupts + + + ${vyos_op_scripts_dir}/show_acceleration.py --hw + + + + + + + + diff --git a/op-mode-definitions/show-bridge.xml b/op-mode-definitions/show-bridge.xml deleted file mode 100644 index 8c1f7c398..000000000 --- a/op-mode-definitions/show-bridge.xml +++ /dev/null @@ -1,36 +0,0 @@ - - - - - - - Show bridging information - - /sbin/brctl show - - - - Show bridge information for a given bridge interface - - - - - /sbin/brctl show $3 - - - - Show bridge Media Access Control (MAC) address table - - /sbin/brctl showmacs $3 - - - - Show bridge spanning tree information - - /sbin/brctl showstp $3 - - - - - - diff --git a/op-mode-definitions/show-bridge.xml.in b/op-mode-definitions/show-bridge.xml.in new file mode 100644 index 000000000..8c1f7c398 --- /dev/null +++ b/op-mode-definitions/show-bridge.xml.in @@ -0,0 +1,36 @@ + + + + + + + Show bridging information + + /sbin/brctl show + + + + Show bridge information for a given bridge interface + + + + + /sbin/brctl show $3 + + + + Show bridge Media Access Control (MAC) address table + + /sbin/brctl showmacs $3 + + + + Show bridge spanning tree information + + /sbin/brctl showstp $3 + + + + + + diff --git a/op-mode-definitions/show-configuration.xml b/op-mode-definitions/show-configuration.xml deleted file mode 100644 index 318942ab0..000000000 --- a/op-mode-definitions/show-configuration.xml +++ /dev/null @@ -1,37 +0,0 @@ - - - - - - - Show available saved configurations - - - cli-shell-api showCfg --show-active-only --show-hide-secrets - - - - Show running configuration (including default values) - - - cli-shell-api showCfg --show-show-defaults --show-active-only --show-hide-secrets - - - - Show running configuration as set commands - - - cli-shell-api showCfg --show-active-only | vyos-config-to-commands - - - - Show available saved configurations - - - ${vyos_op_scripts_dir}/show_configuration_files.sh - - - - - - diff --git a/op-mode-definitions/show-configuration.xml.in b/op-mode-definitions/show-configuration.xml.in new file mode 100644 index 000000000..318942ab0 --- /dev/null +++ b/op-mode-definitions/show-configuration.xml.in @@ -0,0 +1,37 @@ + + + + + + + Show available saved configurations + + + cli-shell-api showCfg --show-active-only --show-hide-secrets + + + + Show running configuration (including default values) + + + cli-shell-api showCfg --show-show-defaults --show-active-only --show-hide-secrets + + + + Show running configuration as set commands + + + cli-shell-api showCfg --show-active-only | vyos-config-to-commands + + + + Show available saved configurations + + + ${vyos_op_scripts_dir}/show_configuration_files.sh + + + + + + diff --git a/op-mode-definitions/show-console-server.xml b/op-mode-definitions/show-console-server.xml deleted file mode 100644 index 77a7f3376..000000000 --- a/op-mode-definitions/show-console-server.xml +++ /dev/null @@ -1,36 +0,0 @@ - - - - - - - - - Show log for serial console server - - /usr/bin/journalctl -u conserver-server.service - - - - - - Show Console-Server information - - - - - Examine console ports and configured baud rates - - /usr/bin/console -x - - - - Show users on various consoles - - /usr/bin/console -u - - - - - - diff --git a/op-mode-definitions/show-console-server.xml.in b/op-mode-definitions/show-console-server.xml.in new file mode 100644 index 000000000..77a7f3376 --- /dev/null +++ b/op-mode-definitions/show-console-server.xml.in @@ -0,0 +1,36 @@ + + + + + + + + + Show log for serial console server + + /usr/bin/journalctl -u conserver-server.service + + + + + + Show Console-Server information + + + + + Examine console ports and configured baud rates + + /usr/bin/console -x + + + + Show users on various consoles + + /usr/bin/console -u + + + + + + diff --git a/op-mode-definitions/show-environment.xml b/op-mode-definitions/show-environment.xml deleted file mode 100644 index 95b658785..000000000 --- a/op-mode-definitions/show-environment.xml +++ /dev/null @@ -1,21 +0,0 @@ - - - - - - - Show current system environmental conditions - - - - - Show hardware monitoring results - - - if ! grep -q hypervisor /proc/cpuinfo; then ${vyos_libexec_dir}/vyos-sudo.py ${vyos_op_scripts_dir}/show_sensors.py; else echo "VyOS running under hypervisor, no sensors available"; fi - - - - - - diff --git a/op-mode-definitions/show-environment.xml.in b/op-mode-definitions/show-environment.xml.in new file mode 100644 index 000000000..95b658785 --- /dev/null +++ b/op-mode-definitions/show-environment.xml.in @@ -0,0 +1,21 @@ + + + + + + + Show current system environmental conditions + + + + + Show hardware monitoring results + + + if ! grep -q hypervisor /proc/cpuinfo; then ${vyos_libexec_dir}/vyos-sudo.py ${vyos_op_scripts_dir}/show_sensors.py; else echo "VyOS running under hypervisor, no sensors available"; fi + + + + + + diff --git a/op-mode-definitions/show-hardware.xml b/op-mode-definitions/show-hardware.xml deleted file mode 100644 index c3ff3a60f..000000000 --- a/op-mode-definitions/show-hardware.xml +++ /dev/null @@ -1,94 +0,0 @@ - - - - - - - Show system hardware details - - - - - Show CPU info - - lscpu - - - - Show system CPU details - - cat /proc/cpuinfo - - - - Show CPU's on system - - ${vyos_op_scripts_dir}/cpu_summary.py - - - - - - Show system DMI details - - ${vyatta_bindir}/vyatta-show-dmi - - - - Show system RAM details - - cat /proc/meminfo - - - - Show system PCI bus details - - lspci - - - - Show verbose system PCI bus details - - lspci -vvv - - - - - - Show SCSI device information - - lsscsi - - - - Show detailed SCSI device information - - lsscsi -vvv - - - - - - Show peripherals connected to the USB bus - - /usr/bin/lsusb -t - - - - Show detailed USB bus information - - /usr/bin/lsusb -v - - - - Show information about connected USB serial ports - - ${vyos_op_scripts_dir}/show_usb_serial.py - - - - - - - - diff --git a/op-mode-definitions/show-hardware.xml.in b/op-mode-definitions/show-hardware.xml.in new file mode 100644 index 000000000..0df2e4404 --- /dev/null +++ b/op-mode-definitions/show-hardware.xml.in @@ -0,0 +1,94 @@ + + + + + + + Show system hardware details + + + + + Show CPU info + + lscpu + + + + Show system CPU details + + cat /proc/cpuinfo + + + + Show system CPUs + + ${vyos_op_scripts_dir}/cpu_summary.py + + + + + + Show system DMI details + + ${vyatta_bindir}/vyatta-show-dmi + + + + Show system RAM details + + cat /proc/meminfo + + + + Show system PCI bus details + + lspci + + + + Show verbose system PCI bus details + + lspci -vvv + + + + + + Show SCSI device information + + lsscsi + + + + Show detailed SCSI device information + + lsscsi -vvv + + + + + + Show peripherals connected to the USB bus + + /usr/bin/lsusb -t + + + + Show detailed USB bus information + + /usr/bin/lsusb -v + + + + Show information about connected USB serial ports + + ${vyos_op_scripts_dir}/show_usb_serial.py + + + + + + + + diff --git a/op-mode-definitions/show-history.xml b/op-mode-definitions/show-history.xml deleted file mode 100644 index 7fb286264..000000000 --- a/op-mode-definitions/show-history.xml +++ /dev/null @@ -1,31 +0,0 @@ - - - - - - - Show command history - - HISTTIMEFORMAT='%FT%T%z ' HISTFILE="$HOME/.bash_history" \set -o history; history - - - - Show recent command history - - HISTTIMEFORMAT='%FT%T%z ' HISTFILE="$HOME/.bash_history" \set -o history; history 20 - - - - - - - Show last N commands in history - - <NUMBER> - - - HISTTIMEFORMAT='%FT%T%z ' HISTFILE="$HOME/.bash_history" \set -o history; history $3 - - - - diff --git a/op-mode-definitions/show-history.xml.in b/op-mode-definitions/show-history.xml.in new file mode 100644 index 000000000..7fb286264 --- /dev/null +++ b/op-mode-definitions/show-history.xml.in @@ -0,0 +1,31 @@ + + + + + + + Show command history + + HISTTIMEFORMAT='%FT%T%z ' HISTFILE="$HOME/.bash_history" \set -o history; history + + + + Show recent command history + + HISTTIMEFORMAT='%FT%T%z ' HISTFILE="$HOME/.bash_history" \set -o history; history 20 + + + + + + + Show last N commands in history + + <NUMBER> + + + HISTTIMEFORMAT='%FT%T%z ' HISTFILE="$HOME/.bash_history" \set -o history; history $3 + + + + diff --git a/op-mode-definitions/show-host.xml b/op-mode-definitions/show-host.xml deleted file mode 100644 index eee1288a1..000000000 --- a/op-mode-definitions/show-host.xml +++ /dev/null @@ -1,44 +0,0 @@ - - - - - - - Show host information - - - - - Show host current date - - /bin/date - - - - Show domain name - - /bin/domainname -d - - - - Show host name - - /bin/hostname - - - - Lookup host information for hostname|IPv4 address - - /usr/bin/host $4 - - - - Show host operating system details - - /bin/uname -a - - - - - - diff --git a/op-mode-definitions/show-host.xml.in b/op-mode-definitions/show-host.xml.in new file mode 100644 index 000000000..eee1288a1 --- /dev/null +++ b/op-mode-definitions/show-host.xml.in @@ -0,0 +1,44 @@ + + + + + + + Show host information + + + + + Show host current date + + /bin/date + + + + Show domain name + + /bin/domainname -d + + + + Show host name + + /bin/hostname + + + + Lookup host information for hostname|IPv4 address + + /usr/bin/host $4 + + + + Show host operating system details + + /bin/uname -a + + + + + + diff --git a/op-mode-definitions/show-interfaces-bonding.xml b/op-mode-definitions/show-interfaces-bonding.xml deleted file mode 100644 index f6d9b3508..000000000 --- a/op-mode-definitions/show-interfaces-bonding.xml +++ /dev/null @@ -1,71 +0,0 @@ - - - - - - - - - Show bonding interface information - - interfaces bonding - - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" - - - - Show summary of the specified bonding interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief - - - - Show detailed interface information - - if [ -f "/proc/net/bonding/$4" ]; then cat "/proc/net/bonding/$4"; else echo "Interface $4 does not exist!"; fi - - - - Show specified virtual network interface (vif) information - - interfaces bonding ${COMP_WORDS[3]} vif - - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4.$6" - - - - Show summary of specified virtual network interface (vif) information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4.$6" --action=show-brief - - - - - - Show eXpress Data Path statistics - - sudo ${vyos_op_scripts_dir}/show_xdp_stats.sh bonding "$4" - - - - - - Show bonding interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=bonding --action=show-brief - - - - Show detailed bonding interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=bonding --action=show - - - - - - - - diff --git a/op-mode-definitions/show-interfaces-bonding.xml.in b/op-mode-definitions/show-interfaces-bonding.xml.in new file mode 100644 index 000000000..f6d9b3508 --- /dev/null +++ b/op-mode-definitions/show-interfaces-bonding.xml.in @@ -0,0 +1,71 @@ + + + + + + + + + Show bonding interface information + + interfaces bonding + + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" + + + + Show summary of the specified bonding interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief + + + + Show detailed interface information + + if [ -f "/proc/net/bonding/$4" ]; then cat "/proc/net/bonding/$4"; else echo "Interface $4 does not exist!"; fi + + + + Show specified virtual network interface (vif) information + + interfaces bonding ${COMP_WORDS[3]} vif + + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4.$6" + + + + Show summary of specified virtual network interface (vif) information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4.$6" --action=show-brief + + + + + + Show eXpress Data Path statistics + + sudo ${vyos_op_scripts_dir}/show_xdp_stats.sh bonding "$4" + + + + + + Show bonding interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=bonding --action=show-brief + + + + Show detailed bonding interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=bonding --action=show + + + + + + + + diff --git a/op-mode-definitions/show-interfaces-bridge.xml b/op-mode-definitions/show-interfaces-bridge.xml deleted file mode 100644 index cc4b248b6..000000000 --- a/op-mode-definitions/show-interfaces-bridge.xml +++ /dev/null @@ -1,48 +0,0 @@ - - - - - - - - - Show bridge interface information - - interfaces bridge - - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" - - - - Show summary of the specified bridge interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief - - - - - - Show bridge interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=bridge --action=show-brief - - - - Show detailed bridge interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=bridge --action=show - - - - View the VLAN filter settings of the bridge - - /usr/sbin/bridge -c vlan show - - - - - - - - diff --git a/op-mode-definitions/show-interfaces-bridge.xml.in b/op-mode-definitions/show-interfaces-bridge.xml.in new file mode 100644 index 000000000..cc4b248b6 --- /dev/null +++ b/op-mode-definitions/show-interfaces-bridge.xml.in @@ -0,0 +1,48 @@ + + + + + + + + + Show bridge interface information + + interfaces bridge + + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" + + + + Show summary of the specified bridge interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief + + + + + + Show bridge interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=bridge --action=show-brief + + + + Show detailed bridge interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=bridge --action=show + + + + View the VLAN filter settings of the bridge + + /usr/sbin/bridge -c vlan show + + + + + + + + diff --git a/op-mode-definitions/show-interfaces-dummy.xml b/op-mode-definitions/show-interfaces-dummy.xml deleted file mode 100644 index 7c24c6921..000000000 --- a/op-mode-definitions/show-interfaces-dummy.xml +++ /dev/null @@ -1,42 +0,0 @@ - - - - - - - - - Show dummy interface information - - interfaces dummy - - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" - - - - Show summary of the specified dummy interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief - - - - - - Show dummy interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=dummy --action=show-brief - - - - Show detailed dummy interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=dummy --action=show - - - - - - - - diff --git a/op-mode-definitions/show-interfaces-dummy.xml.in b/op-mode-definitions/show-interfaces-dummy.xml.in new file mode 100644 index 000000000..7c24c6921 --- /dev/null +++ b/op-mode-definitions/show-interfaces-dummy.xml.in @@ -0,0 +1,42 @@ + + + + + + + + + Show dummy interface information + + interfaces dummy + + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" + + + + Show summary of the specified dummy interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief + + + + + + Show dummy interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=dummy --action=show-brief + + + + Show detailed dummy interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=dummy --action=show + + + + + + + + diff --git a/op-mode-definitions/show-interfaces-ethernet.xml b/op-mode-definitions/show-interfaces-ethernet.xml deleted file mode 100644 index fc79f44bf..000000000 --- a/op-mode-definitions/show-interfaces-ethernet.xml +++ /dev/null @@ -1,97 +0,0 @@ - - - - - - - - - Show ethernet interface information - - interfaces ethernet - - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" - - - - Show summary of the specified ethernet interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief - - - - Visually identify specified ethernet interface - - echo "Blinking interface $4 for 30 seconds."; /sbin/ethtool --identify "$4" 30 - - - - Show physical device information for specified ethernet interface - - /sbin/ethtool "$4"; /sbin/ethtool -i "$4" - - - - Show physical device offloading capabilities - - /sbin/ethtool -k "$4" | sed -e 1d -e '/fixed/d' -e 's/^\t*//g' -e 's/://' | column -t -s' ' - - - - - - Show physical device statistics for specified ethernet interface - - /sbin/ethtool -S "$4" - - - - Show transceiver information from modules (e.g SFP+, QSFP) - - /sbin/ethtool -m "$4" - - - - Show specified virtual network interface (vif) information - - interfaces ethernet ${COMP_WORDS[3]} vif - - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4.$6" - - - - Show summary of specified virtual network interface (vif) information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4.$6" --action=show-brief - - - - - - Show eXpress Data Path statistics - - sudo ${vyos_op_scripts_dir}/show_xdp_stats.sh ethernet "$4" - - - - - - Show ethernet interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=ethernet --action=show-brief - - - - Show detailed ethernet interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=ethernet --action=show - - - - - - - - diff --git a/op-mode-definitions/show-interfaces-ethernet.xml.in b/op-mode-definitions/show-interfaces-ethernet.xml.in new file mode 100644 index 000000000..fc79f44bf --- /dev/null +++ b/op-mode-definitions/show-interfaces-ethernet.xml.in @@ -0,0 +1,97 @@ + + + + + + + + + Show ethernet interface information + + interfaces ethernet + + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" + + + + Show summary of the specified ethernet interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief + + + + Visually identify specified ethernet interface + + echo "Blinking interface $4 for 30 seconds."; /sbin/ethtool --identify "$4" 30 + + + + Show physical device information for specified ethernet interface + + /sbin/ethtool "$4"; /sbin/ethtool -i "$4" + + + + Show physical device offloading capabilities + + /sbin/ethtool -k "$4" | sed -e 1d -e '/fixed/d' -e 's/^\t*//g' -e 's/://' | column -t -s' ' + + + + + + Show physical device statistics for specified ethernet interface + + /sbin/ethtool -S "$4" + + + + Show transceiver information from modules (e.g SFP+, QSFP) + + /sbin/ethtool -m "$4" + + + + Show specified virtual network interface (vif) information + + interfaces ethernet ${COMP_WORDS[3]} vif + + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4.$6" + + + + Show summary of specified virtual network interface (vif) information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4.$6" --action=show-brief + + + + + + Show eXpress Data Path statistics + + sudo ${vyos_op_scripts_dir}/show_xdp_stats.sh ethernet "$4" + + + + + + Show ethernet interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=ethernet --action=show-brief + + + + Show detailed ethernet interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=ethernet --action=show + + + + + + + + diff --git a/op-mode-definitions/show-interfaces-input.xml b/op-mode-definitions/show-interfaces-input.xml deleted file mode 100644 index 15e8203e5..000000000 --- a/op-mode-definitions/show-interfaces-input.xml +++ /dev/null @@ -1,42 +0,0 @@ - - - - - - - - - Show input interface information - - interfaces input - - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" - - - - Show summary of the specified input interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief - - - - - - Show input interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=input --action=show-brief - - - - Show detailed input interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=input --action=show - - - - - - - - diff --git a/op-mode-definitions/show-interfaces-input.xml.in b/op-mode-definitions/show-interfaces-input.xml.in new file mode 100644 index 000000000..15e8203e5 --- /dev/null +++ b/op-mode-definitions/show-interfaces-input.xml.in @@ -0,0 +1,42 @@ + + + + + + + + + Show input interface information + + interfaces input + + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" + + + + Show summary of the specified input interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief + + + + + + Show input interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=input --action=show-brief + + + + Show detailed input interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=input --action=show + + + + + + + + diff --git a/op-mode-definitions/show-interfaces-l2tpv3.xml b/op-mode-definitions/show-interfaces-l2tpv3.xml deleted file mode 100644 index 60fee34a1..000000000 --- a/op-mode-definitions/show-interfaces-l2tpv3.xml +++ /dev/null @@ -1,42 +0,0 @@ - - - - - - - - - Show L2TPv3 interface information - - interfaces l2tpv3 - - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" - - - - Show summary of the specified L2TPv3 interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief - - - - - - Show L2TPv3 interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=l2tpv3 --action=show-brief - - - - Show detailed L2TPv3 interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=l2tpv3 --action=show - - - - - - - - diff --git a/op-mode-definitions/show-interfaces-l2tpv3.xml.in b/op-mode-definitions/show-interfaces-l2tpv3.xml.in new file mode 100644 index 000000000..60fee34a1 --- /dev/null +++ b/op-mode-definitions/show-interfaces-l2tpv3.xml.in @@ -0,0 +1,42 @@ + + + + + + + + + Show L2TPv3 interface information + + interfaces l2tpv3 + + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" + + + + Show summary of the specified L2TPv3 interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief + + + + + + Show L2TPv3 interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=l2tpv3 --action=show-brief + + + + Show detailed L2TPv3 interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=l2tpv3 --action=show + + + + + + + + diff --git a/op-mode-definitions/show-interfaces-loopback.xml b/op-mode-definitions/show-interfaces-loopback.xml deleted file mode 100644 index b30b57909..000000000 --- a/op-mode-definitions/show-interfaces-loopback.xml +++ /dev/null @@ -1,42 +0,0 @@ - - - - - - - - - Show loopback interface information - - interfaces loopback - - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" - - - - Show summary of the specified dummy interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief - - - - - - Show loopback interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=loopback --action=show-brief - - - - Show detailed dummy interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=dummy --action=show - - - - - - - - diff --git a/op-mode-definitions/show-interfaces-loopback.xml.in b/op-mode-definitions/show-interfaces-loopback.xml.in new file mode 100644 index 000000000..b30b57909 --- /dev/null +++ b/op-mode-definitions/show-interfaces-loopback.xml.in @@ -0,0 +1,42 @@ + + + + + + + + + Show loopback interface information + + interfaces loopback + + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" + + + + Show summary of the specified dummy interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief + + + + + + Show loopback interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=loopback --action=show-brief + + + + Show detailed dummy interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=dummy --action=show + + + + + + + + diff --git a/op-mode-definitions/show-interfaces-macsec.xml b/op-mode-definitions/show-interfaces-macsec.xml deleted file mode 100644 index 6aeab66af..000000000 --- a/op-mode-definitions/show-interfaces-macsec.xml +++ /dev/null @@ -1,29 +0,0 @@ - - - - - - - - - Show MACsec interface information - - interfaces macsec - - - /usr/sbin/ip macsec show - - - - Show specified MACsec interface information - - interfaces macsec - - - /usr/sbin/ip macsec show $4 - - - - - - diff --git a/op-mode-definitions/show-interfaces-macsec.xml.in b/op-mode-definitions/show-interfaces-macsec.xml.in new file mode 100644 index 000000000..6aeab66af --- /dev/null +++ b/op-mode-definitions/show-interfaces-macsec.xml.in @@ -0,0 +1,29 @@ + + + + + + + + + Show MACsec interface information + + interfaces macsec + + + /usr/sbin/ip macsec show + + + + Show specified MACsec interface information + + interfaces macsec + + + /usr/sbin/ip macsec show $4 + + + + + + diff --git a/op-mode-definitions/show-interfaces-pppoe.xml b/op-mode-definitions/show-interfaces-pppoe.xml deleted file mode 100644 index 393ca912f..000000000 --- a/op-mode-definitions/show-interfaces-pppoe.xml +++ /dev/null @@ -1,51 +0,0 @@ - - - - - - - - - Show PPPoE interface information - - interfaces pppoe - - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" - - - - Show specified PPPoE interface log - - /usr/bin/journalctl -u "ppp@$4".service - - - - Show specified PPPoE interface statistics - - interfaces pppoe - - - if [ -d "/sys/class/net/$4" ]; then /usr/sbin/pppstats "$4"; fi - - - - - - Show PPPoE interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=pppoe --action=show-brief - - - - Show detailed PPPoE interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=pppoe --action=show - - - - - - - - diff --git a/op-mode-definitions/show-interfaces-pppoe.xml.in b/op-mode-definitions/show-interfaces-pppoe.xml.in new file mode 100644 index 000000000..393ca912f --- /dev/null +++ b/op-mode-definitions/show-interfaces-pppoe.xml.in @@ -0,0 +1,51 @@ + + + + + + + + + Show PPPoE interface information + + interfaces pppoe + + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" + + + + Show specified PPPoE interface log + + /usr/bin/journalctl -u "ppp@$4".service + + + + Show specified PPPoE interface statistics + + interfaces pppoe + + + if [ -d "/sys/class/net/$4" ]; then /usr/sbin/pppstats "$4"; fi + + + + + + Show PPPoE interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=pppoe --action=show-brief + + + + Show detailed PPPoE interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=pppoe --action=show + + + + + + + + diff --git a/op-mode-definitions/show-interfaces-pseudo-ethernet.xml b/op-mode-definitions/show-interfaces-pseudo-ethernet.xml deleted file mode 100644 index 195944745..000000000 --- a/op-mode-definitions/show-interfaces-pseudo-ethernet.xml +++ /dev/null @@ -1,42 +0,0 @@ - - - - - - - - - Show pseudo-ethernet/MACvlan interface information - - interfaces pseudo-ethernet - - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" - - - - Show summary of the specified pseudo-ethernet/MACvlan interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief - - - - - - Show pseudo-ethernet/MACvlan interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=pseudo-ethernet --action=show-brief - - - - Show detailed pseudo-ethernet/MACvlan interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=pseudo-ethernet --action=show - - - - - - - - diff --git a/op-mode-definitions/show-interfaces-pseudo-ethernet.xml.in b/op-mode-definitions/show-interfaces-pseudo-ethernet.xml.in new file mode 100644 index 000000000..195944745 --- /dev/null +++ b/op-mode-definitions/show-interfaces-pseudo-ethernet.xml.in @@ -0,0 +1,42 @@ + + + + + + + + + Show pseudo-ethernet/MACvlan interface information + + interfaces pseudo-ethernet + + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" + + + + Show summary of the specified pseudo-ethernet/MACvlan interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief + + + + + + Show pseudo-ethernet/MACvlan interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=pseudo-ethernet --action=show-brief + + + + Show detailed pseudo-ethernet/MACvlan interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=pseudo-ethernet --action=show + + + + + + + + diff --git a/op-mode-definitions/show-interfaces-tunnel.xml b/op-mode-definitions/show-interfaces-tunnel.xml deleted file mode 100644 index 416de0299..000000000 --- a/op-mode-definitions/show-interfaces-tunnel.xml +++ /dev/null @@ -1,42 +0,0 @@ - - - - - - - - - Show tunnel interface information - - interfaces tunnel - - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" - - - - Show summary of the specified tunnel interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief - - - - - - Show tunnel interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=tunnel --action=show-brief - - - - Show detailed tunnel interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=tunnel --action=show - - - - - - - - diff --git a/op-mode-definitions/show-interfaces-tunnel.xml.in b/op-mode-definitions/show-interfaces-tunnel.xml.in new file mode 100644 index 000000000..416de0299 --- /dev/null +++ b/op-mode-definitions/show-interfaces-tunnel.xml.in @@ -0,0 +1,42 @@ + + + + + + + + + Show tunnel interface information + + interfaces tunnel + + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" + + + + Show summary of the specified tunnel interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief + + + + + + Show tunnel interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=tunnel --action=show-brief + + + + Show detailed tunnel interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=tunnel --action=show + + + + + + + + diff --git a/op-mode-definitions/show-interfaces-vti.xml b/op-mode-definitions/show-interfaces-vti.xml deleted file mode 100644 index f51be2d19..000000000 --- a/op-mode-definitions/show-interfaces-vti.xml +++ /dev/null @@ -1,42 +0,0 @@ - - - - - - - - - Show vti interface information - - interfaces vti - - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" - - - - Show summary of the specified vti interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief - - - - - - Show vti interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=vti --action=show-brief - - - - Show detailed vti interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=vti --action=show - - - - - - - - diff --git a/op-mode-definitions/show-interfaces-vti.xml.in b/op-mode-definitions/show-interfaces-vti.xml.in new file mode 100644 index 000000000..f51be2d19 --- /dev/null +++ b/op-mode-definitions/show-interfaces-vti.xml.in @@ -0,0 +1,42 @@ + + + + + + + + + Show vti interface information + + interfaces vti + + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" + + + + Show summary of the specified vti interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief + + + + + + Show vti interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=vti --action=show-brief + + + + Show detailed vti interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=vti --action=show + + + + + + + + diff --git a/op-mode-definitions/show-interfaces-vxlan.xml b/op-mode-definitions/show-interfaces-vxlan.xml deleted file mode 100644 index 4e3cb93cd..000000000 --- a/op-mode-definitions/show-interfaces-vxlan.xml +++ /dev/null @@ -1,42 +0,0 @@ - - - - - - - - - Show VXLAN interface information - - interfaces vxlan - - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" - - - - Show summary of the specified VXLAN interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief - - - - - - Show VXLAN interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=vxlan --action=show-brief - - - - Show detailed VXLAN interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=vxlan --action=show - - - - - - - - diff --git a/op-mode-definitions/show-interfaces-vxlan.xml.in b/op-mode-definitions/show-interfaces-vxlan.xml.in new file mode 100644 index 000000000..4e3cb93cd --- /dev/null +++ b/op-mode-definitions/show-interfaces-vxlan.xml.in @@ -0,0 +1,42 @@ + + + + + + + + + Show VXLAN interface information + + interfaces vxlan + + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" + + + + Show summary of the specified VXLAN interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief + + + + + + Show VXLAN interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=vxlan --action=show-brief + + + + Show detailed VXLAN interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=vxlan --action=show + + + + + + + + diff --git a/op-mode-definitions/show-interfaces-wirelessmodem.xml b/op-mode-definitions/show-interfaces-wirelessmodem.xml deleted file mode 100644 index c0ab9c66f..000000000 --- a/op-mode-definitions/show-interfaces-wirelessmodem.xml +++ /dev/null @@ -1,51 +0,0 @@ - - - - - - - - - Show Wireless Modem (WWAN) interface information - - interfaces wirelessmodem - - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" - - - - Show specified WWAN interface log - - /usr/bin/journalctl -u "ppp@$4".service - - - - Show specified WWAN interface statistics - - interfaces wirelessmodem - - - if [ -d "/sys/class/net/$4" ]; then /usr/sbin/pppstats "$4"; fi - - - - - - Show Wireless Modem (WWAN) interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=wirelessmodem --action=show-brief - - - - Show detailed Wireless Modem (WWAN( interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=wirelessmodem --action=show - - - - - - - - diff --git a/op-mode-definitions/show-interfaces-wirelessmodem.xml.in b/op-mode-definitions/show-interfaces-wirelessmodem.xml.in new file mode 100644 index 000000000..c0ab9c66f --- /dev/null +++ b/op-mode-definitions/show-interfaces-wirelessmodem.xml.in @@ -0,0 +1,51 @@ + + + + + + + + + Show Wireless Modem (WWAN) interface information + + interfaces wirelessmodem + + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" + + + + Show specified WWAN interface log + + /usr/bin/journalctl -u "ppp@$4".service + + + + Show specified WWAN interface statistics + + interfaces wirelessmodem + + + if [ -d "/sys/class/net/$4" ]; then /usr/sbin/pppstats "$4"; fi + + + + + + Show Wireless Modem (WWAN) interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=wirelessmodem --action=show-brief + + + + Show detailed Wireless Modem (WWAN( interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=wirelessmodem --action=show + + + + + + + + diff --git a/op-mode-definitions/show-interfaces.xml b/op-mode-definitions/show-interfaces.xml deleted file mode 100644 index 39b0f0a2c..000000000 --- a/op-mode-definitions/show-interfaces.xml +++ /dev/null @@ -1,27 +0,0 @@ - - - - - - - Show network interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --action=show-brief - - - - Show network interface counters - - ${vyos_op_scripts_dir}/show_interfaces.py --action=show-count - - - - Show detailed information of all interfaces - - ${vyos_op_scripts_dir}/show_interfaces.py --action=show - - - - - - diff --git a/op-mode-definitions/show-interfaces.xml.in b/op-mode-definitions/show-interfaces.xml.in new file mode 100644 index 000000000..39b0f0a2c --- /dev/null +++ b/op-mode-definitions/show-interfaces.xml.in @@ -0,0 +1,27 @@ + + + + + + + Show network interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --action=show-brief + + + + Show network interface counters + + ${vyos_op_scripts_dir}/show_interfaces.py --action=show-count + + + + Show detailed information of all interfaces + + ${vyos_op_scripts_dir}/show_interfaces.py --action=show + + + + + + diff --git a/op-mode-definitions/show-ip-access-paths-prefix-community-lists.xml b/op-mode-definitions/show-ip-access-paths-prefix-community-lists.xml deleted file mode 100644 index a5ec65c94..000000000 --- a/op-mode-definitions/show-ip-access-paths-prefix-community-lists.xml +++ /dev/null @@ -1,116 +0,0 @@ - - - - - - - Show IPv4 routing information - - - - - Show all IP access-lists - - /usr/bin/vtysh -c "show ip access-list" - - - - Show all IP access-lists - - policy access-list - - - /usr/bin/vtysh -c "show ip access-list $4" - - - - Show all as-path-access-lists - - /usr/bin/vtysh -c "show ip as-path-access-list" - - - - Show all as-path-access-lists - - policy as-path-list - - - /usr/bin/vtysh -c "show ip as-path-access-list $4" - - - - Show IP community-lists - - /usr/bin/vtysh -c "show bgp community-list" - - - - Show IP community-lists - - policy community-list - - - /usr/bin/vtysh -c "show bgp community-list $4 detail" - - - - Show extended IP community-lists - - /usr/bin/vtysh -c "show bgp extcommunity-list" - - - - Show extended IP community-lists - - policy extcommunity-list - - - /usr/bin/vtysh -c "show bgp extcommunity-list $4 detail" - - - - Show IP forwarding status - - /usr/bin/vtysh -c "show ip forwarding" - - - - Show IP large-community-lists - - /usr/bin/vtysh -c "show bgp large-community-list" - - - - Show IP large-community-lists - - policy large-community-list - - - /usr/bin/vtysh -c "show bgp large-community-list $4 detail" - - - - Show all IP prefix-lists - - /usr/bin/vtysh -c "show ip prefix-list" - - - - Show all IP prefix-lists - - policy prefix-list - - - /usr/bin/vtysh -c "show ip prefix-list $4" - - - - Show IP route-maps per protocol - - /usr/bin/vtysh -c "show ip protocol" - - - - - - diff --git a/op-mode-definitions/show-ip-access-paths-prefix-community-lists.xml.in b/op-mode-definitions/show-ip-access-paths-prefix-community-lists.xml.in new file mode 100644 index 000000000..a5ec65c94 --- /dev/null +++ b/op-mode-definitions/show-ip-access-paths-prefix-community-lists.xml.in @@ -0,0 +1,116 @@ + + + + + + + Show IPv4 routing information + + + + + Show all IP access-lists + + /usr/bin/vtysh -c "show ip access-list" + + + + Show all IP access-lists + + policy access-list + + + /usr/bin/vtysh -c "show ip access-list $4" + + + + Show all as-path-access-lists + + /usr/bin/vtysh -c "show ip as-path-access-list" + + + + Show all as-path-access-lists + + policy as-path-list + + + /usr/bin/vtysh -c "show ip as-path-access-list $4" + + + + Show IP community-lists + + /usr/bin/vtysh -c "show bgp community-list" + + + + Show IP community-lists + + policy community-list + + + /usr/bin/vtysh -c "show bgp community-list $4 detail" + + + + Show extended IP community-lists + + /usr/bin/vtysh -c "show bgp extcommunity-list" + + + + Show extended IP community-lists + + policy extcommunity-list + + + /usr/bin/vtysh -c "show bgp extcommunity-list $4 detail" + + + + Show IP forwarding status + + /usr/bin/vtysh -c "show ip forwarding" + + + + Show IP large-community-lists + + /usr/bin/vtysh -c "show bgp large-community-list" + + + + Show IP large-community-lists + + policy large-community-list + + + /usr/bin/vtysh -c "show bgp large-community-list $4 detail" + + + + Show all IP prefix-lists + + /usr/bin/vtysh -c "show ip prefix-list" + + + + Show all IP prefix-lists + + policy prefix-list + + + /usr/bin/vtysh -c "show ip prefix-list $4" + + + + Show IP route-maps per protocol + + /usr/bin/vtysh -c "show ip protocol" + + + + + + diff --git a/op-mode-definitions/show-ip-bgp.xml b/op-mode-definitions/show-ip-bgp.xml deleted file mode 100644 index 5eb2ae56e..000000000 --- a/op-mode-definitions/show-ip-bgp.xml +++ /dev/null @@ -1,342 +0,0 @@ - - - - - - - - - Show Border Gateway Protocol (BGP) information - - /usr/bin/vtysh -c "show ip bgp" - - - - Show BGP attribute information - - /usr/bin/vtysh -c "show ip bgp attribute-info" - - - - Display only routes with non-natural netmasks - - /usr/bin/vtysh -c "show ip bgp cidr-only" - - - - Show BGP routes matching the communities - - /usr/bin/vtysh -c "show ip bgp community" - - - - Display routes matching the specified communities - - <AA:NN> local-AS no-advertise no-export - - - /usr/bin/vtysh -c "show ip bgp community $5" - - - - List all bgp community information - - /usr/bin/vtysh -c "show ip bgp community-info" - - - - Show BGP routes matching specified community list - - /usr/bin/vtysh -c "show ip bgp community-list $5" - - - - Show BGP routes exactly matching specified community list - - /usr/bin/vtysh -c "show ip bgp community-list $5 exact-match" - - - - - - Show dampened BGP paths - - /usr/bin/vtysh -c "show ip bgp dampening dampened-paths" - - - - Show BGP information for specified word - - /usr/bin/vtysh -c "show ip bgp filter-list $5" - - - - Show flap statistics of routes - - /usr/bin/vtysh -c "show ip bgp dampening flap-statistics" - - - - Show BGP IPv4 information - - - - - Show BGP IPv4 unicast information - - - - - Display only routes with non-natural netmasks - - /usr/bin/vtysh -c "show ip bgp ipv4 unicast cidr-only" - - - - Show BGP routes matching the communities - - /usr/bin/vtysh -c "show ip bgp ipv4 unicast community" - - - - Display routes matching the specified communities - - <AA:NN> local-AS no-advertise no-export - - - /usr/bin/vtysh -c "show ip bgp ipv4 unicast community $7" - - - - Show BGP routes matching specified community list - - /usr/bin/vtysh -c "show ip bgp ipv4 unicast community-list $7" - - - - Show BGP routes exactly matching specified community list - - /usr/bin/vtysh -c "show ip bgp ipv4 unicast community-list $7 exact-match" - - - - - - Show BGP information for specified word - - /usr/bin/vtysh -c "show ip bgp filter-list $5" - - - - Show detailed BGP IPv4 unicast neighbor information - - - - - /usr/bin/vtysh -c "show ip bgp ipv4 unicast neighbors $7" - - - - Show routes advertised to a BGP neighbor - - /usr/bin/vtysh -c "show ip bgp ipv4 unicast neighbor $7 advertised-routes" - - - - Show detailed prefix count information - - /usr/bin/vtysh -c "show ip bgp ipv4 unicast neighbor $7 prefix-counts" - - - - Show the received routes from neighbor - - /usr/bin/vtysh -c "show ip bgp ipv4 unicast neighbor $7 received-routes" - - - - Show routes learned from neighbor - - /usr/bin/vtysh -c "show ip bgp ipv4 unicast neighbor $7 routes" - - - - - - Show BGP path information - - /usr/bin/vtysh -c "show ip bgp ipv4 unicast paths" - - - - Show BGP routes matching the specified prefix list - - /usr/bin/vtysh -c "show ip bgp ipv4 unicast prefix-list $7" - - - - Show BGP routes matching the specified AS path regular expression - - /usr/bin/vtysh -c "show ip bgp ipv4 unicast regexp $5" - - - - Show BGP routes matching the specified route map - - /usr/bin/vtysh -c "show ip bgp route-map $5" - - - - Show summary of BGP information - - /usr/bin/vtysh -c "show ip bgp summary" - - - - - - Show BGP information for specified IP address or prefix - - <x.x.x.x> <x.x.x.x/x> - - - /usr/bin/vtysh -c "show ip bgp $6" - - - - - - Show BGP routes matching the specified large-communities - - /usr/bin/vtysh -c "show ip bgp large-community" - - - - Show BGP large-community information - - /usr/bin/vtysh -c "show ip bgp large-community-info" - - - - Show BGP routes matching the specified large-community list - - /usr/bin/vtysh -c "show ip bgp large-community-list $5" - - - - Show BGP memory usage - - /usr/bin/vtysh -c "show ip bgp memory" - - - - Show detailed BGP IPv4 unicast neighbor information - - - - - /usr/bin/vtysh -c "show ip bgp neighbors $5" - - - - Show routes advertised to a BGP neighbor - - /usr/bin/vtysh -c "show ip bgp neighbor $5 advertised-routes" - - - - Show dampened routes received from BGP neighbor - - /usr/bin/vtysh -c "show ip bgp neighbor $5 dampened-routes" - - - - Show flap statistics of the routes learned from BGP neighbor - - /usr/bin/vtysh -c "show ip bgp neighbor $5 flap-statistics" - - - - Show detailed prefix count information for BGP neighbor - - /usr/bin/vtysh -c "show ip bgp neighbor $5 prefix-counts" - - - - Show information received from BGP neighbor - - - - - Show prefixlist filter - - /usr/bin/vtysh -c "show ip bgp neighbor $5 received prefix-filter" - - - - - - Show received routes from BGP neighbor - - /usr/bin/vtysh -c "show ip bgp neighbor $5 received-routes" - - - - Show routes learned from BGP neighbor - - /usr/bin/vtysh -c "show ip bgp neighbor $5 routes" - - - - - - Show BGP path information - - /usr/bin/vtysh -c "show ip bgp paths" - - - - Show BGP routes matching the specified prefix list - - /usr/bin/vtysh -c "show ip bgp prefix-list $5" - - - - Show BGP routes matching the specified AS path regular expression - - /usr/bin/vtysh -c "show ip bgp regexp $5" - - - - Show BGP routes matching the specified route map - - /usr/bin/vtysh -c "show ip bgp route-map $5" - - - - Show summary of BGP information - - /usr/bin/vtysh -c "show ip bgp statistics" - - - - Show summary of BGP information - - /usr/bin/vtysh -c "show ip bgp summary" - - - - - - Show BGP information for specified IP address or prefix - - <x.x.x.x> <x.x.x.x/x> - - - /usr/bin/vtysh -c "show ip bgp $4" - - - - - - diff --git a/op-mode-definitions/show-ip-bgp.xml.in b/op-mode-definitions/show-ip-bgp.xml.in new file mode 100644 index 000000000..a92a78266 --- /dev/null +++ b/op-mode-definitions/show-ip-bgp.xml.in @@ -0,0 +1,342 @@ + + + + + + + + + Show Border Gateway Protocol (BGP) information + + /usr/bin/vtysh -c "show ip bgp" + + + + Show BGP attribute information + + /usr/bin/vtysh -c "show ip bgp attribute-info" + + + + Display only routes with non-natural netmasks + + /usr/bin/vtysh -c "show ip bgp cidr-only" + + + + Show BGP routes matching the communities + + /usr/bin/vtysh -c "show ip bgp community" + + + + Display routes matching the specified communities + + <AA:NN> local-AS no-advertise no-export + + + /usr/bin/vtysh -c "show ip bgp community $5" + + + + List all bgp community information + + /usr/bin/vtysh -c "show ip bgp community-info" + + + + Show BGP routes matching specified community list + + /usr/bin/vtysh -c "show ip bgp community-list $5" + + + + Show BGP routes exactly matching specified community list + + /usr/bin/vtysh -c "show ip bgp community-list $5 exact-match" + + + + + + Show dampened BGP paths + + /usr/bin/vtysh -c "show ip bgp dampening dampened-paths" + + + + Show BGP information for specified word + + /usr/bin/vtysh -c "show ip bgp filter-list $5" + + + + Show flap statistics of routes + + /usr/bin/vtysh -c "show ip bgp dampening flap-statistics" + + + + Show BGP IPv4 information + + + + + Show BGP IPv4 unicast information + + + + + Display only routes with non-natural netmasks + + /usr/bin/vtysh -c "show ip bgp ipv4 unicast cidr-only" + + + + Show BGP routes matching the communities + + /usr/bin/vtysh -c "show ip bgp ipv4 unicast community" + + + + Display routes matching the specified communities + + <AA:NN> local-AS no-advertise no-export + + + /usr/bin/vtysh -c "show ip bgp ipv4 unicast community $7" + + + + Show BGP routes matching specified community list + + /usr/bin/vtysh -c "show ip bgp ipv4 unicast community-list $7" + + + + Show BGP routes exactly matching specified community list + + /usr/bin/vtysh -c "show ip bgp ipv4 unicast community-list $7 exact-match" + + + + + + Show BGP information for specified word + + /usr/bin/vtysh -c "show ip bgp filter-list $5" + + + + Show detailed BGP IPv4 unicast neighbor information + + + + + /usr/bin/vtysh -c "show ip bgp ipv4 unicast neighbors $7" + + + + Show routes advertised to a BGP neighbor + + /usr/bin/vtysh -c "show ip bgp ipv4 unicast neighbor $7 advertised-routes" + + + + Show detailed prefix count information + + /usr/bin/vtysh -c "show ip bgp ipv4 unicast neighbor $7 prefix-counts" + + + + Show the received routes from neighbor + + /usr/bin/vtysh -c "show ip bgp ipv4 unicast neighbor $7 received-routes" + + + + Show routes learned from neighbor + + /usr/bin/vtysh -c "show ip bgp ipv4 unicast neighbor $7 routes" + + + + + + Show BGP path information + + /usr/bin/vtysh -c "show ip bgp ipv4 unicast paths" + + + + Show BGP routes matching the specified prefix list + + /usr/bin/vtysh -c "show ip bgp ipv4 unicast prefix-list $7" + + + + Show BGP routes matching the specified AS path regular expression + + /usr/bin/vtysh -c "show ip bgp ipv4 unicast regexp $5" + + + + Show BGP routes matching the specified route map + + /usr/bin/vtysh -c "show ip bgp route-map $5" + + + + Show summary of BGP information + + /usr/bin/vtysh -c "show ip bgp summary" + + + + + + Show BGP information for specified IP address or prefix + + <x.x.x.x> <x.x.x.x/x> + + + /usr/bin/vtysh -c "show ip bgp $6" + + + + + + Show BGP routes matching the specified large-communities + + /usr/bin/vtysh -c "show ip bgp large-community" + + + + Show BGP large-community information + + /usr/bin/vtysh -c "show ip bgp large-community-info" + + + + Show BGP routes matching the specified large-community list + + /usr/bin/vtysh -c "show ip bgp large-community-list $5" + + + + Show BGP memory usage + + /usr/bin/vtysh -c "show ip bgp memory" + + + + Show detailed BGP IPv4 unicast neighbor information + + + + + /usr/bin/vtysh -c "show ip bgp neighbors $5" + + + + Show routes advertised to a BGP neighbor + + /usr/bin/vtysh -c "show ip bgp neighbor $5 advertised-routes" + + + + Show dampened routes received from BGP neighbor + + /usr/bin/vtysh -c "show ip bgp neighbor $5 dampened-routes" + + + + Show flap statistics of the routes learned from BGP neighbor + + /usr/bin/vtysh -c "show ip bgp neighbor $5 flap-statistics" + + + + Show detailed prefix count information for BGP neighbor + + /usr/bin/vtysh -c "show ip bgp neighbor $5 prefix-counts" + + + + Show information received from BGP neighbor + + + + + Show prefixlist filter + + /usr/bin/vtysh -c "show ip bgp neighbor $5 received prefix-filter" + + + + + + Show received routes from BGP neighbor + + /usr/bin/vtysh -c "show ip bgp neighbor $5 received-routes" + + + + Show routes learned from BGP neighbor + + /usr/bin/vtysh -c "show ip bgp neighbor $5 routes" + + + + + + Show BGP path information + + /usr/bin/vtysh -c "show ip bgp paths" + + + + Show BGP routes matching the specified prefix list + + /usr/bin/vtysh -c "show ip bgp prefix-list $5" + + + + Show BGP routes matching the specified AS path regular expression + + /usr/bin/vtysh -c "show ip bgp regexp $5" + + + + Show BGP routes matching the specified route map + + /usr/bin/vtysh -c "show ip bgp route-map $5" + + + + Show summary of BGP information + + /usr/bin/vtysh -c "show ip bgp statistics" + + + + Show summary of BGP information + + /usr/bin/vtysh -c "show ip bgp summary" + + + + + + Show BGP information for specified IP address or prefix + + <x.x.x.x> <x.x.x.x/x> + + + /usr/bin/vtysh -c "show ip bgp $4" + + + + + + diff --git a/op-mode-definitions/show-ip-igmp.xml b/op-mode-definitions/show-ip-igmp.xml deleted file mode 100644 index b8f2f9107..000000000 --- a/op-mode-definitions/show-ip-igmp.xml +++ /dev/null @@ -1,48 +0,0 @@ - - - - - - - - - Show IGMP (Internet Group Management Protocol) information - - - - - IGMP groups information - - /usr/bin/vtysh -c "show ip igmp groups" - - - - IGMP interfaces information - - /usr/bin/vtysh -c "show ip igmp interface" - - - - IGMP static join information - - /usr/bin/vtysh -c "show ip igmp join" - - - - IGMP sources information - - /usr/bin/vtysh -c "show ip igmp sources" - - - - IGMP statistics - - /usr/bin/vtysh -c "show ip igmp statistics" - - - - - - - - diff --git a/op-mode-definitions/show-ip-igmp.xml.in b/op-mode-definitions/show-ip-igmp.xml.in new file mode 100644 index 000000000..b8f2f9107 --- /dev/null +++ b/op-mode-definitions/show-ip-igmp.xml.in @@ -0,0 +1,48 @@ + + + + + + + + + Show IGMP (Internet Group Management Protocol) information + + + + + IGMP groups information + + /usr/bin/vtysh -c "show ip igmp groups" + + + + IGMP interfaces information + + /usr/bin/vtysh -c "show ip igmp interface" + + + + IGMP static join information + + /usr/bin/vtysh -c "show ip igmp join" + + + + IGMP sources information + + /usr/bin/vtysh -c "show ip igmp sources" + + + + IGMP statistics + + /usr/bin/vtysh -c "show ip igmp statistics" + + + + + + + + diff --git a/op-mode-definitions/show-ip-multicast.xml b/op-mode-definitions/show-ip-multicast.xml deleted file mode 100644 index 5331d2e35..000000000 --- a/op-mode-definitions/show-ip-multicast.xml +++ /dev/null @@ -1,42 +0,0 @@ - - - - - - - - - Show IP multicast - - - - - Show multicast interfaces - - if ps -C igmpproxy &>/dev/null; then ${vyos_op_scripts_dir}/show_igmpproxy.py --interface; else echo IGMP proxy not configured; fi - - - - Show multicast fowarding cache - - if ps -C igmpproxy &>/dev/null; then ${vyos_op_scripts_dir}/show_igmpproxy.py --mfc; else echo IGMP proxy not configured; fi - - - - IP multicast information - - /usr/bin/vtysh -c "show ip multicast" - - - - IP multicast routing table - - /usr/bin/vtysh -c "show ip mroute" - - - - - - - - diff --git a/op-mode-definitions/show-ip-multicast.xml.in b/op-mode-definitions/show-ip-multicast.xml.in new file mode 100644 index 000000000..5331d2e35 --- /dev/null +++ b/op-mode-definitions/show-ip-multicast.xml.in @@ -0,0 +1,42 @@ + + + + + + + + + Show IP multicast + + + + + Show multicast interfaces + + if ps -C igmpproxy &>/dev/null; then ${vyos_op_scripts_dir}/show_igmpproxy.py --interface; else echo IGMP proxy not configured; fi + + + + Show multicast fowarding cache + + if ps -C igmpproxy &>/dev/null; then ${vyos_op_scripts_dir}/show_igmpproxy.py --mfc; else echo IGMP proxy not configured; fi + + + + IP multicast information + + /usr/bin/vtysh -c "show ip multicast" + + + + IP multicast routing table + + /usr/bin/vtysh -c "show ip mroute" + + + + + + + + diff --git a/op-mode-definitions/show-ip-ospf.xml b/op-mode-definitions/show-ip-ospf.xml deleted file mode 100644 index 15fa1db6c..000000000 --- a/op-mode-definitions/show-ip-ospf.xml +++ /dev/null @@ -1,579 +0,0 @@ - - - - - - - Show IPv4 routing information - - - - - Show IPv4 Open Shortest Path First (OSPF) routing information - - /usr/bin/vtysh -c "show ip ospf" - - - - Show IPv4 OSPF border-routers information - - /usr/bin/vtysh -c "show ip ospf border-routers" - - - - Show IPv4 OSPF database information - - /usr/bin/vtysh -c "show ip ospf database" - - - - Show IPv4 OSPF ASBR summary database - - /usr/bin/vtysh -c "show ip ospf database asbr-summary" - - - - Show IPv4 OSPF ASBR summary database for given address of advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database asbr-summary adv-router $7" - - - - Show IPv4 OSPF ASBR summary database for given address of advertised router - - - - - - - Show IPv4 OSPF ASBR summary database information of given address - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database asbr-summary $6" - - - - Show advertising router link states - - - - - Show IPv4 OSPF ASBR summary database of given address for given advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database asbr-summary $6 adv-router $8" - - - - Show summary of self-originate IPv4 OSPF ASBR database - - show ip ospf database asbr-summary $6 self-originate - - - - - - Show IPv4 OSPF external database - - /usr/bin/vtysh -c "show ip ospf database external" - - - - Show IPv4 OSPF external database for specified IP address of advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database external adv-router $7" - - - - Show IPv4 OSPF external database for specified IP address of advertised router - - - - - - - Show IPv4 OSPF external database information of specified IP address - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database external $6" - - - - Show advertising router link states - - - - - Show IPv4 OSPF external database of specified IP address for specified advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database external $6 adv-router $8" - - - - Show self-originate IPv4 OSPF external database - - show ip ospf database external $6 self-originate - - - - - - Show IPv4 OSPF max-age database - - /usr/bin/vtysh -c "show ip ospf database max-age" - - - - Show IPv4 OSPF network database - - /usr/bin/vtysh -c "show ip ospf database network" - - - - Show IPv4 OSPF network database for specified IP address of advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database network adv-router $7" - - - - Show IPv4 OSPF network database for given address of advertised router - - - - - - - Show IPv4 OSPF network database information of specified IP address - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database network $6" - - - - Show advertising router link states - - - - - Show IPv4 OSPF network database of specified IP address for specified advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database network $6 adv-router $8" - - - - Show self-originate IPv4 OSPF network database - - show ip ospf database network $6 self-originate - - - - - - Show IPv4 OSPF NSSA external database - - /usr/bin/vtysh -c "show ip ospf database nssa-external" - - - - Show IPv4 OSPF NSSA external database for specified IP address of advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database nssa-external adv-router $7" - - - - Show IPv4 OSPF NSSA external database for specified IP address of advertised router - - - - - - - Show IPv4 OSPF NSSA external database information of specified IP address - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database nssa-external $6" - - - - Show advertising router link states - - - - - Show IPv4 OSPF NSSA external database of specified IP address for specified advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database nssa-external $6 adv-router $8" - - - - Show self-originate IPv4 OSPF NSSA external database - - show ip ospf database nssa-external $6 self-originate - - - - - - Show IPv4 OSPF opaque-area database - - /usr/bin/vtysh -c "show ip ospf database opaque-area" - - - - Show IPv4 OSPF opaque-area database for specified IP address of advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database opaque-area adv-router $7" - - - - Show IPv4 OSPF opaque-area database for specified IP address of advertised router - - - - - - - Show IPv4 OSPF opaque-area database information of specified IP address - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database opaque-area $6" - - - - Show advertising router link states - - - - - Show IPv4 OSPF opaque-area database of specified IP address for specified advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database opaque-area $6 adv-router $8" - - - - Show self-originate IPv4 OSPF opaque-area database - - show ip ospf database opaque-area $6 self-originate - - - - - - Show IPv4 OSPF opaque-as database - - /usr/bin/vtysh -c "show ip ospf database opaque-as" - - - - Show IPv4 OSPF opaque-as database for specified IP address of advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database opaque-as adv-router $7" - - - - Show IPv4 OSPF opaque-as database for specified IP address of advertised router - - - - - - - Show IPv4 OSPF opaque-as database information of specified IP address - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database opaque-as $6" - - - - Show advertising router link states - - - - - Show IPv4 OSPF opaque-as database of specified IP address for specified advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database opaque-as $6 adv-router $8" - - - - Show self-originate IPv4 OSPF opaque-as database - - show ip ospf database opaque-as $6 self-originate - - - - - - Show IPv4 OSPF opaque-link database - - /usr/bin/vtysh -c "show ip ospf database opaque-link" - - - - Show IPv4 OSPF opaque-link database for specified IP address of advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database opaque-link adv-router $7" - - - - Show IPv4 OSPF opaque-link database for specified IP address of advertised router - - - - - - - Show IPv4 OSPF opaque-link database information of specified IP address - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database opaque-link $6" - - - - Show advertising router link states - - - - - Show IPv4 OSPF opaque-link database of specified IP address for specified advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database opaque-link $6 adv-router $8" - - - - Show self-originate IPv4 OSPF opaque-link database - - show ip ospf database opaque-link $6 self-originate - - - - - - Show IPv4 OSPF router database - - /usr/bin/vtysh -c "show ip ospf database router" - - - - Show IPv4 OSPF router database for specified IP address of advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database router adv-router $7" - - - - Show IPv4 OSPF router database for specified IP address of advertised router - - - - - - - Show IPv4 OSPF router database information of specified IP address - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database router $6" - - - - Show advertising router link states - - - - - Show IPv4 OSPF router database of specified IP address for specified advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database router $6 adv-router $8" - - - - Show self-originate IPv4 OSPF router database - - show ip ospf database router $6 self-originate - - - - - - Show IPv4 OSPF self-originate database - - /usr/bin/vtysh -c "show ip ospf database self-originate" - - - - Show summary of IPv4 OSPF database - - /usr/bin/vtysh -c "show ip ospf database summary" - - - - Show IPv4 OSPF summary database for specified IP address of advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database summary adv-router $7" - - - - Show IPv4 OSPF summary database for specified IP address of advertised router - - - - - - - Show IPv4 OSPF summary database information of specified IP address - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database summary $6" - - - - Show advertising router link states - - - - - Show IPv4 OSPF summary database of specified IP address for specified advertised router - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf database summary $6 adv-router $8" - - - - Show self-originate IPv4 OSPF summary database - - show ip ospf database summary $6 self-originate - - - - - - - - Show IPv4 OSPF interface information - - /usr/bin/vtysh -c "show ip ospf interface" - - - - Show IPv4 OSPF information for specified interface - - - - - /usr/bin/vtysh -c "show ip ospf interface $5" - - - - Show IPv4 OSPF neighbor information - - /usr/bin/vtysh -c "show ip ospf neighbor" - - - - Show IPv4 OSPF neighbor information for specified IP address - - <x.x.x.x> - - - /usr/bin/vtysh -c "show ip ospf neighbor $6" - - - - Show detailed IPv4 OSPF neighbor information - - /usr/bin/vtysh -c "show ip ospf neighbor detail" - - - - - - Show IPv4 OSPF neighbor information for specified IP address or interface - - <x.x.x.x> - - - - /usr/bin/vtysh -c "show ip ospf neighbor $5" - - - - Show IPv4 OSPF route information - - /usr/bin/vtysh -c "show ip ospf route" - - - - - - - - diff --git a/op-mode-definitions/show-ip-ospf.xml.in b/op-mode-definitions/show-ip-ospf.xml.in new file mode 100644 index 000000000..50628d18e --- /dev/null +++ b/op-mode-definitions/show-ip-ospf.xml.in @@ -0,0 +1,579 @@ + + + + + + + Show IPv4 routing information + + + + + Show IPv4 Open Shortest Path First (OSPF) routing information + + /usr/bin/vtysh -c "show ip ospf" + + + + Show IPv4 OSPF border-routers information + + /usr/bin/vtysh -c "show ip ospf border-routers" + + + + Show IPv4 OSPF database information + + /usr/bin/vtysh -c "show ip ospf database" + + + + Show IPv4 OSPF ASBR summary database + + /usr/bin/vtysh -c "show ip ospf database asbr-summary" + + + + Show IPv4 OSPF ASBR summary database for given address of advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database asbr-summary adv-router $7" + + + + Show IPv4 OSPF ASBR summary database for given address of advertised router + + + + + + + Show IPv4 OSPF ASBR summary database information of given address + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database asbr-summary $6" + + + + Show advertising router link states + + + + + Show IPv4 OSPF ASBR summary database of given address for given advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database asbr-summary $6 adv-router $8" + + + + Show summary of self-originate IPv4 OSPF ASBR database + + show ip ospf database asbr-summary $6 self-originate + + + + + + Show IPv4 OSPF external database + + /usr/bin/vtysh -c "show ip ospf database external" + + + + Show IPv4 OSPF external database for specified IP address of advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database external adv-router $7" + + + + Show IPv4 OSPF external database for specified IP address of advertised router + + + + + + + Show IPv4 OSPF external database information of specified IP address + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database external $6" + + + + Show advertising router link states + + + + + Show IPv4 OSPF external database of specified IP address for specified advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database external $6 adv-router $8" + + + + Show self-originate IPv4 OSPF external database + + show ip ospf database external $6 self-originate + + + + + + Show IPv4 OSPF max-age database + + /usr/bin/vtysh -c "show ip ospf database max-age" + + + + Show IPv4 OSPF network database + + /usr/bin/vtysh -c "show ip ospf database network" + + + + Show IPv4 OSPF network database for specified IP address of advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database network adv-router $7" + + + + Show IPv4 OSPF network database for given address of advertised router + + + + + + + Show IPv4 OSPF network database information of specified IP address + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database network $6" + + + + Show advertising router link states + + + + + Show IPv4 OSPF network database of specified IP address for specified advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database network $6 adv-router $8" + + + + Show self-originate IPv4 OSPF network database + + show ip ospf database network $6 self-originate + + + + + + Show IPv4 OSPF NSSA external database + + /usr/bin/vtysh -c "show ip ospf database nssa-external" + + + + Show IPv4 OSPF NSSA external database for specified IP address of advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database nssa-external adv-router $7" + + + + Show IPv4 OSPF NSSA external database for specified IP address of advertised router + + + + + + + Show IPv4 OSPF NSSA external database information of specified IP address + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database nssa-external $6" + + + + Show advertising router link states + + + + + Show IPv4 OSPF NSSA external database of specified IP address for specified advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database nssa-external $6 adv-router $8" + + + + Show self-originate IPv4 OSPF NSSA external database + + show ip ospf database nssa-external $6 self-originate + + + + + + Show IPv4 OSPF opaque-area database + + /usr/bin/vtysh -c "show ip ospf database opaque-area" + + + + Show IPv4 OSPF opaque-area database for specified IP address of advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database opaque-area adv-router $7" + + + + Show IPv4 OSPF opaque-area database for specified IP address of advertised router + + + + + + + Show IPv4 OSPF opaque-area database information of specified IP address + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database opaque-area $6" + + + + Show advertising router link states + + + + + Show IPv4 OSPF opaque-area database of specified IP address for specified advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database opaque-area $6 adv-router $8" + + + + Show self-originate IPv4 OSPF opaque-area database + + show ip ospf database opaque-area $6 self-originate + + + + + + Show IPv4 OSPF opaque-as database + + /usr/bin/vtysh -c "show ip ospf database opaque-as" + + + + Show IPv4 OSPF opaque-as database for specified IP address of advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database opaque-as adv-router $7" + + + + Show IPv4 OSPF opaque-as database for specified IP address of advertised router + + + + + + + Show IPv4 OSPF opaque-as database information of specified IP address + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database opaque-as $6" + + + + Show advertising router link states + + + + + Show IPv4 OSPF opaque-as database of specified IP address for specified advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database opaque-as $6 adv-router $8" + + + + Show self-originate IPv4 OSPF opaque-as database + + show ip ospf database opaque-as $6 self-originate + + + + + + Show IPv4 OSPF opaque-link database + + /usr/bin/vtysh -c "show ip ospf database opaque-link" + + + + Show IPv4 OSPF opaque-link database for specified IP address of advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database opaque-link adv-router $7" + + + + Show IPv4 OSPF opaque-link database for specified IP address of advertised router + + + + + + + Show IPv4 OSPF opaque-link database information of specified IP address + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database opaque-link $6" + + + + Show advertising router link states + + + + + Show IPv4 OSPF opaque-link database of specified IP address for specified advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database opaque-link $6 adv-router $8" + + + + Show self-originate IPv4 OSPF opaque-link database + + show ip ospf database opaque-link $6 self-originate + + + + + + Show IPv4 OSPF router database + + /usr/bin/vtysh -c "show ip ospf database router" + + + + Show IPv4 OSPF router database for specified IP address of advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database router adv-router $7" + + + + Show IPv4 OSPF router database for specified IP address of advertised router + + + + + + + Show IPv4 OSPF router database information of specified IP address + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database router $6" + + + + Show advertising router link states + + + + + Show IPv4 OSPF router database of specified IP address for specified advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database router $6 adv-router $8" + + + + Show self-originate IPv4 OSPF router database + + show ip ospf database router $6 self-originate + + + + + + Show IPv4 OSPF self-originate database + + /usr/bin/vtysh -c "show ip ospf database self-originate" + + + + Show summary of IPv4 OSPF database + + /usr/bin/vtysh -c "show ip ospf database summary" + + + + Show IPv4 OSPF summary database for specified IP address of advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database summary adv-router $7" + + + + Show IPv4 OSPF summary database for specified IP address of advertised router + + + + + + + Show IPv4 OSPF summary database information of specified IP address + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database summary $6" + + + + Show advertising router link states + + + + + Show IPv4 OSPF summary database of specified IP address for specified advertised router + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf database summary $6 adv-router $8" + + + + Show self-originate IPv4 OSPF summary database + + show ip ospf database summary $6 self-originate + + + + + + + + Show IPv4 OSPF interface information + + /usr/bin/vtysh -c "show ip ospf interface" + + + + Show IPv4 OSPF information for specified interface + + + + + /usr/bin/vtysh -c "show ip ospf interface $5" + + + + Show IPv4 OSPF neighbor information + + /usr/bin/vtysh -c "show ip ospf neighbor" + + + + Show IPv4 OSPF neighbor information for specified IP address + + <x.x.x.x> + + + /usr/bin/vtysh -c "show ip ospf neighbor $6" + + + + Show detailed IPv4 OSPF neighbor information + + /usr/bin/vtysh -c "show ip ospf neighbor detail" + + + + + + Show IPv4 OSPF neighbor information for specified IP address or interface + + <x.x.x.x> + + + + /usr/bin/vtysh -c "show ip ospf neighbor $5" + + + + Show IPv4 OSPF route information + + /usr/bin/vtysh -c "show ip ospf route" + + + + + + + + diff --git a/op-mode-definitions/show-ip-pim.xml b/op-mode-definitions/show-ip-pim.xml deleted file mode 100644 index 3f4edc779..000000000 --- a/op-mode-definitions/show-ip-pim.xml +++ /dev/null @@ -1,72 +0,0 @@ - - - - - - - - - Show PIM (Protocol Independent Multicast) information - - - - - PIM interfaces information - - /usr/bin/vtysh -c "show ip pim interface" - - - - PIM join information - - /usr/bin/vtysh -c "show ip pim join" - - - - PIM neighbor information - - /usr/bin/vtysh -c "show ip pim neighbor" - - - - PIM cached nexthop rpf information - - /usr/bin/vtysh -c "show ip pim nexthop" - - - - PIM state information - - /usr/bin/vtysh -c "show ip pim state" - - - - PIM statistics - - /usr/bin/vtysh -c "show ip pim statistics" - - - - PIM RP (Rendevous Point) information - - /usr/bin/vtysh -c "show ip pim rp-info" - - - - PIM cached source rpf information - - /usr/bin/vtysh -c "show ip pim rpf" - - - - PIM upstream information - - /usr/bin/vtysh -c "show ip pim upstream" - - - - - - - - diff --git a/op-mode-definitions/show-ip-pim.xml.in b/op-mode-definitions/show-ip-pim.xml.in new file mode 100644 index 000000000..3f4edc779 --- /dev/null +++ b/op-mode-definitions/show-ip-pim.xml.in @@ -0,0 +1,72 @@ + + + + + + + + + Show PIM (Protocol Independent Multicast) information + + + + + PIM interfaces information + + /usr/bin/vtysh -c "show ip pim interface" + + + + PIM join information + + /usr/bin/vtysh -c "show ip pim join" + + + + PIM neighbor information + + /usr/bin/vtysh -c "show ip pim neighbor" + + + + PIM cached nexthop rpf information + + /usr/bin/vtysh -c "show ip pim nexthop" + + + + PIM state information + + /usr/bin/vtysh -c "show ip pim state" + + + + PIM statistics + + /usr/bin/vtysh -c "show ip pim statistics" + + + + PIM RP (Rendevous Point) information + + /usr/bin/vtysh -c "show ip pim rp-info" + + + + PIM cached source rpf information + + /usr/bin/vtysh -c "show ip pim rpf" + + + + PIM upstream information + + /usr/bin/vtysh -c "show ip pim upstream" + + + + + + + + diff --git a/op-mode-definitions/show-ip-ports.xml b/op-mode-definitions/show-ip-ports.xml deleted file mode 100644 index a74b68ffc..000000000 --- a/op-mode-definitions/show-ip-ports.xml +++ /dev/null @@ -1,17 +0,0 @@ - - - - - - - - - Show IP ports in use by various system services - - sudo /usr/bin/netstat -tulnp - - - - - - diff --git a/op-mode-definitions/show-ip-ports.xml.in b/op-mode-definitions/show-ip-ports.xml.in new file mode 100644 index 000000000..a74b68ffc --- /dev/null +++ b/op-mode-definitions/show-ip-ports.xml.in @@ -0,0 +1,17 @@ + + + + + + + + + Show IP ports in use by various system services + + sudo /usr/bin/netstat -tulnp + + + + + + diff --git a/op-mode-definitions/show-ip-rip.xml b/op-mode-definitions/show-ip-rip.xml deleted file mode 100644 index b61ab10a7..000000000 --- a/op-mode-definitions/show-ip-rip.xml +++ /dev/null @@ -1,28 +0,0 @@ - - - - - - - Show IPv4 routing information - - - - - Show Routing Information Protocol (RIP) information - - /usr/bin/vtysh -c "show ip rip" - - - - Show RIP protocol status - - /usr/bin/vtysh -c "show ip rip status" - - - - - - - - diff --git a/op-mode-definitions/show-ip-rip.xml.in b/op-mode-definitions/show-ip-rip.xml.in new file mode 100644 index 000000000..b61ab10a7 --- /dev/null +++ b/op-mode-definitions/show-ip-rip.xml.in @@ -0,0 +1,28 @@ + + + + + + + Show IPv4 routing information + + + + + Show Routing Information Protocol (RIP) information + + /usr/bin/vtysh -c "show ip rip" + + + + Show RIP protocol status + + /usr/bin/vtysh -c "show ip rip status" + + + + + + + + diff --git a/op-mode-definitions/show-ip-route.xml b/op-mode-definitions/show-ip-route.xml deleted file mode 100644 index a98048785..000000000 --- a/op-mode-definitions/show-ip-route.xml +++ /dev/null @@ -1,166 +0,0 @@ - - - - - - - Show IPv4 routing information - - - - - Show IP routes - - /usr/bin/vtysh -c "show ip route" - - - - Show IP BGP routes - - /usr/bin/vtysh -c "show ip route bgp" - - - - Show kernel route cache - - ip -s route list cache - - - - Show kernel route cache for a given route - - <x.x.x.x> <x.x.x.x/x> - - - ip -s route list cache $5 - - - - Show IP connected routes - - /usr/bin/vtysh -c "show ip route connected" - - - - Show kernel route table - - ip route list - - - - Show kernel route table for a given route - - <x.x.x.x> <x.x.x.x/x> - - - ip -s route list $5 - - - - Show IP IS-IS routes - - /usr/bin/vtysh -c "show ip route isis" - - - - Show IP kernel routes - - /usr/bin/vtysh -c "show ip route kernel" - - - - Show IP OSPF routes - - /usr/bin/vtysh -c "show ip route ospf" - - - - Show IP RIP routes - - /usr/bin/vtysh -c "show ip route rip" - - - - Show IP static routes - - /usr/bin/vtysh -c "show ip route static" - - - - Show IP routes summary - - /usr/bin/vtysh -c "show ip route summary" - - - - Show IP supernet routes - - /usr/bin/vtysh -c "show ip route supernets-only" - - - - Show IP routes in policy table - - - - - Show IP routes in policy table - - <1-200> - - - /usr/bin/vtysh -c "show ip route table $5" - - - - Show only routes with tag - - - - - Tag value - - <1-4294967295> - - - /usr/bin/vtysh -c "show ip route tag $5" - - - - Show IP routes in VRF - - - - - Show IP routes in VRF - - <vrf> - vrf name - - - /usr/bin/vtysh -c "show ip route vrf $5" - - - - - - Show IP routes of specified IP address or prefix - - <x.x.x.x> <x.x.x.x/x> - - - /usr/bin/vtysh -c "show ip route $4" - - - - Show longer prefixes of routes for specified IP address or prefix - - /usr/bin/vtysh -c "show ip route $4 longer-prefixes" - - - - - - - - diff --git a/op-mode-definitions/show-ip-route.xml.in b/op-mode-definitions/show-ip-route.xml.in new file mode 100644 index 000000000..a98048785 --- /dev/null +++ b/op-mode-definitions/show-ip-route.xml.in @@ -0,0 +1,166 @@ + + + + + + + Show IPv4 routing information + + + + + Show IP routes + + /usr/bin/vtysh -c "show ip route" + + + + Show IP BGP routes + + /usr/bin/vtysh -c "show ip route bgp" + + + + Show kernel route cache + + ip -s route list cache + + + + Show kernel route cache for a given route + + <x.x.x.x> <x.x.x.x/x> + + + ip -s route list cache $5 + + + + Show IP connected routes + + /usr/bin/vtysh -c "show ip route connected" + + + + Show kernel route table + + ip route list + + + + Show kernel route table for a given route + + <x.x.x.x> <x.x.x.x/x> + + + ip -s route list $5 + + + + Show IP IS-IS routes + + /usr/bin/vtysh -c "show ip route isis" + + + + Show IP kernel routes + + /usr/bin/vtysh -c "show ip route kernel" + + + + Show IP OSPF routes + + /usr/bin/vtysh -c "show ip route ospf" + + + + Show IP RIP routes + + /usr/bin/vtysh -c "show ip route rip" + + + + Show IP static routes + + /usr/bin/vtysh -c "show ip route static" + + + + Show IP routes summary + + /usr/bin/vtysh -c "show ip route summary" + + + + Show IP supernet routes + + /usr/bin/vtysh -c "show ip route supernets-only" + + + + Show IP routes in policy table + + + + + Show IP routes in policy table + + <1-200> + + + /usr/bin/vtysh -c "show ip route table $5" + + + + Show only routes with tag + + + + + Tag value + + <1-4294967295> + + + /usr/bin/vtysh -c "show ip route tag $5" + + + + Show IP routes in VRF + + + + + Show IP routes in VRF + + <vrf> + vrf name + + + /usr/bin/vtysh -c "show ip route vrf $5" + + + + + + Show IP routes of specified IP address or prefix + + <x.x.x.x> <x.x.x.x/x> + + + /usr/bin/vtysh -c "show ip route $4" + + + + Show longer prefixes of routes for specified IP address or prefix + + /usr/bin/vtysh -c "show ip route $4 longer-prefixes" + + + + + + + + diff --git a/op-mode-definitions/show-ipv6-bgp.xml b/op-mode-definitions/show-ipv6-bgp.xml deleted file mode 100644 index aad61b97a..000000000 --- a/op-mode-definitions/show-ipv6-bgp.xml +++ /dev/null @@ -1,203 +0,0 @@ - - - - - - - Show IPv6 routing information - - - - - Show Border Gateway Protocol (BGP) information - - vtysh -c "show bgp ipv6" - - - - Show summary of BGP neighbor status - - vtysh -c "show bgp ipv6 summary" - - - - Show routes matching AS path regular expression - - vtysh -c "show bgp ipv6 regexp $5" - - - - Show routes matching the IPv6 prefix-list name - - policy prefix-list6 - - - vtysh -c "show bgp ipv6 prefix-list $5" - - - - Show detailed information on TCP and BGP neighbor connections for given address - - - - - vtysh -c "show bgp ipv6 neighbor $5" - - - - Show routes advertised to a BGP neighbor - - vtysh -c "show bgp ipv6 neighbor $5 advertised-routes" - - - - Show routes filtered from a BGP neighbor - - vtysh -c "show bgp ipv6 neighbor $5 filtered-routes" - - - - Show dampened routes received from BGP neighbor - - vtysh -c "show bgp ipv6 neighbor $5 dampened-routes" - - - - Show flap statistics of the routes learned from BGP neighbor - - vtysh -c "show bgp ipv6 neighbor $5 flap-statistics" - - - - Show detailed prefix count information for BGP neighbor - - vtysh -c "show bgp ipv6 neighbor $5 prefix-counts" - - - - Show information received from BGP neighbor - - - - - Show prefixlist filter - - vtysh -c "show bgp ipv6 neighbor $5 received prefix-filter" - - - - - - Show received routes from BGP neighbor - - vtysh -c "show bgp ipv6 neighbor $5 received-routes" - - - - Show routes learned from BGP neighbor - - vtysh -c "show bgp ipv6 neighbor $5 routes" - - - - - - Show routes matching the large-community-list number or name - - vtysh -c "show bgp ipv6 large-community-list $5" - - - - Show routes matching the large-community-list number or name - - vtysh -c "show bgp ipv6 large-community-list $5 exact-match" - - - - - - Show routes matching the large-community-list number or name - - vtysh -c "show bgp ipv6 large-community-list $5" - - - - Show routes matching the large-community-list number or name - - vtysh -c "show bgp ipv6 large-community-list $5 exact-match" - - - - - - Show routes conforming to regular expression access list name - - vtysh -c "show bgp ipv6 filter-list $5" - - - - Show BGP information for specified community number - - <AA:NN> local-AS no-advertise no-export - - - vtysh -c "show bgp ipv6 community $5" - - - - Show routes from community that exactly matches the community number - - vtysh -c "show bgp ipv6 community $5 exact-match" - - - - - - Show routes matching the community-list number or name - - vtysh -c "show bgp ipv6 community-list $5" - - - - Show routes exactly matching the community-list name or number - - vtysh -c "show bgp ipv6 community-list $5 exact-match" - - - - - - Show BGP routes matching the specified route map - - policy route-map - - - vtysh -c "show bgp ipv6 route-map $5" - - - - - - Show BGP information for specified IP address or prefix - - <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> - - - vtysh -c "show bgp ipv6 $4" - - - - Show route and more specific routes - - <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> - - - vtysh -c "show bgp ipv6 $4 longer-prefixes" - - - - - - - - diff --git a/op-mode-definitions/show-ipv6-bgp.xml.in b/op-mode-definitions/show-ipv6-bgp.xml.in new file mode 100644 index 000000000..aad61b97a --- /dev/null +++ b/op-mode-definitions/show-ipv6-bgp.xml.in @@ -0,0 +1,203 @@ + + + + + + + Show IPv6 routing information + + + + + Show Border Gateway Protocol (BGP) information + + vtysh -c "show bgp ipv6" + + + + Show summary of BGP neighbor status + + vtysh -c "show bgp ipv6 summary" + + + + Show routes matching AS path regular expression + + vtysh -c "show bgp ipv6 regexp $5" + + + + Show routes matching the IPv6 prefix-list name + + policy prefix-list6 + + + vtysh -c "show bgp ipv6 prefix-list $5" + + + + Show detailed information on TCP and BGP neighbor connections for given address + + + + + vtysh -c "show bgp ipv6 neighbor $5" + + + + Show routes advertised to a BGP neighbor + + vtysh -c "show bgp ipv6 neighbor $5 advertised-routes" + + + + Show routes filtered from a BGP neighbor + + vtysh -c "show bgp ipv6 neighbor $5 filtered-routes" + + + + Show dampened routes received from BGP neighbor + + vtysh -c "show bgp ipv6 neighbor $5 dampened-routes" + + + + Show flap statistics of the routes learned from BGP neighbor + + vtysh -c "show bgp ipv6 neighbor $5 flap-statistics" + + + + Show detailed prefix count information for BGP neighbor + + vtysh -c "show bgp ipv6 neighbor $5 prefix-counts" + + + + Show information received from BGP neighbor + + + + + Show prefixlist filter + + vtysh -c "show bgp ipv6 neighbor $5 received prefix-filter" + + + + + + Show received routes from BGP neighbor + + vtysh -c "show bgp ipv6 neighbor $5 received-routes" + + + + Show routes learned from BGP neighbor + + vtysh -c "show bgp ipv6 neighbor $5 routes" + + + + + + Show routes matching the large-community-list number or name + + vtysh -c "show bgp ipv6 large-community-list $5" + + + + Show routes matching the large-community-list number or name + + vtysh -c "show bgp ipv6 large-community-list $5 exact-match" + + + + + + Show routes matching the large-community-list number or name + + vtysh -c "show bgp ipv6 large-community-list $5" + + + + Show routes matching the large-community-list number or name + + vtysh -c "show bgp ipv6 large-community-list $5 exact-match" + + + + + + Show routes conforming to regular expression access list name + + vtysh -c "show bgp ipv6 filter-list $5" + + + + Show BGP information for specified community number + + <AA:NN> local-AS no-advertise no-export + + + vtysh -c "show bgp ipv6 community $5" + + + + Show routes from community that exactly matches the community number + + vtysh -c "show bgp ipv6 community $5 exact-match" + + + + + + Show routes matching the community-list number or name + + vtysh -c "show bgp ipv6 community-list $5" + + + + Show routes exactly matching the community-list name or number + + vtysh -c "show bgp ipv6 community-list $5 exact-match" + + + + + + Show BGP routes matching the specified route map + + policy route-map + + + vtysh -c "show bgp ipv6 route-map $5" + + + + + + Show BGP information for specified IP address or prefix + + <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> + + + vtysh -c "show bgp ipv6 $4" + + + + Show route and more specific routes + + <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> + + + vtysh -c "show bgp ipv6 $4 longer-prefixes" + + + + + + + + diff --git a/op-mode-definitions/show-ipv6-ospfv3.xml b/op-mode-definitions/show-ipv6-ospfv3.xml deleted file mode 100644 index 36bb5b40e..000000000 --- a/op-mode-definitions/show-ipv6-ospfv3.xml +++ /dev/null @@ -1,777 +0,0 @@ - - - - - - - Show IPv6 routing information - - - - - Show IPv6 Open Shortest Path First (OSPF) - - vtysh -c "show ipv6 ospf6" - - - - Show Shortest Path First tree information - - vtysh -c "show ipv6 ospf6 spf tree" - - - - Area ID (as an IPv4 notation) - - protocols ospfv3 area - - - vtysh -c "show ipv6 ospf6 area $4 spf tree" - - - - Simulate view point (Router ID) - - <x.x.x.x> - - - vtysh -c "show ipv6 ospf6 simulate spf-tree $7 $4 $5" - - - - - - Show OSPFv3 border-router (ABR and ASBR) information - - vtysh -c "show ipv6 ospf6 border-routers" - - - - Show OSPFv3 detailed border-router information - - vtysh -c "show ipv6 ospf6 border-routers detail" - - - - - - Border router ID - - <x.x.x.x> - - - vtysh -c "show ipv6 ospf6 border-routers $5" - - - - Show OSPFv3 Link state database information - - vtysh -c "show ipv6 ospf6 database" - - - - Search by Advertising Router ID - - <x.x.x.x> - - - - - - Search by Link state ID - - <x.x.x.x> - - - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database adv-router $6 linkstate-id $8 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database adv-router $6 linkstate-id $8 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database adv-router $6 linkstate-id $8 internal" - - - - - - - - Search by Any Link state Type - - - - - Search by Link state ID - - <x.x.x.x> - - - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database * * $7 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database * * $7 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database * * $7 internal" - - - - - - - - Search by Link state ID - - <x.x.x.x> - - - vtysh -c "show ipv6 ospf6 database * $6" - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database * $6 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database * $6 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database * $6 internal" - - - - Search by Advertising Router ID - - <x.x.x.x> - - - vtysh -c "show ipv6 ospf6 database * $6 $7" - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database * $6 $7 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database * $6 $7 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database * $6 $7 internal" - - - - - - - - - - - - - Show AS-External LSAs - - vtysh -c "show ipv6 ospf6 database as-external" - - - - Search by Advertising Router ID - - <x.x.x.x> - - - - - - Search by Link state ID - - <x.x.x.x> - - - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database as-external adv-router $7 linkstate-id $9 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database as-external adv-router $7 linkstate-id $9 internal" - - - - - - - - Search by Advertising Router ID - - <x.x.x.x> - - - vtysh -c "show ipv6 ospf6 database as-external * $7" - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database as-external * $7 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database as-external * $7 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database as-external * $7 internal" - - - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database as-external detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database as-external dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database as-external internal" - - - - Search by Link state ID - - <x.x.x.x> - - - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database as-external linkstate-id $7 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database as-external linkstate-id $7 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database as-external linkstate-id $7 internal" - - - - - - Show Self-originated LSAs - - vtysh -c "show ipv6 ospf6 database as-external self-originated" - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database as-external self-originated detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database as-external self-originated dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database as-external self-originated internal" - - - - Search by Link state ID - - <x.x.x.x> - - - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database as-external self-originated linkstate-id $8 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database as-external self-originated linkstate-id $8 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database as-external self-originated linkstate-id $8 internal" - - - - - - - - - - Search by Advertising Router IDs - - <x.x.x.x> - - - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database as-external $6 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database as-external $6 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database as-external $6 internal" - - - - Show Self-originated LSAs - - vtysh -c "show ipv6 ospf6 database as-external $6 self-originated" - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database as-external $6 self-originated detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database as-external $6 self-originated dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database as-external $6 self-originated internal" - - - - - - Search by Advertising Router ID - - <x.x.x.x> - - - - - - Show dump of LSAs - - echo vtysh -c "show ipv6 ospf6 database as-external $6 $7 dump" - - - - Show LSAs internal information - - echo vtysh -c "show ipv6 ospf6 database as-external $6 $7 internal" - - - - - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database dump" - - - - Search by Link state ID - - <x.x.x.x> - - - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database linkstate-id $6 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database linkstate-id $6 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database linkstate-id $6 internal" - - - - - - Show Self-originated LSAs - - vtysh -c "show ipv6 ospf6 database self-originated" - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database self-originated detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database self-originated dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database self-originated internal" - - - - - - - - Show OSPFv3 interface information - - vtysh -c "show ipv6 ospf6 interface" - - - - Show connected prefixes to advertise - - vtysh -c "show ipv6 ospf6 interface prefix" - - - - More detailed interface prefix information - - vtysh -c "show ipv6 ospf6 interface prefix detail" - - - - - - Show interface prefix route specific information - - <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> - - - vtysh -c "show ipv6 ospf6 interface prefix $6" - - - - More detailed information - - vtysh -c "show ipv6 ospf6 interface prefix $6 detail" - - - - Matched interface prefix information - - vtysh -c "show ipv6 ospf6 interface prefix $6 match" - - - - - - - - Specific insterface to examine - - - - - vtysh -c "show ipv6 ospf6 interface $5" - - - - Show connected prefixes to advertise - - vtysh -c "show ipv6 ospf6 interface $5 prefix" - - - - More detailed interface prefix information - - vtysh -c "show ipv6 ospf6 interface $5 prefix detail" - - - - - - Show interface prefix route specific information - - <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> - - - vtysh -c "show ipv6 ospf6 interface $5 prefix $7" - - - - More detailed information - - vtysh -c "show ipv6 ospf6 interface $5 prefix $7 detail" - - - - Matched interface prefix information - - vtysh -c "show ipv6 ospf6 interface $5 prefix $7 match" - - - - - - - - Show OSPFv3 linkstate routing information - - - - - Show detailed linkstate information - - vtysh -c "show ipv6 ospf6 linkstate detail" - - - - Show linkstate Network information - - vtysh -c "show ipv6 ospf6 linkstate network" - - - - Show linkstate Router information - - vtysh -c "show ipv6 ospf6 linkstate router" - - - - - - Show OSPFv3 neighbor information - - vtysh -c "show ipv6 ospf6 neighbor" - - - - Show detailed neighbor information - - vtysh -c "show ipv6 ospf6 neighbor detail" - - - - Show neighbor DR choice information - - vtysh -c "show ipv6 ospf6 neighbor drchoice" - - - - - - Show OSPFv3 redistribute external information - - vtysh -c "show ipv6 ospf6 redistribute" - - - - Show OSPFv3 routing table information - - vtysh -c "show ipv6 ospf6 route" - - - - Show Type-1 External route information - - vtysh -c "show ipv6 ospf6 route external-1" - - - - Show detailed Type-1 External route information - - vtysh -c "show ipv6 ospf6 route external-1 detail" - - - - - - Show Type-2 External route information - - vtysh -c "show ipv6 ospf6 route external-2" - - - - Show detailed Type-2 External route information - - vtysh -c "show ipv6 ospf6 route external-2 detail" - - - - - - Show Inter-Area route information - - vtysh -c "show ipv6 ospf6 route inter-area" - - - - Show detailed Inter-Area route information - - vtysh -c "show ipv6 ospf6 route inter-area detail" - - - - - - Show Intra-Area route information - - vtysh -c "show ipv6 ospf6 route intra-area" - - - - Show detailed Intra-Area route information - - vtysh -c "show ipv6 ospf6 route intra-area detail" - - - - - - Show detailed route information - - vtysh -c "show ipv6 ospf6 route detail" - - - - Show route table summary - - vtysh -c "show ipv6 ospf6 route summary" - - - - - - Show specified route/prefix information - - <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> - - - vtysh -c "show ipv6 ospf6 route $5" - - - - Show routes longer than specified prefix - - vtysh -c "show ipv6 ospf6 route $5 longer" - - - - Show routes matching specified prefix - - vtysh -c "show ipv6 ospf6 route $5 match" - - - - Detailed information - - vtysh -c "show ipv6 ospf6 route $5 match detail" - - - - - - - - - - - - diff --git a/op-mode-definitions/show-ipv6-ospfv3.xml.in b/op-mode-definitions/show-ipv6-ospfv3.xml.in new file mode 100644 index 000000000..36bb5b40e --- /dev/null +++ b/op-mode-definitions/show-ipv6-ospfv3.xml.in @@ -0,0 +1,777 @@ + + + + + + + Show IPv6 routing information + + + + + Show IPv6 Open Shortest Path First (OSPF) + + vtysh -c "show ipv6 ospf6" + + + + Show Shortest Path First tree information + + vtysh -c "show ipv6 ospf6 spf tree" + + + + Area ID (as an IPv4 notation) + + protocols ospfv3 area + + + vtysh -c "show ipv6 ospf6 area $4 spf tree" + + + + Simulate view point (Router ID) + + <x.x.x.x> + + + vtysh -c "show ipv6 ospf6 simulate spf-tree $7 $4 $5" + + + + + + Show OSPFv3 border-router (ABR and ASBR) information + + vtysh -c "show ipv6 ospf6 border-routers" + + + + Show OSPFv3 detailed border-router information + + vtysh -c "show ipv6 ospf6 border-routers detail" + + + + + + Border router ID + + <x.x.x.x> + + + vtysh -c "show ipv6 ospf6 border-routers $5" + + + + Show OSPFv3 Link state database information + + vtysh -c "show ipv6 ospf6 database" + + + + Search by Advertising Router ID + + <x.x.x.x> + + + + + + Search by Link state ID + + <x.x.x.x> + + + + + + Show details of LSAs + + vtysh -c "show ipv6 ospf6 database adv-router $6 linkstate-id $8 detail" + + + + Show dump of LSAs + + vtysh -c "show ipv6 ospf6 database adv-router $6 linkstate-id $8 dump" + + + + Show LSAs internal information + + vtysh -c "show ipv6 ospf6 database adv-router $6 linkstate-id $8 internal" + + + + + + + + Search by Any Link state Type + + + + + Search by Link state ID + + <x.x.x.x> + + + + + + Show details of LSAs + + vtysh -c "show ipv6 ospf6 database * * $7 detail" + + + + Show dump of LSAs + + vtysh -c "show ipv6 ospf6 database * * $7 dump" + + + + Show LSAs internal information + + vtysh -c "show ipv6 ospf6 database * * $7 internal" + + + + + + + + Search by Link state ID + + <x.x.x.x> + + + vtysh -c "show ipv6 ospf6 database * $6" + + + + Show details of LSAs + + vtysh -c "show ipv6 ospf6 database * $6 detail" + + + + Show dump of LSAs + + vtysh -c "show ipv6 ospf6 database * $6 dump" + + + + Show LSAs internal information + + vtysh -c "show ipv6 ospf6 database * $6 internal" + + + + Search by Advertising Router ID + + <x.x.x.x> + + + vtysh -c "show ipv6 ospf6 database * $6 $7" + + + + Show details of LSAs + + vtysh -c "show ipv6 ospf6 database * $6 $7 detail" + + + + Show dump of LSAs + + vtysh -c "show ipv6 ospf6 database * $6 $7 dump" + + + + Show LSAs internal information + + vtysh -c "show ipv6 ospf6 database * $6 $7 internal" + + + + + + + + + + + + + Show AS-External LSAs + + vtysh -c "show ipv6 ospf6 database as-external" + + + + Search by Advertising Router ID + + <x.x.x.x> + + + + + + Search by Link state ID + + <x.x.x.x> + + + + + + Show dump of LSAs + + vtysh -c "show ipv6 ospf6 database as-external adv-router $7 linkstate-id $9 dump" + + + + Show LSAs internal information + + vtysh -c "show ipv6 ospf6 database as-external adv-router $7 linkstate-id $9 internal" + + + + + + + + Search by Advertising Router ID + + <x.x.x.x> + + + vtysh -c "show ipv6 ospf6 database as-external * $7" + + + + Show details of LSAs + + vtysh -c "show ipv6 ospf6 database as-external * $7 detail" + + + + Show dump of LSAs + + vtysh -c "show ipv6 ospf6 database as-external * $7 dump" + + + + Show LSAs internal information + + vtysh -c "show ipv6 ospf6 database as-external * $7 internal" + + + + + + Show details of LSAs + + vtysh -c "show ipv6 ospf6 database as-external detail" + + + + Show dump of LSAs + + vtysh -c "show ipv6 ospf6 database as-external dump" + + + + Show LSAs internal information + + vtysh -c "show ipv6 ospf6 database as-external internal" + + + + Search by Link state ID + + <x.x.x.x> + + + + + + Show details of LSAs + + vtysh -c "show ipv6 ospf6 database as-external linkstate-id $7 detail" + + + + Show dump of LSAs + + vtysh -c "show ipv6 ospf6 database as-external linkstate-id $7 dump" + + + + Show LSAs internal information + + vtysh -c "show ipv6 ospf6 database as-external linkstate-id $7 internal" + + + + + + Show Self-originated LSAs + + vtysh -c "show ipv6 ospf6 database as-external self-originated" + + + + Show details of LSAs + + vtysh -c "show ipv6 ospf6 database as-external self-originated detail" + + + + Show dump of LSAs + + vtysh -c "show ipv6 ospf6 database as-external self-originated dump" + + + + Show LSAs internal information + + vtysh -c "show ipv6 ospf6 database as-external self-originated internal" + + + + Search by Link state ID + + <x.x.x.x> + + + + + + Show details of LSAs + + vtysh -c "show ipv6 ospf6 database as-external self-originated linkstate-id $8 detail" + + + + Show dump of LSAs + + vtysh -c "show ipv6 ospf6 database as-external self-originated linkstate-id $8 dump" + + + + Show LSAs internal information + + vtysh -c "show ipv6 ospf6 database as-external self-originated linkstate-id $8 internal" + + + + + + + + + + Search by Advertising Router IDs + + <x.x.x.x> + + + + + + Show details of LSAs + + vtysh -c "show ipv6 ospf6 database as-external $6 detail" + + + + Show dump of LSAs + + vtysh -c "show ipv6 ospf6 database as-external $6 dump" + + + + Show LSAs internal information + + vtysh -c "show ipv6 ospf6 database as-external $6 internal" + + + + Show Self-originated LSAs + + vtysh -c "show ipv6 ospf6 database as-external $6 self-originated" + + + + Show details of LSAs + + vtysh -c "show ipv6 ospf6 database as-external $6 self-originated detail" + + + + Show dump of LSAs + + vtysh -c "show ipv6 ospf6 database as-external $6 self-originated dump" + + + + Show LSAs internal information + + vtysh -c "show ipv6 ospf6 database as-external $6 self-originated internal" + + + + + + Search by Advertising Router ID + + <x.x.x.x> + + + + + + Show dump of LSAs + + echo vtysh -c "show ipv6 ospf6 database as-external $6 $7 dump" + + + + Show LSAs internal information + + echo vtysh -c "show ipv6 ospf6 database as-external $6 $7 internal" + + + + + + + + Show details of LSAs + + vtysh -c "show ipv6 ospf6 database detail" + + + + Show dump of LSAs + + vtysh -c "show ipv6 ospf6 database dump" + + + + Search by Link state ID + + <x.x.x.x> + + + + + + Show details of LSAs + + vtysh -c "show ipv6 ospf6 database linkstate-id $6 detail" + + + + Show dump of LSAs + + vtysh -c "show ipv6 ospf6 database linkstate-id $6 dump" + + + + Show LSAs internal information + + vtysh -c "show ipv6 ospf6 database linkstate-id $6 internal" + + + + + + Show Self-originated LSAs + + vtysh -c "show ipv6 ospf6 database self-originated" + + + + Show details of LSAs + + vtysh -c "show ipv6 ospf6 database self-originated detail" + + + + Show dump of LSAs + + vtysh -c "show ipv6 ospf6 database self-originated dump" + + + + Show LSAs internal information + + vtysh -c "show ipv6 ospf6 database self-originated internal" + + + + + + + + Show OSPFv3 interface information + + vtysh -c "show ipv6 ospf6 interface" + + + + Show connected prefixes to advertise + + vtysh -c "show ipv6 ospf6 interface prefix" + + + + More detailed interface prefix information + + vtysh -c "show ipv6 ospf6 interface prefix detail" + + + + + + Show interface prefix route specific information + + <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> + + + vtysh -c "show ipv6 ospf6 interface prefix $6" + + + + More detailed information + + vtysh -c "show ipv6 ospf6 interface prefix $6 detail" + + + + Matched interface prefix information + + vtysh -c "show ipv6 ospf6 interface prefix $6 match" + + + + + + + + Specific insterface to examine + + + + + vtysh -c "show ipv6 ospf6 interface $5" + + + + Show connected prefixes to advertise + + vtysh -c "show ipv6 ospf6 interface $5 prefix" + + + + More detailed interface prefix information + + vtysh -c "show ipv6 ospf6 interface $5 prefix detail" + + + + + + Show interface prefix route specific information + + <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> + + + vtysh -c "show ipv6 ospf6 interface $5 prefix $7" + + + + More detailed information + + vtysh -c "show ipv6 ospf6 interface $5 prefix $7 detail" + + + + Matched interface prefix information + + vtysh -c "show ipv6 ospf6 interface $5 prefix $7 match" + + + + + + + + Show OSPFv3 linkstate routing information + + + + + Show detailed linkstate information + + vtysh -c "show ipv6 ospf6 linkstate detail" + + + + Show linkstate Network information + + vtysh -c "show ipv6 ospf6 linkstate network" + + + + Show linkstate Router information + + vtysh -c "show ipv6 ospf6 linkstate router" + + + + + + Show OSPFv3 neighbor information + + vtysh -c "show ipv6 ospf6 neighbor" + + + + Show detailed neighbor information + + vtysh -c "show ipv6 ospf6 neighbor detail" + + + + Show neighbor DR choice information + + vtysh -c "show ipv6 ospf6 neighbor drchoice" + + + + + + Show OSPFv3 redistribute external information + + vtysh -c "show ipv6 ospf6 redistribute" + + + + Show OSPFv3 routing table information + + vtysh -c "show ipv6 ospf6 route" + + + + Show Type-1 External route information + + vtysh -c "show ipv6 ospf6 route external-1" + + + + Show detailed Type-1 External route information + + vtysh -c "show ipv6 ospf6 route external-1 detail" + + + + + + Show Type-2 External route information + + vtysh -c "show ipv6 ospf6 route external-2" + + + + Show detailed Type-2 External route information + + vtysh -c "show ipv6 ospf6 route external-2 detail" + + + + + + Show Inter-Area route information + + vtysh -c "show ipv6 ospf6 route inter-area" + + + + Show detailed Inter-Area route information + + vtysh -c "show ipv6 ospf6 route inter-area detail" + + + + + + Show Intra-Area route information + + vtysh -c "show ipv6 ospf6 route intra-area" + + + + Show detailed Intra-Area route information + + vtysh -c "show ipv6 ospf6 route intra-area detail" + + + + + + Show detailed route information + + vtysh -c "show ipv6 ospf6 route detail" + + + + Show route table summary + + vtysh -c "show ipv6 ospf6 route summary" + + + + + + Show specified route/prefix information + + <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> + + + vtysh -c "show ipv6 ospf6 route $5" + + + + Show routes longer than specified prefix + + vtysh -c "show ipv6 ospf6 route $5 longer" + + + + Show routes matching specified prefix + + vtysh -c "show ipv6 ospf6 route $5 match" + + + + Detailed information + + vtysh -c "show ipv6 ospf6 route $5 match detail" + + + + + + + + + + + + diff --git a/op-mode-definitions/show-ipv6-prefix-list.xml b/op-mode-definitions/show-ipv6-prefix-list.xml deleted file mode 100644 index e003ad110..000000000 --- a/op-mode-definitions/show-ipv6-prefix-list.xml +++ /dev/null @@ -1,92 +0,0 @@ - - - - - - - Show IPv6 routing information - - - - - Show IPv6 prefix-lists - - vtysh -c "show ipv6 prefix-list" - - - - Show detail of IPv6 prefix-lists - - vtysh -c "show ipv6 prefix-list detail" - - - - Show detail of specified IPv6 prefix-list - - vtysh -c "show ipv6 prefix-list detail $5" - - - - Show summary of IPv6 prefix-lists - - vtysh -c "show ipv6 prefix-list summary" - - - - Show summary of specified IPv6 prefix-list - - vtysh -c "show ipv6 prefix-list summary $5" - - - - - - Show specified IPv6 prefix-list - - WORD - - - vtysh -c "show ipv6 prefix-list $4" - - - - Show select prefix of specified IPv6 prefix-list - - <h:h:h:h:h:h:h:h/x> - - - vtysh -c "show ipv6 prefix-list $4 $5" - - - - Show first-match from select prefix of named IPv6 prefix-list - - vtysh -c "show ipv6 prefix-list $4 $5 first-match" - - - - Show longer match of select prefix from named IPv6 prefix-list - - vtysh -c "show ipv6 prefix-list $4 $5 longer" - - - - - - Show specified sequence from specified IPv6 prefix-list - - vtysh -c "show ipv6 prefix-list $4 seq" - - - - Show specified sequence from specified IPv6 prefix-list - - vtysh -c "show ipv6 prefix-list $4 seq $6" - - - - - - - - diff --git a/op-mode-definitions/show-ipv6-prefix-list.xml.in b/op-mode-definitions/show-ipv6-prefix-list.xml.in new file mode 100644 index 000000000..e003ad110 --- /dev/null +++ b/op-mode-definitions/show-ipv6-prefix-list.xml.in @@ -0,0 +1,92 @@ + + + + + + + Show IPv6 routing information + + + + + Show IPv6 prefix-lists + + vtysh -c "show ipv6 prefix-list" + + + + Show detail of IPv6 prefix-lists + + vtysh -c "show ipv6 prefix-list detail" + + + + Show detail of specified IPv6 prefix-list + + vtysh -c "show ipv6 prefix-list detail $5" + + + + Show summary of IPv6 prefix-lists + + vtysh -c "show ipv6 prefix-list summary" + + + + Show summary of specified IPv6 prefix-list + + vtysh -c "show ipv6 prefix-list summary $5" + + + + + + Show specified IPv6 prefix-list + + WORD + + + vtysh -c "show ipv6 prefix-list $4" + + + + Show select prefix of specified IPv6 prefix-list + + <h:h:h:h:h:h:h:h/x> + + + vtysh -c "show ipv6 prefix-list $4 $5" + + + + Show first-match from select prefix of named IPv6 prefix-list + + vtysh -c "show ipv6 prefix-list $4 $5 first-match" + + + + Show longer match of select prefix from named IPv6 prefix-list + + vtysh -c "show ipv6 prefix-list $4 $5 longer" + + + + + + Show specified sequence from specified IPv6 prefix-list + + vtysh -c "show ipv6 prefix-list $4 seq" + + + + Show specified sequence from specified IPv6 prefix-list + + vtysh -c "show ipv6 prefix-list $4 seq $6" + + + + + + + + diff --git a/op-mode-definitions/show-ipv6-route.xml b/op-mode-definitions/show-ipv6-route.xml deleted file mode 100644 index fafd615ea..000000000 --- a/op-mode-definitions/show-ipv6-route.xml +++ /dev/null @@ -1,117 +0,0 @@ - - - - - - - Show IPv6 routing information - - - - - Show IPv6 routes of given address or prefix - - <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> - - - - - - Show longer prefixes of routes for given address or prefix - - vtysh -c "show ipv6 route $4 longer-prefixes" - - - vtysh -c "show ipv6 route $4" - - - - Show IPv6 routes - - vtysh -c "show ipv6 route" - - - - Show IPv6 BGP routes - - vtysh -c "show ipv6 route bgp" - - - - Show IPv6 connected routes - - vtysh -c "show ipv6 route connected" - - - - Show IPv6 IS-IS routes - - vtysh -c "show ipv6 route isis" - - - - Show IPv6 Kernel routes - - vtysh -c "show ipv6 route kernel" - - - - Show IPv6 OSPF routes - - vtysh -c "show ipv6 route ospf6" - - - - Show IPv6 RIPNG routes - - vtysh -c "show ipv6 route ripng" - - - - Show IPv6 static routes - - vtysh -c "show ipv6 route static" - - - - Show IPv6 routes summary - - vtysh -c "show ipv6 route summary" - - - - Show IPv6 routes in policy tables - - vtysh -c "show ipv6 route table all" - - - - Show IPv6 routes in specific policy table - - protocols static table - - - vtysh -c "show ipv6 route table $5" - - - - Show IPv6 routes in VRFs - - vtysh -c "show ipv6 route vrf all" - - - - Show IPv6 routes in specific VRF - - vrf name - - - vtysh -c "show ipv6 route vrf $5" - - - - - - - - diff --git a/op-mode-definitions/show-ipv6-route.xml.in b/op-mode-definitions/show-ipv6-route.xml.in new file mode 100644 index 000000000..fafd615ea --- /dev/null +++ b/op-mode-definitions/show-ipv6-route.xml.in @@ -0,0 +1,117 @@ + + + + + + + Show IPv6 routing information + + + + + Show IPv6 routes of given address or prefix + + <h:h:h:h:h:h:h:h> <h:h:h:h:h:h:h:h/x> + + + + + + Show longer prefixes of routes for given address or prefix + + vtysh -c "show ipv6 route $4 longer-prefixes" + + + vtysh -c "show ipv6 route $4" + + + + Show IPv6 routes + + vtysh -c "show ipv6 route" + + + + Show IPv6 BGP routes + + vtysh -c "show ipv6 route bgp" + + + + Show IPv6 connected routes + + vtysh -c "show ipv6 route connected" + + + + Show IPv6 IS-IS routes + + vtysh -c "show ipv6 route isis" + + + + Show IPv6 Kernel routes + + vtysh -c "show ipv6 route kernel" + + + + Show IPv6 OSPF routes + + vtysh -c "show ipv6 route ospf6" + + + + Show IPv6 RIPNG routes + + vtysh -c "show ipv6 route ripng" + + + + Show IPv6 static routes + + vtysh -c "show ipv6 route static" + + + + Show IPv6 routes summary + + vtysh -c "show ipv6 route summary" + + + + Show IPv6 routes in policy tables + + vtysh -c "show ipv6 route table all" + + + + Show IPv6 routes in specific policy table + + protocols static table + + + vtysh -c "show ipv6 route table $5" + + + + Show IPv6 routes in VRFs + + vtysh -c "show ipv6 route vrf all" + + + + Show IPv6 routes in specific VRF + + vrf name + + + vtysh -c "show ipv6 route vrf $5" + + + + + + + + diff --git a/op-mode-definitions/show-ipv6.xml b/op-mode-definitions/show-ipv6.xml deleted file mode 100644 index a59c8df0c..000000000 --- a/op-mode-definitions/show-ipv6.xml +++ /dev/null @@ -1,49 +0,0 @@ - - - - - - - Show IPv6 routing information - - - - - Show all IPv6 access-lists - - vtysh -c "show ipv6 access-list" - - - - Show specified IPv6 access-list - - WORD - - - vtysh -c "show ipv6 access-list $4" - - - - Show IPv6 forwarding status - - vtysh -c "show ipv6 forwarding" - - - - Show RIPNG protocol information - - vtysh -c "show ipv6 ripng" - - - - Show RIPNG protocol status - - vtysh -c "show ipv6 ripng status" - - - - - - - - diff --git a/op-mode-definitions/show-ipv6.xml.in b/op-mode-definitions/show-ipv6.xml.in new file mode 100644 index 000000000..a59c8df0c --- /dev/null +++ b/op-mode-definitions/show-ipv6.xml.in @@ -0,0 +1,49 @@ + + + + + + + Show IPv6 routing information + + + + + Show all IPv6 access-lists + + vtysh -c "show ipv6 access-list" + + + + Show specified IPv6 access-list + + WORD + + + vtysh -c "show ipv6 access-list $4" + + + + Show IPv6 forwarding status + + vtysh -c "show ipv6 forwarding" + + + + Show RIPNG protocol information + + vtysh -c "show ipv6 ripng" + + + + Show RIPNG protocol status + + vtysh -c "show ipv6 ripng status" + + + + + + + + diff --git a/op-mode-definitions/show-isis.xml b/op-mode-definitions/show-isis.xml deleted file mode 100644 index 4e308730f..000000000 --- a/op-mode-definitions/show-isis.xml +++ /dev/null @@ -1,191 +0,0 @@ - - - - - - - IS-IS routing protocol - - - - - Show IS-IS link state database - - - - - Show detailed information - - /usr/bin/vtysh -c "show isis database detail" - - - /usr/bin/vtysh -c "show isis database" - - - - Show IS-IS link state database PDU - - lsp-id detail - - - /usr/bin/vtysh -c "show isis database $4" - - - - Show IS-IS dynamic hostname mapping - - /usr/bin/vtysh -c "show isis hostname" - - - - Show IS-IS interfaces - - - - - - - - Show detailed information - - /usr/bin/vtysh -c "show isis interface detail" - - - /usr/bin/vtysh -c "show isis interface" - - - - Show specific IS-IS interface - - - - - /usr/bin/vtysh -c "show isis interface $4" - - - - Show IS-IS MPLS traffic engineering information - - - - - Show router information - - /usr/bin/vtysh -c "show isis mpls-te router" - - - - Show interface information - - /usr/bin/vtysh -c "show isis mpls-te interface" - - - - Show specific IS-IS interface - - - - - /usr/bin/vtysh -c "show isis mpls-te interface $5" - - - - - - Show IS-IS neighbor adjacencies - - - - - Show detailed information - - /usr/bin/vtysh -c "show isis neighbor detail" - - - /usr/bin/vtysh -c "show isis neighbor" - - - - Show specific IS-IS neighbor adjacency - - system-id - - - /usr/bin/vtysh -c "show isis neighbor $4" - - - - Show IS-IS routing table - - - - - Show level-1 routes - - /usr/bin/vtysh -c "show isis route level-1" - - - - Show level-2 routes - - /usr/bin/vtysh -c "show isis route level-2" - - - /usr/bin/vtysh -c "show isis route" - - - - Show IS-IS Segment-Routing (SPRING) information - - - - - Show node information - - /usr/bin/vtysh -c "show isis segment-routing node" - - - - Show prefix segment IDs - - /usr/bin/vtysh -c "show isis segment-routing prefix-sids" - - - - - - Show IS-IS SPF delay parameters - - /usr/bin/vtysh -c "show isis spf-delay-ietf" - - - - Show IS-IS information summary - - /usr/bin/vtysh -c "show isis summary" - - - - Show IS-IS paths to Intermediate Systems - - - - - Show level-1 routes - - /usr/bin/vtysh -c "show isis topology level-1" - - - - Show level-2 routes - - /usr/bin/vtysh -c "show isis topology level-2" - - - /usr/bin/vtysh -c "show isis topology" - - - - - - diff --git a/op-mode-definitions/show-isis.xml.in b/op-mode-definitions/show-isis.xml.in new file mode 100644 index 000000000..4e308730f --- /dev/null +++ b/op-mode-definitions/show-isis.xml.in @@ -0,0 +1,191 @@ + + + + + + + IS-IS routing protocol + + + + + Show IS-IS link state database + + + + + Show detailed information + + /usr/bin/vtysh -c "show isis database detail" + + + /usr/bin/vtysh -c "show isis database" + + + + Show IS-IS link state database PDU + + lsp-id detail + + + /usr/bin/vtysh -c "show isis database $4" + + + + Show IS-IS dynamic hostname mapping + + /usr/bin/vtysh -c "show isis hostname" + + + + Show IS-IS interfaces + + + + + + + + Show detailed information + + /usr/bin/vtysh -c "show isis interface detail" + + + /usr/bin/vtysh -c "show isis interface" + + + + Show specific IS-IS interface + + + + + /usr/bin/vtysh -c "show isis interface $4" + + + + Show IS-IS MPLS traffic engineering information + + + + + Show router information + + /usr/bin/vtysh -c "show isis mpls-te router" + + + + Show interface information + + /usr/bin/vtysh -c "show isis mpls-te interface" + + + + Show specific IS-IS interface + + + + + /usr/bin/vtysh -c "show isis mpls-te interface $5" + + + + + + Show IS-IS neighbor adjacencies + + + + + Show detailed information + + /usr/bin/vtysh -c "show isis neighbor detail" + + + /usr/bin/vtysh -c "show isis neighbor" + + + + Show specific IS-IS neighbor adjacency + + system-id + + + /usr/bin/vtysh -c "show isis neighbor $4" + + + + Show IS-IS routing table + + + + + Show level-1 routes + + /usr/bin/vtysh -c "show isis route level-1" + + + + Show level-2 routes + + /usr/bin/vtysh -c "show isis route level-2" + + + /usr/bin/vtysh -c "show isis route" + + + + Show IS-IS Segment-Routing (SPRING) information + + + + + Show node information + + /usr/bin/vtysh -c "show isis segment-routing node" + + + + Show prefix segment IDs + + /usr/bin/vtysh -c "show isis segment-routing prefix-sids" + + + + + + Show IS-IS SPF delay parameters + + /usr/bin/vtysh -c "show isis spf-delay-ietf" + + + + Show IS-IS information summary + + /usr/bin/vtysh -c "show isis summary" + + + + Show IS-IS paths to Intermediate Systems + + + + + Show level-1 routes + + /usr/bin/vtysh -c "show isis topology level-1" + + + + Show level-2 routes + + /usr/bin/vtysh -c "show isis topology level-2" + + + /usr/bin/vtysh -c "show isis topology" + + + + + + diff --git a/op-mode-definitions/show-license.xml b/op-mode-definitions/show-license.xml deleted file mode 100644 index 2ce11567d..000000000 --- a/op-mode-definitions/show-license.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - Show VyOS license information - - less $_vyatta_less_options --prompt=".license, page %dt of %D" -- ${vyatta_sysconfdir}/LICENSE - - - - diff --git a/op-mode-definitions/show-license.xml.in b/op-mode-definitions/show-license.xml.in new file mode 100644 index 000000000..2ce11567d --- /dev/null +++ b/op-mode-definitions/show-license.xml.in @@ -0,0 +1,13 @@ + + + + + + + Show VyOS license information + + less $_vyatta_less_options --prompt=".license, page %dt of %D" -- ${vyatta_sysconfdir}/LICENSE + + + + diff --git a/op-mode-definitions/show-log.xml b/op-mode-definitions/show-log.xml deleted file mode 100644 index b00e4cfec..000000000 --- a/op-mode-definitions/show-log.xml +++ /dev/null @@ -1,218 +0,0 @@ - - - - - - - Show contents of current master log file - - /bin/journalctl - - - - Show contents of all master log files - - eval $(lesspipe); less $_vyatta_less_options --prompt=".log?m, file %i of %m., page %dt of %D" -- `printf "%s\n" /var/log/messages* | sort -nr` - - - - Show listing of authorization attempts - - /bin/journalctl -q SYSLOG_FACILITY=10 SYSLOG_FACILITY=4 - - - - Show log for Cluster - - cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e heartbeat -e cl_status -e mach_down -e ha_log - - - - Show log for Conntrack-sync - - cat $(printf "%s\n" /var/log/messages* | sort -nr ) | grep -e conntrackd - - - - Show log for Dynamic Host Control Protocol (DHCP) - - cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep dhcpd - - - - Show log for Firewall - - - - - Show log for a specified firewall (IPv6) - - firewall ipv6-name - - - cat $(printf "%s\n" /var/log/messages* | sort -nr ) | egrep "\[$5-([0-9]+|default)-[ADR]\]" - - - - Show log for a rule in the specified firewall - - firewall ipv6-name ${COMP_WORDS[4]} rule - - - cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e "\[$5-$7-[ADR]\]" - - - - - - Show log for a specified firewall (IPv4) - - firewall name - - - cat $(printf "%s\n" /var/log/messages* | sort -nr ) | egrep "\[$5-([0-9]+|default)-[ADR]\]" - - - - Show log for a rule in the specified firewall - - firewall name ${COMP_WORDS[4]} rule - - - cat $(printf "%s\n" /var/log/messages* | sort -nr) | egrep "\[$5-$7-[ADR]\]" - - - - - - - - Show log for HTTPs - - cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e nginx - - - - Show contents of master log file for image - - - - - less $_vyatta_less_options --prompt=".log, page %dt of %D" -- /lib/live/mount/persistence/boot/$4/rw/var/log/messages - - - - Show contents of all master log files for image - - eval $(lesspipe); less $_vyatta_less_options --prompt=".log?m, file %i of %m., page %dt of %D" -- `printf "%s\n" /lib/live/mount/persistence/boot/$4/rw/var/log/messages* | sort -nr` - - - - Show listing of authorization attempts for image - - less $_vyatta_less_options --prompt=".log, page %dt of %D" -- /lib/live/mount/persistence/boot/$4/rw/var/log/auth.log - - - - Show last changes to messages - - <NUMBER> - - - tail -n "$6" /lib/live/mount/persistence/boot/$4/rw/var/log/messages | ${VYATTA_PAGER:-cat} - - - - - - Show log for LLDP - - cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e lldpd - - - - Show log for Network Address Translation (NAT) - - egrep -i "kernel:.*\[NAT-[A-Z]{3,}-[0-9]+(-MASQ)?\]" $(find /var/log -maxdepth 1 -type f -name messages\* | sort -t. -k2nr) - - - - Show log for OpenVPN - - cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e openvpn - - - - Show log for Simple Network Monitoring Protocol (SNMP) - - cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e snmpd - - - - Show last n changes to messages - - <NUMBER> - - - tail -n "$4" /var/log/messages | ${VYATTA_PAGER:-cat} - - - - Show last 10 lines of /var/log/messages file - - tail -n 10 /var/log/messages - - - - Show log for Virtual Private Network (VPN) - - - - - Show log for ALL - - cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e charon -e accel -e pptpd -e ppp - - - - Show log for IPSec - - cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e charon - - - - Show log for L2TP - - cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e remote-access-aaa-win -e remote-access-zzz-mac -e accel-l2tp -e ppp - - - - Show log for PPTP - - cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e accel-pptp -e ppp - - - - Show log for SSTP - - cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e accel-sstp -e ppp - - - - - - Show log for Virtual Router Redundancy Protocol (VRRP) - - cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e Keepalived_vrrp - - - - Show log for Webproxy - - cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e "squid" - - - - - - diff --git a/op-mode-definitions/show-log.xml.in b/op-mode-definitions/show-log.xml.in new file mode 100644 index 000000000..b00e4cfec --- /dev/null +++ b/op-mode-definitions/show-log.xml.in @@ -0,0 +1,218 @@ + + + + + + + Show contents of current master log file + + /bin/journalctl + + + + Show contents of all master log files + + eval $(lesspipe); less $_vyatta_less_options --prompt=".log?m, file %i of %m., page %dt of %D" -- `printf "%s\n" /var/log/messages* | sort -nr` + + + + Show listing of authorization attempts + + /bin/journalctl -q SYSLOG_FACILITY=10 SYSLOG_FACILITY=4 + + + + Show log for Cluster + + cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e heartbeat -e cl_status -e mach_down -e ha_log + + + + Show log for Conntrack-sync + + cat $(printf "%s\n" /var/log/messages* | sort -nr ) | grep -e conntrackd + + + + Show log for Dynamic Host Control Protocol (DHCP) + + cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep dhcpd + + + + Show log for Firewall + + + + + Show log for a specified firewall (IPv6) + + firewall ipv6-name + + + cat $(printf "%s\n" /var/log/messages* | sort -nr ) | egrep "\[$5-([0-9]+|default)-[ADR]\]" + + + + Show log for a rule in the specified firewall + + firewall ipv6-name ${COMP_WORDS[4]} rule + + + cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e "\[$5-$7-[ADR]\]" + + + + + + Show log for a specified firewall (IPv4) + + firewall name + + + cat $(printf "%s\n" /var/log/messages* | sort -nr ) | egrep "\[$5-([0-9]+|default)-[ADR]\]" + + + + Show log for a rule in the specified firewall + + firewall name ${COMP_WORDS[4]} rule + + + cat $(printf "%s\n" /var/log/messages* | sort -nr) | egrep "\[$5-$7-[ADR]\]" + + + + + + + + Show log for HTTPs + + cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e nginx + + + + Show contents of master log file for image + + + + + less $_vyatta_less_options --prompt=".log, page %dt of %D" -- /lib/live/mount/persistence/boot/$4/rw/var/log/messages + + + + Show contents of all master log files for image + + eval $(lesspipe); less $_vyatta_less_options --prompt=".log?m, file %i of %m., page %dt of %D" -- `printf "%s\n" /lib/live/mount/persistence/boot/$4/rw/var/log/messages* | sort -nr` + + + + Show listing of authorization attempts for image + + less $_vyatta_less_options --prompt=".log, page %dt of %D" -- /lib/live/mount/persistence/boot/$4/rw/var/log/auth.log + + + + Show last changes to messages + + <NUMBER> + + + tail -n "$6" /lib/live/mount/persistence/boot/$4/rw/var/log/messages | ${VYATTA_PAGER:-cat} + + + + + + Show log for LLDP + + cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e lldpd + + + + Show log for Network Address Translation (NAT) + + egrep -i "kernel:.*\[NAT-[A-Z]{3,}-[0-9]+(-MASQ)?\]" $(find /var/log -maxdepth 1 -type f -name messages\* | sort -t. -k2nr) + + + + Show log for OpenVPN + + cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e openvpn + + + + Show log for Simple Network Monitoring Protocol (SNMP) + + cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e snmpd + + + + Show last n changes to messages + + <NUMBER> + + + tail -n "$4" /var/log/messages | ${VYATTA_PAGER:-cat} + + + + Show last 10 lines of /var/log/messages file + + tail -n 10 /var/log/messages + + + + Show log for Virtual Private Network (VPN) + + + + + Show log for ALL + + cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e charon -e accel -e pptpd -e ppp + + + + Show log for IPSec + + cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e charon + + + + Show log for L2TP + + cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e remote-access-aaa-win -e remote-access-zzz-mac -e accel-l2tp -e ppp + + + + Show log for PPTP + + cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e accel-pptp -e ppp + + + + Show log for SSTP + + cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e accel-sstp -e ppp + + + + + + Show log for Virtual Router Redundancy Protocol (VRRP) + + cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e Keepalived_vrrp + + + + Show log for Webproxy + + cat $(printf "%s\n" /var/log/messages* | sort -nr) | grep -e "squid" + + + + + + diff --git a/op-mode-definitions/show-login.xml b/op-mode-definitions/show-login.xml deleted file mode 100644 index 6d8c782c4..000000000 --- a/op-mode-definitions/show-login.xml +++ /dev/null @@ -1,33 +0,0 @@ - - - - - - - Show current login credentials - - ${vyos_op_scripts_dir}/show_current_user.sh - - - - Show current login group information - - /usr/bin/id -Gn - - - - Show current login level - - if [ -n "$VYATTA_USER_LEVEL_DIR" ]; then basename $VYATTA_USER_LEVEL_DIR; fi - - - - Show current login user id - - /usr/bin/id -un - - - - - - diff --git a/op-mode-definitions/show-login.xml.in b/op-mode-definitions/show-login.xml.in new file mode 100644 index 000000000..6d8c782c4 --- /dev/null +++ b/op-mode-definitions/show-login.xml.in @@ -0,0 +1,33 @@ + + + + + + + Show current login credentials + + ${vyos_op_scripts_dir}/show_current_user.sh + + + + Show current login group information + + /usr/bin/id -Gn + + + + Show current login level + + if [ -n "$VYATTA_USER_LEVEL_DIR" ]; then basename $VYATTA_USER_LEVEL_DIR; fi + + + + Show current login user id + + /usr/bin/id -un + + + + + + diff --git a/op-mode-definitions/show-monitoring.xml b/op-mode-definitions/show-monitoring.xml deleted file mode 100644 index 2651b3438..000000000 --- a/op-mode-definitions/show-monitoring.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - Show currently monitored services - - vtysh -c "show debugging" - - - - diff --git a/op-mode-definitions/show-monitoring.xml.in b/op-mode-definitions/show-monitoring.xml.in new file mode 100644 index 000000000..2651b3438 --- /dev/null +++ b/op-mode-definitions/show-monitoring.xml.in @@ -0,0 +1,13 @@ + + + + + + + Show currently monitored services + + vtysh -c "show debugging" + + + + diff --git a/op-mode-definitions/show-mpls.xml b/op-mode-definitions/show-mpls.xml deleted file mode 100644 index 833ac98eb..000000000 --- a/op-mode-definitions/show-mpls.xml +++ /dev/null @@ -1,218 +0,0 @@ - - - - - - - Show Multiprotocol Label Switching (MPLS) - - - - - Label Distribution Protocol (LDP) - - - - - Label Information Base - - /usr/bin/vtysh -c "show mpls ldp binding" - - - - Show detailed information - - /usr/bin/vtysh -c "show mpls ldp binding detail" - - - - Display labels from LDP neighbor - - <x.x.x.x> <h:h:h:h:h:h:h:h> - - - - /usr/bin/vtysh -c "show mpls ldp binding neighbor $6" - - - - Show detailed information - - /usr/bin/vtysh -c "show mpls ldp binding neighbor $6 detail" - - - - Match locally assigned label value - - /usr/bin/vtysh -c "show mpls ldp binding neighbor $6 local-label $8" - - - - Match remotely assigned label value - - /usr/bin/vtysh -c "show mpls ldp binding neighbor $6 remote-label $8" - - - - - - Match locally assigned label value - - /usr/bin/vtysh -c "show mpls ldp binding local-label $6" - - - - Show detailed information - - /usr/bin/vtysh -c "show mpls ldp binding local-label $6 detail" - - - - Match LDP neighbor - - <x.x.x.x> <h:h:h:h:h:h:h:h> - - - - /usr/bin/vtysh -c "show mpls ldp binding local-label $6 neighbor $8" - - - - Match remotely assigned label value - - /usr/bin/vtysh -c "show mpls ldp binding local-label $6 remote-label $8" - - - - - - Match remotely assigned label value - - /usr/bin/vtysh -c "show mpls ldp binding remote-label $6" - - - - Show detailed information - - /usr/bin/vtysh -c "show mpls ldp binding remote-label $6 detail" - - - - Match LDP neighbor - - <x.x.x.x> <h:h:h:h:h:h:h:h> - - - - /usr/bin/vtysh -c "show mpls ldp binding remote-label $6 neighbor $8" - - - - Match locally assigned label value - - /usr/bin/vtysh -c "show mpls ldp binding remote-label $6 local-label $8" - - - - - - - - LDP forwarding equivalence class - - <x.x.x.x/x> <h:h:h:h:h:h:h:h/h> - - - /usr/bin/vtysh -c "show mpls ldp binding $5" - - - - Show detailed information - - /usr/bin/vtysh -c "show mpls ldp binding $5 detail" - - - - - - Discovery hello information - - /usr/bin/vtysh -c "show mpls ldp discovery" - - - - Show detailed information - - /usr/bin/vtysh -c "show mpls ldp discovery detail" - - - - - - LDP interface information - - /usr/bin/vtysh -c "show mpls ldp interface" - - - - LDP neighbor information - - /usr/bin/vtysh -c "show mpls ldp neighbor" - - - - Show detailed information - - /usr/bin/vtysh -c "show mpls ldp neighbor detail" - - - - Show neighbor capability information - - /usr/bin/vtysh -c "show mpls ldp neighbor capabilities" - - - - - - LDP neighbor - - <x.x.x.x> <h:h:h:h:h:h:h:h> - - - - /usr/bin/vtysh -c "show mpls ldp neighbor $5" - - - - Show detailed information - - /usr/bin/vtysh -c "show mpls ldp neighbor $5 detail" - - - - Show neighbor capability information - - /usr/bin/vtysh -c "show mpls ldp neighbor $5 capabilities" - - - - - - - - Show MPLS pseudowire interfaces - - /usr/bin/vtysh -c "show mpls pseudowires" - - - - Show MPLS table - - /usr/bin/vtysh -c "show mpls table" - - - - - - diff --git a/op-mode-definitions/show-mpls.xml.in b/op-mode-definitions/show-mpls.xml.in new file mode 100644 index 000000000..833ac98eb --- /dev/null +++ b/op-mode-definitions/show-mpls.xml.in @@ -0,0 +1,218 @@ + + + + + + + Show Multiprotocol Label Switching (MPLS) + + + + + Label Distribution Protocol (LDP) + + + + + Label Information Base + + /usr/bin/vtysh -c "show mpls ldp binding" + + + + Show detailed information + + /usr/bin/vtysh -c "show mpls ldp binding detail" + + + + Display labels from LDP neighbor + + <x.x.x.x> <h:h:h:h:h:h:h:h> + + + + /usr/bin/vtysh -c "show mpls ldp binding neighbor $6" + + + + Show detailed information + + /usr/bin/vtysh -c "show mpls ldp binding neighbor $6 detail" + + + + Match locally assigned label value + + /usr/bin/vtysh -c "show mpls ldp binding neighbor $6 local-label $8" + + + + Match remotely assigned label value + + /usr/bin/vtysh -c "show mpls ldp binding neighbor $6 remote-label $8" + + + + + + Match locally assigned label value + + /usr/bin/vtysh -c "show mpls ldp binding local-label $6" + + + + Show detailed information + + /usr/bin/vtysh -c "show mpls ldp binding local-label $6 detail" + + + + Match LDP neighbor + + <x.x.x.x> <h:h:h:h:h:h:h:h> + + + + /usr/bin/vtysh -c "show mpls ldp binding local-label $6 neighbor $8" + + + + Match remotely assigned label value + + /usr/bin/vtysh -c "show mpls ldp binding local-label $6 remote-label $8" + + + + + + Match remotely assigned label value + + /usr/bin/vtysh -c "show mpls ldp binding remote-label $6" + + + + Show detailed information + + /usr/bin/vtysh -c "show mpls ldp binding remote-label $6 detail" + + + + Match LDP neighbor + + <x.x.x.x> <h:h:h:h:h:h:h:h> + + + + /usr/bin/vtysh -c "show mpls ldp binding remote-label $6 neighbor $8" + + + + Match locally assigned label value + + /usr/bin/vtysh -c "show mpls ldp binding remote-label $6 local-label $8" + + + + + + + + LDP forwarding equivalence class + + <x.x.x.x/x> <h:h:h:h:h:h:h:h/h> + + + /usr/bin/vtysh -c "show mpls ldp binding $5" + + + + Show detailed information + + /usr/bin/vtysh -c "show mpls ldp binding $5 detail" + + + + + + Discovery hello information + + /usr/bin/vtysh -c "show mpls ldp discovery" + + + + Show detailed information + + /usr/bin/vtysh -c "show mpls ldp discovery detail" + + + + + + LDP interface information + + /usr/bin/vtysh -c "show mpls ldp interface" + + + + LDP neighbor information + + /usr/bin/vtysh -c "show mpls ldp neighbor" + + + + Show detailed information + + /usr/bin/vtysh -c "show mpls ldp neighbor detail" + + + + Show neighbor capability information + + /usr/bin/vtysh -c "show mpls ldp neighbor capabilities" + + + + + + LDP neighbor + + <x.x.x.x> <h:h:h:h:h:h:h:h> + + + + /usr/bin/vtysh -c "show mpls ldp neighbor $5" + + + + Show detailed information + + /usr/bin/vtysh -c "show mpls ldp neighbor $5 detail" + + + + Show neighbor capability information + + /usr/bin/vtysh -c "show mpls ldp neighbor $5 capabilities" + + + + + + + + Show MPLS pseudowire interfaces + + /usr/bin/vtysh -c "show mpls pseudowires" + + + + Show MPLS table + + /usr/bin/vtysh -c "show mpls table" + + + + + + diff --git a/op-mode-definitions/show-ntp.xml b/op-mode-definitions/show-ntp.xml deleted file mode 100644 index b7f0acdf8..000000000 --- a/op-mode-definitions/show-ntp.xml +++ /dev/null @@ -1,31 +0,0 @@ - - - - - - - Show peer status of NTP daemon - - if ps -C ntpd &>/dev/null; then ntpq -n -c peers; else echo NTP daemon disabled; fi - - - - Show date and time of specified NTP server - - - - - /usr/sbin/ntpdate -q "$4" - - - - Show NTP operational summary - - if ps -C ntpd &>/dev/null; then ntpq -n -c sysinfo; ntpq -n -c kerninfo; else echo NTP daemon disabled; fi - - - - - - - diff --git a/op-mode-definitions/show-ntp.xml.in b/op-mode-definitions/show-ntp.xml.in new file mode 100644 index 000000000..b7f0acdf8 --- /dev/null +++ b/op-mode-definitions/show-ntp.xml.in @@ -0,0 +1,31 @@ + + + + + + + Show peer status of NTP daemon + + if ps -C ntpd &>/dev/null; then ntpq -n -c peers; else echo NTP daemon disabled; fi + + + + Show date and time of specified NTP server + + + + + /usr/sbin/ntpdate -q "$4" + + + + Show NTP operational summary + + if ps -C ntpd &>/dev/null; then ntpq -n -c sysinfo; ntpq -n -c kerninfo; else echo NTP daemon disabled; fi + + + + + + + diff --git a/op-mode-definitions/show-poweroff.xml b/op-mode-definitions/show-poweroff.xml deleted file mode 100644 index 1fd2afcc3..000000000 --- a/op-mode-definitions/show-poweroff.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - Show scheduled poweroff - - ${vyos_op_scripts_dir}/powerctrl.py --check - - - - diff --git a/op-mode-definitions/show-poweroff.xml.in b/op-mode-definitions/show-poweroff.xml.in new file mode 100644 index 000000000..1fd2afcc3 --- /dev/null +++ b/op-mode-definitions/show-poweroff.xml.in @@ -0,0 +1,13 @@ + + + + + + + Show scheduled poweroff + + ${vyos_op_scripts_dir}/powerctrl.py --check + + + + diff --git a/op-mode-definitions/show-protocols-bfd.xml b/op-mode-definitions/show-protocols-bfd.xml deleted file mode 100644 index 3d9b67c67..000000000 --- a/op-mode-definitions/show-protocols-bfd.xml +++ /dev/null @@ -1,55 +0,0 @@ - - - - - - - Show protocol specific information - - - - - - - Show all Bidirectional Forwarding Detection (BFD) peer status - - /usr/bin/vtysh -c "show bfd peers" - - - - Show Bidirectional Forwarding Detection (BFD) peer counters - - /usr/bin/vtysh -c "show bfd peers counters" - - - - - - Show Bidirectional Forwarding Detection (BFD) peer status - - - - - /usr/bin/vtysh -c "show bfd peers" | awk -v BFD_PEER=$5 'BEGIN { regex = sprintf("(peer %s.*)vrf", BFD_PEER) } { if (match($0, regex, bfd_peer_value)) peer=bfd_peer_value[1] } END { if (peer) system("/usr/bin/vtysh -c \"show bfd " peer "\"") }' - - - - Show Bidirectional Forwarding Detection (BFD) peer counters - - /usr/bin/vtysh -c "show bfd peers" | awk -v BFD_PEER=$5 'BEGIN { regex = sprintf("(peer %s.*)vrf", BFD_PEER) } { if (match($0, regex, bfd_peer_value)) peer=bfd_peer_value[1] } END { if (peer) system("/usr/bin/vtysh -c \"show bfd " peer " counters\"") }' - - - - - - Show Bidirectional Forwarding Detection (BFD) peers brief - - /usr/bin/vtysh -c "show bfd peers brief" - - - - - - - - diff --git a/op-mode-definitions/show-protocols-bfd.xml.in b/op-mode-definitions/show-protocols-bfd.xml.in new file mode 100644 index 000000000..3d9b67c67 --- /dev/null +++ b/op-mode-definitions/show-protocols-bfd.xml.in @@ -0,0 +1,55 @@ + + + + + + + Show protocol specific information + + + + + + + Show all Bidirectional Forwarding Detection (BFD) peer status + + /usr/bin/vtysh -c "show bfd peers" + + + + Show Bidirectional Forwarding Detection (BFD) peer counters + + /usr/bin/vtysh -c "show bfd peers counters" + + + + + + Show Bidirectional Forwarding Detection (BFD) peer status + + + + + /usr/bin/vtysh -c "show bfd peers" | awk -v BFD_PEER=$5 'BEGIN { regex = sprintf("(peer %s.*)vrf", BFD_PEER) } { if (match($0, regex, bfd_peer_value)) peer=bfd_peer_value[1] } END { if (peer) system("/usr/bin/vtysh -c \"show bfd " peer "\"") }' + + + + Show Bidirectional Forwarding Detection (BFD) peer counters + + /usr/bin/vtysh -c "show bfd peers" | awk -v BFD_PEER=$5 'BEGIN { regex = sprintf("(peer %s.*)vrf", BFD_PEER) } { if (match($0, regex, bfd_peer_value)) peer=bfd_peer_value[1] } END { if (peer) system("/usr/bin/vtysh -c \"show bfd " peer " counters\"") }' + + + + + + Show Bidirectional Forwarding Detection (BFD) peers brief + + /usr/bin/vtysh -c "show bfd peers brief" + + + + + + + + diff --git a/op-mode-definitions/show-protocols-static.xml b/op-mode-definitions/show-protocols-static.xml deleted file mode 100644 index aaf875072..000000000 --- a/op-mode-definitions/show-protocols-static.xml +++ /dev/null @@ -1,49 +0,0 @@ - - - - - - - Show Address Resolution Protocol (ARP) information - - /usr/sbin/arp -e -n - - - - Show Address Resolution Protocol (ARP) cache for specified interface - - - - - /usr/sbin/arp -e -n -i "$4" - - - - - - - - - - Show Address Resolution Protocol (ARP) information - - /usr/sbin/arp -e -n - - - - Show Address Resolution Protocol (ARP) cache for specified interface - - - - - /usr/sbin/arp -e -n -i "$6" - - - - - - - - - - diff --git a/op-mode-definitions/show-protocols-static.xml.in b/op-mode-definitions/show-protocols-static.xml.in new file mode 100644 index 000000000..aaf875072 --- /dev/null +++ b/op-mode-definitions/show-protocols-static.xml.in @@ -0,0 +1,49 @@ + + + + + + + Show Address Resolution Protocol (ARP) information + + /usr/sbin/arp -e -n + + + + Show Address Resolution Protocol (ARP) cache for specified interface + + + + + /usr/sbin/arp -e -n -i "$4" + + + + + + + + + + Show Address Resolution Protocol (ARP) information + + /usr/sbin/arp -e -n + + + + Show Address Resolution Protocol (ARP) cache for specified interface + + + + + /usr/sbin/arp -e -n -i "$6" + + + + + + + + + + diff --git a/op-mode-definitions/show-raid.xml b/op-mode-definitions/show-raid.xml deleted file mode 100644 index 8bf394552..000000000 --- a/op-mode-definitions/show-raid.xml +++ /dev/null @@ -1,16 +0,0 @@ - - - - - - - Show status of RAID set - - - - - ${vyos_op_scripts_dir}/show_raid.sh $3 - - - - diff --git a/op-mode-definitions/show-raid.xml.in b/op-mode-definitions/show-raid.xml.in new file mode 100644 index 000000000..8bf394552 --- /dev/null +++ b/op-mode-definitions/show-raid.xml.in @@ -0,0 +1,16 @@ + + + + + + + Show status of RAID set + + + + + ${vyos_op_scripts_dir}/show_raid.sh $3 + + + + diff --git a/op-mode-definitions/show-reboot.xml b/op-mode-definitions/show-reboot.xml deleted file mode 100644 index c85966bcb..000000000 --- a/op-mode-definitions/show-reboot.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - Show scheduled reboot - - ${vyos_op_scripts_dir}/powerctrl.py --check - - - - diff --git a/op-mode-definitions/show-reboot.xml.in b/op-mode-definitions/show-reboot.xml.in new file mode 100644 index 000000000..c85966bcb --- /dev/null +++ b/op-mode-definitions/show-reboot.xml.in @@ -0,0 +1,13 @@ + + + + + + + Show scheduled reboot + + ${vyos_op_scripts_dir}/powerctrl.py --check + + + + diff --git a/op-mode-definitions/show-route-map.xml b/op-mode-definitions/show-route-map.xml deleted file mode 100644 index 0e376757b..000000000 --- a/op-mode-definitions/show-route-map.xml +++ /dev/null @@ -1,22 +0,0 @@ - - - - - - - Show route-map information - - /usr/bin/vtysh -c "show route-map" - - - - Show specified route-map information - - policy route-map - - - /usr/bin/vtysh -c "show route-map $3" - - - - diff --git a/op-mode-definitions/show-route-map.xml.in b/op-mode-definitions/show-route-map.xml.in new file mode 100644 index 000000000..0e376757b --- /dev/null +++ b/op-mode-definitions/show-route-map.xml.in @@ -0,0 +1,22 @@ + + + + + + + Show route-map information + + /usr/bin/vtysh -c "show route-map" + + + + Show specified route-map information + + policy route-map + + + /usr/bin/vtysh -c "show route-map $3" + + + + diff --git a/op-mode-definitions/show-rpki.xml b/op-mode-definitions/show-rpki.xml deleted file mode 100644 index d68c3b862..000000000 --- a/op-mode-definitions/show-rpki.xml +++ /dev/null @@ -1,32 +0,0 @@ - - - - - - - Show RPKI information - - - - - Show RPKI cache connections - - /usr/bin/vtysh -c "show rpki cache-connection" - - - - Show RPKI cache servers information - - /usr/bin/vtysh -c "show rpki cache-server" - - - - Show RPKI-validated prefixes - - /usr/bin/vtysh -c "show rpki prefix-table" - - - - - - diff --git a/op-mode-definitions/show-rpki.xml.in b/op-mode-definitions/show-rpki.xml.in new file mode 100644 index 000000000..d68c3b862 --- /dev/null +++ b/op-mode-definitions/show-rpki.xml.in @@ -0,0 +1,32 @@ + + + + + + + Show RPKI information + + + + + Show RPKI cache connections + + /usr/bin/vtysh -c "show rpki cache-connection" + + + + Show RPKI cache servers information + + /usr/bin/vtysh -c "show rpki cache-server" + + + + Show RPKI-validated prefixes + + /usr/bin/vtysh -c "show rpki prefix-table" + + + + + + diff --git a/op-mode-definitions/show-system.xml b/op-mode-definitions/show-system.xml deleted file mode 100644 index 0623e3b62..000000000 --- a/op-mode-definitions/show-system.xml +++ /dev/null @@ -1,183 +0,0 @@ - - - - - - - Show system information - - - - - Show active network connections on the system - - netstat -an - - - - Show TCP connection information - - ss -t -r - - - - Show all TCP connections - - ss -t -a - - - - Show TCP connection without resolving names - - ss -t -n - - - - - - Show UDP socket information - - ss -u -a -r - - - - Show UDP socket information without resolving names - - ss -u -a -n - - - - - - - - Show CPU information - - ${vyos_op_scripts_dir}/show_cpu.py - - - - Checks overall system integrity - - sudo ${vyos_op_scripts_dir}/show_system_integrity.py - - - - Show messages in kernel ring buffer - - sudo dmesg - - - - Show user accounts - - - - - Show user account information - - ${vyos_libexec_dir}/vyos-sudo.py ${vyos_op_scripts_dir}/show_users.py - - - - Show information about all accounts - - ${vyos_libexec_dir}/vyos-sudo.py ${vyos_op_scripts_dir}/show_users.py all - - - - Show information about locked accounts - - ${vyos_libexec_dir}/vyos-sudo.py ${vyos_op_scripts_dir}/show_users.py locked - - - - Show information about non VyOS user accounts - - ${vyos_libexec_dir}/vyos-sudo.py ${vyos_op_scripts_dir}/show_users.py other - - - - Show information about VyOS user accounts - - ${vyos_libexec_dir}/vyos-sudo.py ${vyos_op_scripts_dir}/show_users.py vyos - - - - - - - - Show system memory usage - - ${vyos_op_scripts_dir}/show_ram.sh - - - - Show kernel cache information - - sudo slabtop -o - - - - Show detailed system memory usage - - cat /proc/meminfo - - - - Show memory usage of all routing protocols - - /usr/bin/vtysh -c "show memory" - - - - - - Show system processes - - ps ax - - - - Show extensive process info - - top -b -n1 - - - - Show summary of system processes - - uptime - - - - Show process tree - - ps -ejH - - - - - - Show Quagga routing daemons - - /usr/bin/vtysh -c "show daemons" - - - - Show filesystem usage - - df -h -x squashfs - - - - Show how long the system has been up - - uptime - - - - - - diff --git a/op-mode-definitions/show-system.xml.in b/op-mode-definitions/show-system.xml.in new file mode 100644 index 000000000..0623e3b62 --- /dev/null +++ b/op-mode-definitions/show-system.xml.in @@ -0,0 +1,183 @@ + + + + + + + Show system information + + + + + Show active network connections on the system + + netstat -an + + + + Show TCP connection information + + ss -t -r + + + + Show all TCP connections + + ss -t -a + + + + Show TCP connection without resolving names + + ss -t -n + + + + + + Show UDP socket information + + ss -u -a -r + + + + Show UDP socket information without resolving names + + ss -u -a -n + + + + + + + + Show CPU information + + ${vyos_op_scripts_dir}/show_cpu.py + + + + Checks overall system integrity + + sudo ${vyos_op_scripts_dir}/show_system_integrity.py + + + + Show messages in kernel ring buffer + + sudo dmesg + + + + Show user accounts + + + + + Show user account information + + ${vyos_libexec_dir}/vyos-sudo.py ${vyos_op_scripts_dir}/show_users.py + + + + Show information about all accounts + + ${vyos_libexec_dir}/vyos-sudo.py ${vyos_op_scripts_dir}/show_users.py all + + + + Show information about locked accounts + + ${vyos_libexec_dir}/vyos-sudo.py ${vyos_op_scripts_dir}/show_users.py locked + + + + Show information about non VyOS user accounts + + ${vyos_libexec_dir}/vyos-sudo.py ${vyos_op_scripts_dir}/show_users.py other + + + + Show information about VyOS user accounts + + ${vyos_libexec_dir}/vyos-sudo.py ${vyos_op_scripts_dir}/show_users.py vyos + + + + + + + + Show system memory usage + + ${vyos_op_scripts_dir}/show_ram.sh + + + + Show kernel cache information + + sudo slabtop -o + + + + Show detailed system memory usage + + cat /proc/meminfo + + + + Show memory usage of all routing protocols + + /usr/bin/vtysh -c "show memory" + + + + + + Show system processes + + ps ax + + + + Show extensive process info + + top -b -n1 + + + + Show summary of system processes + + uptime + + + + Show process tree + + ps -ejH + + + + + + Show Quagga routing daemons + + /usr/bin/vtysh -c "show daemons" + + + + Show filesystem usage + + df -h -x squashfs + + + + Show how long the system has been up + + uptime + + + + + + diff --git a/op-mode-definitions/show-table.xml b/op-mode-definitions/show-table.xml deleted file mode 100644 index b093a5de7..000000000 --- a/op-mode-definitions/show-table.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - - - - Show routing tables - - /usr/bin/vtysh -c "show zebra router table summary" - - - - diff --git a/op-mode-definitions/show-table.xml.in b/op-mode-definitions/show-table.xml.in new file mode 100644 index 000000000..b093a5de7 --- /dev/null +++ b/op-mode-definitions/show-table.xml.in @@ -0,0 +1,13 @@ + + + + + + + Show routing tables + + /usr/bin/vtysh -c "show zebra router table summary" + + + + diff --git a/op-mode-definitions/show-users.xml b/op-mode-definitions/show-users.xml deleted file mode 100644 index a026e47e7..000000000 --- a/op-mode-definitions/show-users.xml +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - Show user information - - who -H - - - - Show 10 recently logged in users - - last -aF -n 10 | sed -e 's/^wtmp begins/Displaying logins since/' - - - - Show specified number of recently logged in users - - NUMBER - - - last -aF -n $4 | sed -e 's/^wtmp begins/Displaying logins since/' - - - - - - diff --git a/op-mode-definitions/show-users.xml.in b/op-mode-definitions/show-users.xml.in new file mode 100644 index 000000000..a026e47e7 --- /dev/null +++ b/op-mode-definitions/show-users.xml.in @@ -0,0 +1,30 @@ + + + + + + + Show user information + + who -H + + + + Show 10 recently logged in users + + last -aF -n 10 | sed -e 's/^wtmp begins/Displaying logins since/' + + + + Show specified number of recently logged in users + + NUMBER + + + last -aF -n $4 | sed -e 's/^wtmp begins/Displaying logins since/' + + + + + + diff --git a/op-mode-definitions/show-version.xml b/op-mode-definitions/show-version.xml deleted file mode 100644 index 2202d27b3..000000000 --- a/op-mode-definitions/show-version.xml +++ /dev/null @@ -1,33 +0,0 @@ - - - - - - - Show system version information - - sudo ${vyos_op_scripts_dir}/show_version.py - - - - Show system version and some fun stuff - - sudo ${vyos_op_scripts_dir}/show_version.py --funny - - - - Show system version and versions of all packages - - echo "Package versions:"; dpkg -l | awk '$0~/>/{exit}1' - - - - Show Quagga version information - - /usr/bin/vtysh -c "show version" - - - - - - diff --git a/op-mode-definitions/show-version.xml.in b/op-mode-definitions/show-version.xml.in new file mode 100644 index 000000000..2202d27b3 --- /dev/null +++ b/op-mode-definitions/show-version.xml.in @@ -0,0 +1,33 @@ + + + + + + + Show system version information + + sudo ${vyos_op_scripts_dir}/show_version.py + + + + Show system version and some fun stuff + + sudo ${vyos_op_scripts_dir}/show_version.py --funny + + + + Show system version and versions of all packages + + echo "Package versions:"; dpkg -l | awk '$0~/>/{exit}1' + + + + Show Quagga version information + + /usr/bin/vtysh -c "show version" + + + + + + diff --git a/op-mode-definitions/show-vpn.xml b/op-mode-definitions/show-vpn.xml deleted file mode 100644 index 0e7fc38e9..000000000 --- a/op-mode-definitions/show-vpn.xml +++ /dev/null @@ -1,20 +0,0 @@ - - - - - - - Show active remote access Virtual Private Network (VPN) sessions - - - - - Show active VPN server sessions - - ${vyos_op_scripts_dir}/show_vpn_ra.py - - - - - - diff --git a/op-mode-definitions/show-vpn.xml.in b/op-mode-definitions/show-vpn.xml.in new file mode 100644 index 000000000..3fbc74ad1 --- /dev/null +++ b/op-mode-definitions/show-vpn.xml.in @@ -0,0 +1,20 @@ + + + + + + + Show active remote access Virtual Private Network (VPN) sessions + + + + + Show active VPN server sessions + + ${vyos_op_scripts_dir}/show_vpn_ra.py + + + + + + diff --git a/op-mode-definitions/show-vrf.xml b/op-mode-definitions/show-vrf.xml deleted file mode 100644 index 438e7c334..000000000 --- a/op-mode-definitions/show-vrf.xml +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - Show VRF information - - ${vyos_op_scripts_dir}/show_vrf.py -e - - - - Show information on specific VRF instance - - vrf name - - - ${vyos_op_scripts_dir}/show_vrf.py -e "$3" - - - - Shows all process ids associated with VRF - - /usr/sbin/ip vrf pids "$3" - - - - - - diff --git a/op-mode-definitions/show-vrf.xml.in b/op-mode-definitions/show-vrf.xml.in new file mode 100644 index 000000000..438e7c334 --- /dev/null +++ b/op-mode-definitions/show-vrf.xml.in @@ -0,0 +1,30 @@ + + + + + + + Show VRF information + + ${vyos_op_scripts_dir}/show_vrf.py -e + + + + Show information on specific VRF instance + + vrf name + + + ${vyos_op_scripts_dir}/show_vrf.py -e "$3" + + + + Shows all process ids associated with VRF + + /usr/sbin/ip vrf pids "$3" + + + + + + diff --git a/op-mode-definitions/snmp.xml b/op-mode-definitions/snmp.xml deleted file mode 100644 index a0a47da40..000000000 --- a/op-mode-definitions/snmp.xml +++ /dev/null @@ -1,111 +0,0 @@ - - - - - - - Show status of SNMP on localhost - - - - - Show status of SNMP community - - - - - ${vyos_op_scripts_dir}/snmp.py --community="$4" - - - - Show status of SNMP on remote host - - ${vyos_op_scripts_dir}/snmp.py --community="$4" --host "$6" - - - - - - Show SNMP MIB information - - - - - Show all SNMP interfaces MIB information - - ${vyos_op_scripts_dir}/snmp_ifmib.py - - - - Show SNMP ifAlias for specified interface - - - - - ${vyos_op_scripts_dir}/snmp_ifmib.py --ifalias="$6" - - - - Show SNMP ifDescr for specified interface - - - - - ${vyos_op_scripts_dir}/snmp_ifmib.py --ifdescr="$6" - - - - Show SNMP ifDescr for specified interface - - - - - ${vyos_op_scripts_dir}/snmp_ifmib.py --ifindex="$6" - - - - - - - - Show SNMP v3 status on localhost - - ${vyos_op_scripts_dir}/snmp_v3.py --all - - - - Show TSM certificates - - ${vyos_op_scripts_dir}/snmp_v3_showcerts.sh - - - - Show the list of configured groups - - ${vyos_op_scripts_dir}/snmp_v3.py --group - - - - Show the list of configured targets - - ${vyos_op_scripts_dir}/snmp_v3.py --trap - - - - Show the list of configured users - - ${vyos_op_scripts_dir}/snmp_v3.py --user - - - - Show the list of configured views - - ${vyos_op_scripts_dir}/snmp_v3.py --view - - - - - - - - diff --git a/op-mode-definitions/snmp.xml.in b/op-mode-definitions/snmp.xml.in new file mode 100644 index 000000000..a0a47da40 --- /dev/null +++ b/op-mode-definitions/snmp.xml.in @@ -0,0 +1,111 @@ + + + + + + + Show status of SNMP on localhost + + + + + Show status of SNMP community + + + + + ${vyos_op_scripts_dir}/snmp.py --community="$4" + + + + Show status of SNMP on remote host + + ${vyos_op_scripts_dir}/snmp.py --community="$4" --host "$6" + + + + + + Show SNMP MIB information + + + + + Show all SNMP interfaces MIB information + + ${vyos_op_scripts_dir}/snmp_ifmib.py + + + + Show SNMP ifAlias for specified interface + + + + + ${vyos_op_scripts_dir}/snmp_ifmib.py --ifalias="$6" + + + + Show SNMP ifDescr for specified interface + + + + + ${vyos_op_scripts_dir}/snmp_ifmib.py --ifdescr="$6" + + + + Show SNMP ifDescr for specified interface + + + + + ${vyos_op_scripts_dir}/snmp_ifmib.py --ifindex="$6" + + + + + + + + Show SNMP v3 status on localhost + + ${vyos_op_scripts_dir}/snmp_v3.py --all + + + + Show TSM certificates + + ${vyos_op_scripts_dir}/snmp_v3_showcerts.sh + + + + Show the list of configured groups + + ${vyos_op_scripts_dir}/snmp_v3.py --group + + + + Show the list of configured targets + + ${vyos_op_scripts_dir}/snmp_v3.py --trap + + + + Show the list of configured users + + ${vyos_op_scripts_dir}/snmp_v3.py --user + + + + Show the list of configured views + + ${vyos_op_scripts_dir}/snmp_v3.py --view + + + + + + + + diff --git a/op-mode-definitions/sstp-server.xml b/op-mode-definitions/sstp-server.xml deleted file mode 100644 index 03dfc4262..000000000 --- a/op-mode-definitions/sstp-server.xml +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - Show SSTP server information - - - - - Show active SSTP server sessions - - ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="sstp" --action="show sessions" - - - - Show SSTP server statistics - - ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="sstp" --action="show stat" - - - - - - diff --git a/op-mode-definitions/sstp-server.xml.in b/op-mode-definitions/sstp-server.xml.in new file mode 100644 index 000000000..03dfc4262 --- /dev/null +++ b/op-mode-definitions/sstp-server.xml.in @@ -0,0 +1,26 @@ + + + + + + + Show SSTP server information + + + + + Show active SSTP server sessions + + ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="sstp" --action="show sessions" + + + + Show SSTP server statistics + + ${vyos_op_scripts_dir}/ppp-server-ctrl.py --proto="sstp" --action="show stat" + + + + + + diff --git a/op-mode-definitions/telnet.xml b/op-mode-definitions/telnet.xml deleted file mode 100644 index c5bb6d283..000000000 --- a/op-mode-definitions/telnet.xml +++ /dev/null @@ -1,30 +0,0 @@ - - - - - Telnet to a node - - - - - Telnet to a host - - <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> - - - /usr/bin/telnet $3 - - - - Telnet to a host:port - - <0-65535> - - - /usr/bin/telnet $3 $5 - - - - - - diff --git a/op-mode-definitions/telnet.xml.in b/op-mode-definitions/telnet.xml.in new file mode 100644 index 000000000..c5bb6d283 --- /dev/null +++ b/op-mode-definitions/telnet.xml.in @@ -0,0 +1,30 @@ + + + + + Telnet to a node + + + + + Telnet to a host + + <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> + + + /usr/bin/telnet $3 + + + + Telnet to a host:port + + <0-65535> + + + /usr/bin/telnet $3 $5 + + + + + + diff --git a/op-mode-definitions/terminal.xml b/op-mode-definitions/terminal.xml deleted file mode 100644 index 9c4e629cb..000000000 --- a/op-mode-definitions/terminal.xml +++ /dev/null @@ -1,122 +0,0 @@ - - - - - Clear system information - - - - - Clear screen - - /usr/bin/clear - - - - - - Reset a service - - - - - Reset terminal - - /usr/bin/reset - - - - - - Set operational options - - - - - Bash builtin set command - - <OPTION> - - - builtin $3 - - - - - Control console behaviors - - - - - Reconfigure console keyboard layout - - sudo dpkg-reconfigure -f dialog keyboard-configuration && sudo systemctl restart keyboard-setup - - - - - - - Control terminal behaviors - - - - - - Set key behaviors - - - - - Enable/disable getting help using question mark (default enabled) - - enable disable - - - ${vyos_op_scripts_dir}/toggle_help_binding.sh $5 - - - - - - - Set terminal pager to default (less) - - VYATTA_PAGER=${_vyatta_default_pager} - - - - Set terminal pager - - <PROGRAM> - - - VYATTA_PAGER=$4 - - - - - Set terminal to given number of rows (0 disables paging) - - <NUMBER> - - - if [ "$4" -eq 0 ]; then VYATTA_PAGER=cat; else VYATTA_PAGER=${_vyatta_default_pager}; stty rows $4; fi - - - - - Set terminal to given number of columns - - <NUMBER> - - - stty columns $4 - - - - - - - - diff --git a/op-mode-definitions/terminal.xml.in b/op-mode-definitions/terminal.xml.in new file mode 100644 index 000000000..9c4e629cb --- /dev/null +++ b/op-mode-definitions/terminal.xml.in @@ -0,0 +1,122 @@ + + + + + Clear system information + + + + + Clear screen + + /usr/bin/clear + + + + + + Reset a service + + + + + Reset terminal + + /usr/bin/reset + + + + + + Set operational options + + + + + Bash builtin set command + + <OPTION> + + + builtin $3 + + + + + Control console behaviors + + + + + Reconfigure console keyboard layout + + sudo dpkg-reconfigure -f dialog keyboard-configuration && sudo systemctl restart keyboard-setup + + + + + + + Control terminal behaviors + + + + + + Set key behaviors + + + + + Enable/disable getting help using question mark (default enabled) + + enable disable + + + ${vyos_op_scripts_dir}/toggle_help_binding.sh $5 + + + + + + + Set terminal pager to default (less) + + VYATTA_PAGER=${_vyatta_default_pager} + + + + Set terminal pager + + <PROGRAM> + + + VYATTA_PAGER=$4 + + + + + Set terminal to given number of rows (0 disables paging) + + <NUMBER> + + + if [ "$4" -eq 0 ]; then VYATTA_PAGER=cat; else VYATTA_PAGER=${_vyatta_default_pager}; stty rows $4; fi + + + + + Set terminal to given number of columns + + <NUMBER> + + + stty columns $4 + + + + + + + + diff --git a/op-mode-definitions/traceroute.xml b/op-mode-definitions/traceroute.xml deleted file mode 100644 index 1b619ed43..000000000 --- a/op-mode-definitions/traceroute.xml +++ /dev/null @@ -1,227 +0,0 @@ - - - - - Track network path to node - - <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> - - - /usr/bin/traceroute "$2" - - - - Track network path to node - - <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> - - - - - - Explicitly use IPv4 when tracing the path - - <hostname> <x.x.x.x> - - - /usr/bin/traceroute -4 "$3" - - - - Route tracing and port detection using TCP - - sudo /usr/bin/tcptraceroute "$3" - - - - TCP port to connect to for path tracing - - 0-65535 - - - sudo /usr/bin/tcptraceroute "$3" $6 - - - - - - - - Explicitly use IPv6 when tracing the path - - <hostname> <h:h:h:h:h:h:h:h> - - - /usr/bin/traceroute -6 "$3" - - - - Use TCP/IPv6 packets to perform a traceroute - - sudo /usr/bin/tcptraceroute6 "$3" - - - - TCP port to connect to for path tracing - - 0-65535 - - - sudo /usr/bin/tcptraceroute6 "$3" $6 - - - - - - - - Track network path to specified node via given VRF - - vrf name - - - - - - - Track network path to specified node via given VRF - - <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> - - - sudo /usr/sbin/ip vrf exec "$3" /usr/bin/traceroute "$4" - - - - Explicitly use IPv4 when tracing the path via given VRF - - <hostname> <x.x.x.x> - - - sudo /usr/sbin/ip vrf exec "$3" /usr/bin/traceroute -4 "$5" - - - - Route tracing and port detection using TCP - - sudo /usr/sbin/ip vrf exec "$3" /usr/bin/tcptraceroute "$5" - - - - TCP port to connect to for path tracing - - 0-65535 - - - sudo /usr/sbin/ip vrf exec "$3" /usr/bin/tcptraceroute "$5" $8 - - - - - - - - Explicitly use IPv6 when tracing the path via given VRF - - <hostname> <h:h:h:h:h:h:h:h> - - - sudo /usr/sbin/ip vrf exec "$3" /usr/bin/traceroute -6 "$5" - - - - Use TCP/IPv6 packets to perform a traceroute - - sudo /usr/sbin/ip vrf exec "$3" /usr/bin/tcptraceroute6 "$5" - - - - TCP port to connect to for path tracing - - 0-65535 - - - sudo /usr/sbin/ip vrf exec "$3" /usr/bin/tcptraceroute6 "$5" $8 - - - - - - - - - - - - - - Monitor path to destination in realtime - - <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> - - - /usr/bin/mtr "$3" - - - - - - IPv4 fully qualified domain name (FQDN) - - <fqdn> - - - /usr/bin/mtr -4 "$4" - - - - IPv6 fully qualified domain name (FQDN) - - <fqdn> - - - /usr/bin/mtr -6 "$4" - - - - Monitor path to destination in realtime via given VRF - - vrf name - - - - - - IPv4 fully qualified domain name (FQDN) - - <fqdn> - - - sudo /usr/sbin/ip vrf exec "$4" /usr/bin/mtr -4 "$6" - - - - IPv6 fully qualified domain name (FQDN) - - <fqdn> - - - sudo /usr/sbin/ip vrf exec "$4" /usr/bin/mtr -6 "$6" - - - - Track network path to specified node via given VRF - - <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> - - - sudo /usr/sbin/ip vrf exec "$4" /usr/bin/mtr "$5" - - - - - - - - diff --git a/op-mode-definitions/traceroute.xml.in b/op-mode-definitions/traceroute.xml.in new file mode 100644 index 000000000..1b619ed43 --- /dev/null +++ b/op-mode-definitions/traceroute.xml.in @@ -0,0 +1,227 @@ + + + + + Track network path to node + + <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> + + + /usr/bin/traceroute "$2" + + + + Track network path to node + + <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> + + + + + + Explicitly use IPv4 when tracing the path + + <hostname> <x.x.x.x> + + + /usr/bin/traceroute -4 "$3" + + + + Route tracing and port detection using TCP + + sudo /usr/bin/tcptraceroute "$3" + + + + TCP port to connect to for path tracing + + 0-65535 + + + sudo /usr/bin/tcptraceroute "$3" $6 + + + + + + + + Explicitly use IPv6 when tracing the path + + <hostname> <h:h:h:h:h:h:h:h> + + + /usr/bin/traceroute -6 "$3" + + + + Use TCP/IPv6 packets to perform a traceroute + + sudo /usr/bin/tcptraceroute6 "$3" + + + + TCP port to connect to for path tracing + + 0-65535 + + + sudo /usr/bin/tcptraceroute6 "$3" $6 + + + + + + + + Track network path to specified node via given VRF + + vrf name + + + + + + + Track network path to specified node via given VRF + + <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> + + + sudo /usr/sbin/ip vrf exec "$3" /usr/bin/traceroute "$4" + + + + Explicitly use IPv4 when tracing the path via given VRF + + <hostname> <x.x.x.x> + + + sudo /usr/sbin/ip vrf exec "$3" /usr/bin/traceroute -4 "$5" + + + + Route tracing and port detection using TCP + + sudo /usr/sbin/ip vrf exec "$3" /usr/bin/tcptraceroute "$5" + + + + TCP port to connect to for path tracing + + 0-65535 + + + sudo /usr/sbin/ip vrf exec "$3" /usr/bin/tcptraceroute "$5" $8 + + + + + + + + Explicitly use IPv6 when tracing the path via given VRF + + <hostname> <h:h:h:h:h:h:h:h> + + + sudo /usr/sbin/ip vrf exec "$3" /usr/bin/traceroute -6 "$5" + + + + Use TCP/IPv6 packets to perform a traceroute + + sudo /usr/sbin/ip vrf exec "$3" /usr/bin/tcptraceroute6 "$5" + + + + TCP port to connect to for path tracing + + 0-65535 + + + sudo /usr/sbin/ip vrf exec "$3" /usr/bin/tcptraceroute6 "$5" $8 + + + + + + + + + + + + + + Monitor path to destination in realtime + + <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> + + + /usr/bin/mtr "$3" + + + + + + IPv4 fully qualified domain name (FQDN) + + <fqdn> + + + /usr/bin/mtr -4 "$4" + + + + IPv6 fully qualified domain name (FQDN) + + <fqdn> + + + /usr/bin/mtr -6 "$4" + + + + Monitor path to destination in realtime via given VRF + + vrf name + + + + + + IPv4 fully qualified domain name (FQDN) + + <fqdn> + + + sudo /usr/sbin/ip vrf exec "$4" /usr/bin/mtr -4 "$6" + + + + IPv6 fully qualified domain name (FQDN) + + <fqdn> + + + sudo /usr/sbin/ip vrf exec "$4" /usr/bin/mtr -6 "$6" + + + + Track network path to specified node via given VRF + + <hostname> <x.x.x.x> <h:h:h:h:h:h:h:h> + + + sudo /usr/sbin/ip vrf exec "$4" /usr/bin/mtr "$5" + + + + + + + + diff --git a/op-mode-definitions/traffic-dump.xml b/op-mode-definitions/traffic-dump.xml deleted file mode 100644 index 6d86f7423..000000000 --- a/op-mode-definitions/traffic-dump.xml +++ /dev/null @@ -1,45 +0,0 @@ - - - - - - - Monitor traffic dumps - - - - sudo tcpdump -i $4 - - Monitor traffic dump from an interface - - - - - - - sudo tcpdump -n -i $4 "${@:6}" - - Monitor traffic matching filter conditions - - - - sudo tcpdump -n -i $4 -w $6 - - Save traffic dump from an interface to a file - - - - sudo tcpdump -n -i $4 -w $6 "${@:8}" - - Save a dump of traffic matching filter conditions to a file - - - - - - - - - - - diff --git a/op-mode-definitions/traffic-dump.xml.in b/op-mode-definitions/traffic-dump.xml.in new file mode 100644 index 000000000..6d86f7423 --- /dev/null +++ b/op-mode-definitions/traffic-dump.xml.in @@ -0,0 +1,45 @@ + + + + + + + Monitor traffic dumps + + + + sudo tcpdump -i $4 + + Monitor traffic dump from an interface + + + + + + + sudo tcpdump -n -i $4 "${@:6}" + + Monitor traffic matching filter conditions + + + + sudo tcpdump -n -i $4 -w $6 + + Save traffic dump from an interface to a file + + + + sudo tcpdump -n -i $4 -w $6 "${@:8}" + + Save a dump of traffic matching filter conditions to a file + + + + + + + + + + + diff --git a/op-mode-definitions/vrrp.xml b/op-mode-definitions/vrrp.xml deleted file mode 100644 index 856fb440d..000000000 --- a/op-mode-definitions/vrrp.xml +++ /dev/null @@ -1,37 +0,0 @@ - - - - - - - Show VRRP (Virtual Router Redundancy Protocol) information - - sudo ${vyos_op_scripts_dir}/vrrp.py --summary - - - - Show VRRP statistics - - sudo ${vyos_op_scripts_dir}/vrrp.py --statistics - - - - Show detailed VRRP state information - - sudo ${vyos_op_scripts_dir}/vrrp.py --data - - - - - - - - - - Restart the VRRP (Virtual Router Redundancy Protocol) process - - sudo systemctl restart keepalived.service - - - - diff --git a/op-mode-definitions/vrrp.xml.in b/op-mode-definitions/vrrp.xml.in new file mode 100644 index 000000000..856fb440d --- /dev/null +++ b/op-mode-definitions/vrrp.xml.in @@ -0,0 +1,37 @@ + + + + + + + Show VRRP (Virtual Router Redundancy Protocol) information + + sudo ${vyos_op_scripts_dir}/vrrp.py --summary + + + + Show VRRP statistics + + sudo ${vyos_op_scripts_dir}/vrrp.py --statistics + + + + Show detailed VRRP state information + + sudo ${vyos_op_scripts_dir}/vrrp.py --data + + + + + + + + + + Restart the VRRP (Virtual Router Redundancy Protocol) process + + sudo systemctl restart keepalived.service + + + + diff --git a/op-mode-definitions/wake-on-lan.xml b/op-mode-definitions/wake-on-lan.xml deleted file mode 100644 index 1a9b88596..000000000 --- a/op-mode-definitions/wake-on-lan.xml +++ /dev/null @@ -1,26 +0,0 @@ - - - - - Send Wake-On-LAN (WOL) Magic Packet - - - - - Interface where the station is connected - - - - - - - - Station (MAC) address to wake up - - sudo /usr/sbin/etherwake -i "$3" "$5" - - - - - - diff --git a/op-mode-definitions/wake-on-lan.xml.in b/op-mode-definitions/wake-on-lan.xml.in new file mode 100644 index 000000000..1a9b88596 --- /dev/null +++ b/op-mode-definitions/wake-on-lan.xml.in @@ -0,0 +1,26 @@ + + + + + Send Wake-On-LAN (WOL) Magic Packet + + + + + Interface where the station is connected + + + + + + + + Station (MAC) address to wake up + + sudo /usr/sbin/etherwake -i "$3" "$5" + + + + + + diff --git a/op-mode-definitions/webproxy.xml b/op-mode-definitions/webproxy.xml deleted file mode 100644 index f8ec8fb0a..000000000 --- a/op-mode-definitions/webproxy.xml +++ /dev/null @@ -1,110 +0,0 @@ - - - - - - - Monitor WebProxy service - - ${vyatta_bindir}/vyatta-monitor Webproxy squid - - - - Monitor the last lines of the squid access log - - if [ -f /var/log/squid3/access.log ]; then sudo tail --follow=name /var/log/squid3/access.log; else echo "WebProxy cache-log does not exist"; fi - - - - Monitor Webproxy in the background - - - - - Start background monitoring of Webproxy - - ${vyatta_bindir}/vyatta-monitor-background Webproxy squid - - - - Stop background monitoring of Webproxy - - ${vyatta_bindir}/vyatta-monitor-background-stop Webproxy - - - - - - Monitor the last lines of the squid cache log - - if [ -f /var/log/squid3/cache.log ]; then sudo tail --follow=name /var/log/squid3/cache.log; else echo "WebProxy cache-log does not exist"; fi - - - - - - - - - - Restart WebProxy service - - if cli-shell-api existsActive service webproxy; then sudo systemctl restart squid.service; else echo "Service WebProxy not configured"; fi - - - - - - - - Show WebProxy information - - - - - - Show webproxy blacklist information - - - - - Show webproxy blacklist categories - - ${vyos_completion_dir}/list_webproxy_category.sh - - - - - - Show contents of WebProxy access log - - if [ -e /var/log/squid/access.log ]; then sudo less $_vyatta_less_options --prompt="file %i of %m, page %dt of %D" -- `printf "%s\n" /var/log/squid/access.log* | sort -nr`; else echo "No WebProxy log"; fi - - - - Show update log for url-filter database - - if [ -e /opt/vyatta/etc/config/url-filtering/squidguard/updatestatus ]; then cat /opt/vyatta/etc/config/url-filtering/squidguard/updatestatus; else echo "Update log not found"; fi - - - - - - - - - - Update WebProxy - - - - - Update the webproxy blacklist database - - sudo ${vyos_op_scripts_dir}/webproxy_update_blacklist.sh --update-blacklist - - - - - - diff --git a/op-mode-definitions/webproxy.xml.in b/op-mode-definitions/webproxy.xml.in new file mode 100644 index 000000000..f8ec8fb0a --- /dev/null +++ b/op-mode-definitions/webproxy.xml.in @@ -0,0 +1,110 @@ + + + + + + + Monitor WebProxy service + + ${vyatta_bindir}/vyatta-monitor Webproxy squid + + + + Monitor the last lines of the squid access log + + if [ -f /var/log/squid3/access.log ]; then sudo tail --follow=name /var/log/squid3/access.log; else echo "WebProxy cache-log does not exist"; fi + + + + Monitor Webproxy in the background + + + + + Start background monitoring of Webproxy + + ${vyatta_bindir}/vyatta-monitor-background Webproxy squid + + + + Stop background monitoring of Webproxy + + ${vyatta_bindir}/vyatta-monitor-background-stop Webproxy + + + + + + Monitor the last lines of the squid cache log + + if [ -f /var/log/squid3/cache.log ]; then sudo tail --follow=name /var/log/squid3/cache.log; else echo "WebProxy cache-log does not exist"; fi + + + + + + + + + + Restart WebProxy service + + if cli-shell-api existsActive service webproxy; then sudo systemctl restart squid.service; else echo "Service WebProxy not configured"; fi + + + + + + + + Show WebProxy information + + + + + + Show webproxy blacklist information + + + + + Show webproxy blacklist categories + + ${vyos_completion_dir}/list_webproxy_category.sh + + + + + + Show contents of WebProxy access log + + if [ -e /var/log/squid/access.log ]; then sudo less $_vyatta_less_options --prompt="file %i of %m, page %dt of %D" -- `printf "%s\n" /var/log/squid/access.log* | sort -nr`; else echo "No WebProxy log"; fi + + + + Show update log for url-filter database + + if [ -e /opt/vyatta/etc/config/url-filtering/squidguard/updatestatus ]; then cat /opt/vyatta/etc/config/url-filtering/squidguard/updatestatus; else echo "Update log not found"; fi + + + + + + + + + + Update WebProxy + + + + + Update the webproxy blacklist database + + sudo ${vyos_op_scripts_dir}/webproxy_update_blacklist.sh --update-blacklist + + + + + + diff --git a/op-mode-definitions/wireguard.xml b/op-mode-definitions/wireguard.xml deleted file mode 100644 index a7bfa36a3..000000000 --- a/op-mode-definitions/wireguard.xml +++ /dev/null @@ -1,138 +0,0 @@ - - - - - - - - wireguard key generation utility - - - - - generates the wireguard default-keypair - - sudo ${vyos_op_scripts_dir}/wireguard.py --genkey - - - - generate a wireguard preshared key - - ${vyos_op_scripts_dir}/wireguard.py --genpsk - - - - Generates named wireguard keypairs - - sudo ${vyos_op_scripts_dir}/wireguard.py --genkey --location "$4" - - - - - - - - - - Show wireguard properties - - - - - Shows named wireguard keys - - - - - Show wireguard private named key - - - - - ${vyos_op_scripts_dir}/wireguard.py --showpub --location "$5" - - - - Show wireguard public named key - - - - - ${vyos_op_scripts_dir}/wireguard.py --showpriv --location "$5" - - - - - - - - - - show wireguard interface information - - - - - sudo ${vyos_op_scripts_dir}/wireguard.py --showinterface "$4" - - - - show all allowed-ips for the specified interface - - sudo wg show "$4" allowed-ips - - - - show all endpoints for the specified interface - - sudo wg show "$4" endpoints - - - - show all peer IDs for the specified interface - - sudo wg show "$4" peers - - - - - - - Show wireguard interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=wireguard --action=show-brief - - - - Show detailed wireguard interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=wireguard --action=show - - - - - - - - - - - - Delete wireguard properties - - - - - Delete a wireguard keypair - - - - - sudo ${vyos_op_scripts_dir}/wireguard.py --delkdir --location "$4" - - - - - - - diff --git a/op-mode-definitions/wireguard.xml.in b/op-mode-definitions/wireguard.xml.in new file mode 100644 index 000000000..69ba8043d --- /dev/null +++ b/op-mode-definitions/wireguard.xml.in @@ -0,0 +1,137 @@ + + + + + + + + wireguard key generation utility + + + + + generates the wireguard default-keypair + + sudo ${vyos_op_scripts_dir}/wireguard.py --genkey + + + + generate a wireguard preshared key + + ${vyos_op_scripts_dir}/wireguard.py --genpsk + + + + Generates named wireguard keypairs + + sudo ${vyos_op_scripts_dir}/wireguard.py --genkey --location "$4" + + + + + + + + + + Show wireguard properties + + + + + Shows named wireguard keys + + + + + Show wireguard private named key + + + + + ${vyos_op_scripts_dir}/wireguard.py --showpub --location "$5" + + + + Show wireguard public named key + + + + + ${vyos_op_scripts_dir}/wireguard.py --showpriv --location "$5" + + + + + + + + + + show wireguard interface information + + + + + sudo ${vyos_op_scripts_dir}/wireguard.py --showinterface "$4" + + + + show all allowed-ips for the specified interface + + sudo wg show "$4" allowed-ips + + + + show all endpoints for the specified interface + + sudo wg show "$4" endpoints + + + + show all peer IDs for the specified interface + + sudo wg show "$4" peers + + + + + + + Show wireguard interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=wireguard --action=show-brief + + + + Show detailed wireguard interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=wireguard --action=show + + + + + + + + + + + + Delete wireguard properties + + + + + Delete a wireguard keypair + + + + + sudo ${vyos_op_scripts_dir}/wireguard.py --delkdir --location "$4" + + + + + + diff --git a/op-mode-definitions/wireless.xml b/op-mode-definitions/wireless.xml deleted file mode 100644 index a3a9d1f55..000000000 --- a/op-mode-definitions/wireless.xml +++ /dev/null @@ -1,119 +0,0 @@ - - - - - - - - - Clear wireless interface information - - - - - Clear all wireless interface counters - - sudo ${vyos_op_scripts_dir}/show_interfaces.py --action=clear --intf-type="$3" - - - - - - Clear interface information for a given wireless interface - - - - - - - - Clear all wireless interface counters - - sudo ${vyos_op_scripts_dir}/show_interfaces.py --action=clear --intf="$4" - - - - - - - - - - - - - - Show wireless interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=wireless --action=show-brief - - - - Show detailed wireless interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=wireless --action=show - - - - Show wireless interface configuration - - ${vyos_op_scripts_dir}/show_wireless.py --brief - - - - - - Show specified wireless interface information - - - - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" - - - - Show summary of the specified wireless interface information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief - - - - Show summary of the specified wireless interface information - - sudo ${vyos_op_scripts_dir}/show_wireless.py --scan "$4" - - - - Show detailed scan results - - sudo /sbin/iw dev "$4" scan ap-force - - - - - - Show specified wireless interface information - - ${vyos_op_scripts_dir}/show_wireless.py --stations "$4" - - - - Show specified virtual network interface (vif) information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4.$6" - - - - Show summary of specified virtual network interface (vif) information - - ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4.$6" --action=show-brief - - - - - - - - - - diff --git a/op-mode-definitions/wireless.xml.in b/op-mode-definitions/wireless.xml.in new file mode 100644 index 000000000..a3a9d1f55 --- /dev/null +++ b/op-mode-definitions/wireless.xml.in @@ -0,0 +1,119 @@ + + + + + + + + + Clear wireless interface information + + + + + Clear all wireless interface counters + + sudo ${vyos_op_scripts_dir}/show_interfaces.py --action=clear --intf-type="$3" + + + + + + Clear interface information for a given wireless interface + + + + + + + + Clear all wireless interface counters + + sudo ${vyos_op_scripts_dir}/show_interfaces.py --action=clear --intf="$4" + + + + + + + + + + + + + + Show wireless interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=wireless --action=show-brief + + + + Show detailed wireless interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf-type=wireless --action=show + + + + Show wireless interface configuration + + ${vyos_op_scripts_dir}/show_wireless.py --brief + + + + + + Show specified wireless interface information + + + + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" + + + + Show summary of the specified wireless interface information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4" --action=show-brief + + + + Show summary of the specified wireless interface information + + sudo ${vyos_op_scripts_dir}/show_wireless.py --scan "$4" + + + + Show detailed scan results + + sudo /sbin/iw dev "$4" scan ap-force + + + + + + Show specified wireless interface information + + ${vyos_op_scripts_dir}/show_wireless.py --stations "$4" + + + + Show specified virtual network interface (vif) information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4.$6" + + + + Show summary of specified virtual network interface (vif) information + + ${vyos_op_scripts_dir}/show_interfaces.py --intf="$4.$6" --action=show-brief + + + + + + + + + + -- cgit v1.2.3 From 1e3de0926517fe7b7b1bd14aa1bd9d74fc021505 Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Sun, 10 Jan 2021 10:25:41 +0100 Subject: op-mode: T3178: migrate most of the OSPFv3 parts to re-includable snippets This eases CLI maintenance and also migration from legacy code. --- .../include/ospfv3-adv-router-id-node-tag.xml.i | 16 + .../include/ospfv3-adv-router.xml.i | 13 + op-mode-definitions/include/ospfv3-detail.xml.i | 9 + op-mode-definitions/include/ospfv3-dump.xml.i | 9 + op-mode-definitions/include/ospfv3-internal.xml.i | 9 + .../include/ospfv3-linkstate-id.xml.i | 15 + .../include/ospfv3-self-originated.xml.i | 13 + op-mode-definitions/show-ipv6-ospfv3.xml.in | 507 ++------------------- 8 files changed, 123 insertions(+), 468 deletions(-) create mode 100644 op-mode-definitions/include/ospfv3-adv-router-id-node-tag.xml.i create mode 100644 op-mode-definitions/include/ospfv3-adv-router.xml.i create mode 100644 op-mode-definitions/include/ospfv3-detail.xml.i create mode 100644 op-mode-definitions/include/ospfv3-dump.xml.i create mode 100644 op-mode-definitions/include/ospfv3-internal.xml.i create mode 100644 op-mode-definitions/include/ospfv3-linkstate-id.xml.i create mode 100644 op-mode-definitions/include/ospfv3-self-originated.xml.i diff --git a/op-mode-definitions/include/ospfv3-adv-router-id-node-tag.xml.i b/op-mode-definitions/include/ospfv3-adv-router-id-node-tag.xml.i new file mode 100644 index 000000000..b6a64c52a --- /dev/null +++ b/op-mode-definitions/include/ospfv3-adv-router-id-node-tag.xml.i @@ -0,0 +1,16 @@ + + + + Search by Advertising Router ID + + <x.x.x.x> + + + vtysh -c "show ipv6 ospf6 database * $6 $7" + + #include + #include + #include + + + diff --git a/op-mode-definitions/include/ospfv3-adv-router.xml.i b/op-mode-definitions/include/ospfv3-adv-router.xml.i new file mode 100644 index 000000000..6330c0a72 --- /dev/null +++ b/op-mode-definitions/include/ospfv3-adv-router.xml.i @@ -0,0 +1,13 @@ + + + + Search by Advertising Router ID + + <x.x.x.x> + + + + #include + + + diff --git a/op-mode-definitions/include/ospfv3-detail.xml.i b/op-mode-definitions/include/ospfv3-detail.xml.i new file mode 100644 index 000000000..76096fbc8 --- /dev/null +++ b/op-mode-definitions/include/ospfv3-detail.xml.i @@ -0,0 +1,9 @@ + + + + Show detailed information + + + vtysh -c "show ipv6 ospf6 ${@:4}" + + diff --git a/op-mode-definitions/include/ospfv3-dump.xml.i b/op-mode-definitions/include/ospfv3-dump.xml.i new file mode 100644 index 000000000..4271aec53 --- /dev/null +++ b/op-mode-definitions/include/ospfv3-dump.xml.i @@ -0,0 +1,9 @@ + + + + Show dump of LSAs + + + vtysh -c "show ipv6 ospf6 ${@:4}" + + diff --git a/op-mode-definitions/include/ospfv3-internal.xml.i b/op-mode-definitions/include/ospfv3-internal.xml.i new file mode 100644 index 000000000..8b45e86c1 --- /dev/null +++ b/op-mode-definitions/include/ospfv3-internal.xml.i @@ -0,0 +1,9 @@ + + + + Show internal LSA information + + + vtysh -c "show ipv6 ospf6 ${@:4}" + + diff --git a/op-mode-definitions/include/ospfv3-linkstate-id.xml.i b/op-mode-definitions/include/ospfv3-linkstate-id.xml.i new file mode 100644 index 000000000..eab5916f1 --- /dev/null +++ b/op-mode-definitions/include/ospfv3-linkstate-id.xml.i @@ -0,0 +1,15 @@ + + + + Search by Link state ID + + <x.x.x.x> + + + + #include + #include + #include + + + diff --git a/op-mode-definitions/include/ospfv3-self-originated.xml.i b/op-mode-definitions/include/ospfv3-self-originated.xml.i new file mode 100644 index 000000000..76054757b --- /dev/null +++ b/op-mode-definitions/include/ospfv3-self-originated.xml.i @@ -0,0 +1,13 @@ + + + + Show Self-originated LSAs + + vtysh -c "show ipv6 ospf6 database as-external $6 self-originated" + + #include + #include + #include + + + diff --git a/op-mode-definitions/show-ipv6-ospfv3.xml.in b/op-mode-definitions/show-ipv6-ospfv3.xml.in index 36bb5b40e..bbae74c75 100644 --- a/op-mode-definitions/show-ipv6-ospfv3.xml.in +++ b/op-mode-definitions/show-ipv6-ospfv3.xml.in @@ -45,12 +45,7 @@ vtysh -c "show ipv6 ospf6 border-routers" - - - Show OSPFv3 detailed border-router information - - vtysh -c "show ipv6 ospf6 border-routers detail" - + #include @@ -68,44 +63,7 @@ vtysh -c "show ipv6 ospf6 database" - - - Search by Advertising Router ID - - <x.x.x.x> - - - - - - Search by Link state ID - - <x.x.x.x> - - - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database adv-router $6 linkstate-id $8 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database adv-router $6 linkstate-id $8 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database adv-router $6 linkstate-id $8 internal" - - - - - + #include Search by Any Link state Type @@ -119,24 +77,9 @@ - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database * * $7 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database * * $7 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database * * $7 internal" - + #include + #include + #include @@ -150,98 +93,19 @@ vtysh -c "show ipv6 ospf6 database * $6" - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database * $6 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database * $6 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database * $6 internal" - - - - Search by Advertising Router ID - - <x.x.x.x> - - - vtysh -c "show ipv6 ospf6 database * $6 $7" - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database * $6 $7 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database * $6 $7 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database * $6 $7 internal" - - - + #include + #include + #include + #include - - - - - Show AS-External LSAs vtysh -c "show ipv6 ospf6 database as-external" - - - Search by Advertising Router ID - - <x.x.x.x> - - - - - - Search by Link state ID - - <x.x.x.x> - - - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database as-external adv-router $7 linkstate-id $9 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database as-external adv-router $7 linkstate-id $9 internal" - - - - - + #include Search by Advertising Router ID @@ -251,126 +115,16 @@ vtysh -c "show ipv6 ospf6 database as-external * $7" - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database as-external * $7 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database as-external * $7 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database as-external * $7 internal" - - - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database as-external detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database as-external dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database as-external internal" - - - - Search by Link state ID - - <x.x.x.x> - - - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database as-external linkstate-id $7 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database as-external linkstate-id $7 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database as-external linkstate-id $7 internal" - + #include + #include + #include - - - Show Self-originated LSAs - - vtysh -c "show ipv6 ospf6 database as-external self-originated" - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database as-external self-originated detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database as-external self-originated dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database as-external self-originated internal" - - - - Search by Link state ID - - <x.x.x.x> - - - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database as-external self-originated linkstate-id $8 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database as-external self-originated linkstate-id $8 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database as-external self-originated linkstate-id $8 internal" - - - - - + #include + #include + #include + #include + #include @@ -381,140 +135,17 @@ - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database as-external $6 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database as-external $6 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database as-external $6 internal" - - - - Show Self-originated LSAs - - vtysh -c "show ipv6 ospf6 database as-external $6 self-originated" - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database as-external $6 self-originated detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database as-external $6 self-originated dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database as-external $6 self-originated internal" - - - - - - Search by Advertising Router ID - - <x.x.x.x> - - - - - - Show dump of LSAs - - echo vtysh -c "show ipv6 ospf6 database as-external $6 $7 dump" - - - - Show LSAs internal information - - echo vtysh -c "show ipv6 ospf6 database as-external $6 $7 internal" - - - - - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database dump" - - - - Search by Link state ID - - <x.x.x.x> - - - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database linkstate-id $6 detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database linkstate-id $6 dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database linkstate-id $6 internal" - + #include + #include + #include + #include + #include - - - Show Self-originated LSAs - - vtysh -c "show ipv6 ospf6 database self-originated" - - - - Show details of LSAs - - vtysh -c "show ipv6 ospf6 database self-originated detail" - - - - Show dump of LSAs - - vtysh -c "show ipv6 ospf6 database self-originated dump" - - - - Show LSAs internal information - - vtysh -c "show ipv6 ospf6 database self-originated internal" - - - + #include + #include + #include + #include @@ -529,12 +160,7 @@ vtysh -c "show ipv6 ospf6 interface prefix" - - - More detailed interface prefix information - - vtysh -c "show ipv6 ospf6 interface prefix detail" - + #include @@ -546,12 +172,7 @@ vtysh -c "show ipv6 ospf6 interface prefix $6" - - - More detailed information - - vtysh -c "show ipv6 ospf6 interface prefix $6 detail" - + #include Matched interface prefix information @@ -577,12 +198,7 @@ vtysh -c "show ipv6 ospf6 interface $5 prefix" - - - More detailed interface prefix information - - vtysh -c "show ipv6 ospf6 interface $5 prefix detail" - + #include @@ -594,12 +210,7 @@ vtysh -c "show ipv6 ospf6 interface $5 prefix $7" - - - More detailed information - - vtysh -c "show ipv6 ospf6 interface $5 prefix $7 detail" - + #include Matched interface prefix information @@ -615,12 +226,7 @@ Show OSPFv3 linkstate routing information - - - Show detailed linkstate information - - vtysh -c "show ipv6 ospf6 linkstate detail" - + #include Show linkstate Network information @@ -641,12 +247,7 @@ vtysh -c "show ipv6 ospf6 neighbor" - - - Show detailed neighbor information - - vtysh -c "show ipv6 ospf6 neighbor detail" - + #include Show neighbor DR choice information @@ -673,12 +274,7 @@ vtysh -c "show ipv6 ospf6 route external-1" - - - Show detailed Type-1 External route information - - vtysh -c "show ipv6 ospf6 route external-1 detail" - + #include @@ -687,12 +283,7 @@ vtysh -c "show ipv6 ospf6 route external-2" - - - Show detailed Type-2 External route information - - vtysh -c "show ipv6 ospf6 route external-2 detail" - + #include @@ -701,12 +292,7 @@ vtysh -c "show ipv6 ospf6 route inter-area" - - - Show detailed Inter-Area route information - - vtysh -c "show ipv6 ospf6 route inter-area detail" - + #include @@ -715,20 +301,10 @@ vtysh -c "show ipv6 ospf6 route intra-area" - - - Show detailed Intra-Area route information - - vtysh -c "show ipv6 ospf6 route intra-area detail" - + #include - - - Show detailed route information - - vtysh -c "show ipv6 ospf6 route detail" - + #include Show route table summary @@ -758,12 +334,7 @@ vtysh -c "show ipv6 ospf6 route $5 match" - - - Detailed information - - vtysh -c "show ipv6 ospf6 route $5 match detail" - + #include -- cgit v1.2.3