aboutsummaryrefslogtreecommitdiff
path: root/usr.sbin/ntp/scripts/ntpver
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin/ntp/scripts/ntpver')
-rwxr-xr-xusr.sbin/ntp/scripts/ntpver7
1 files changed, 7 insertions, 0 deletions
diff --git a/usr.sbin/ntp/scripts/ntpver b/usr.sbin/ntp/scripts/ntpver
new file mode 100755
index 000000000000..cb216e8a636c
--- /dev/null
+++ b/usr.sbin/ntp/scripts/ntpver
@@ -0,0 +1,7 @@
+#!/bin/sh
+# print version string of NTP daemon
+# Copyright (c) 1997 by Ulrich Windl
+# Modified 970318: Harlan Stenn: rewritten...
+# usage: ntpver hostname
+
+ntpq -c "rv 0 daemon_version" $* | awk '/daemon_version/ { print $2 }'