Page Menu
Home
VyOS Platform
Search
Configure Global Search
Log In
Files
F118309961
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
860 B
Referenced Files
None
Subscribers
None
View Options
diff --git a/src/op_mode/show_ntp.sh b/src/op_mode/show_ntp.sh
index 85f8eda15..4b59b801e 100755
--- a/src/op_mode/show_ntp.sh
+++ b/src/op_mode/show_ntp.sh
@@ -1,34 +1,34 @@
#!/bin/sh
sourcestats=0
tracking=0
while [[ "$#" -gt 0 ]]; do
case $1 in
--sourcestats) sourcestats=1 ;;
--tracking) tracking=1 ;;
*) echo "Unknown parameter passed: $1" ;;
esac
shift
done
if ! ps -C chronyd &>/dev/null; then
echo NTP daemon disabled
exit 1
fi
PID=$(pgrep chronyd | head -n1)
-VRF_NAME=$(ip vrf identify )
+VRF_NAME=$(ip vrf identify ${PID})
if [ ! -z ${VRF_NAME} ]; then
VRF_CMD="sudo ip vrf exec ${VRF_NAME}"
fi
if [ $sourcestats -eq 1 ]; then
$VRF_CMD chronyc sourcestats -v
elif [ $tracking -eq 1 ]; then
$VRF_CMD chronyc tracking -v
else
echo "Unknown option"
fi
File Metadata
Details
Attached
Mime Type
text/x-diff
Expires
Sat, Oct 17, 12:53 AM (1 d, 12 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
4416732
Default Alt Text
(860 B)
Attached To
Mode
rVYOSONEX vyos-1x
Attached
Detach File
Event Timeline
Log In to Comment