MOON
Server: Apache/2.2.31 (Unix) mod_ssl/2.2.31 OpenSSL/0.9.8e-fips-rhel5 mod_bwlimited/1.4
System: Linux csr818.wilogic.com 2.6.18-419.el5xen #1 SMP Fri Feb 24 22:50:37 UTC 2017 x86_64
User: digitals (531)
PHP: 5.4.45
Disabled: NONE
Upload Files
File: //usr/local/ssl/share/munin/plugins/ntp_kernel_pll_off
#!/bin/sh
# -*- sh -*-

: <<EOF

=head1 NAME

ntp_kernel_pll_off - Plugin to monitor the kernel's PLL offset for the
NTP status

=head1 CONFIGURATION

No configuration

=head1 AUTHORS

Unknown author

=head1 LICENSE

Unknown license

=head1 MAGIC MARKERS

 #%# family=auto
 #%# capabilities=autoconf

=cut

EOF

# $Id: ntp_kernel_pll_off.in,v 1.1.1.1 2006/06/04 20:53:57 he Exp $

if [ "$1" = "autoconf" ]; then
    ntpdc -c kern 2>/dev/null | 
    awk 'BEGIN { ev=1; }
         /^pll offset:/ { ev=0; } 
         END { if (ev == 0) { print "yes";} else { print "no"; } exit ev; }'
    exit 0
fi

if [ "$1" = "config" ]; then
    echo 'graph_title NTP kernel PLL offset (secs)'
    echo 'graph_vlabel PLL offset (secs)'
    echo 'graph_category time'
    echo 'graph_info The kernel offset for the phase-locked loop used by NTP'
    echo 'ntp_pll_off.label pll-offset'
    echo 'ntp_pll_off.info Phase-locked loop offset in seconds'
    exit 0
fi

echo -n 'ntp_pll_off.value '
ntpdc -c kern | awk '/^pll offset:/ { print $3 }'