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 --- .../show-interfaces-ethernet.xml.in | 97 ++++++++++++++++++++++ 1 file changed, 97 insertions(+) create mode 100644 op-mode-definitions/show-interfaces-ethernet.xml.in (limited to 'op-mode-definitions/show-interfaces-ethernet.xml.in') 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 + + + + + + + + -- cgit v1.2.3