Ad Widget

Collapse

who can help me monitor the NTP server ?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • j-luo
    Junior Member
    • Nov 2009
    • 7

    #1

    who can help me monitor the NTP server ?

    i want to use zabbix 1.7.2 to check the ntp server
    i used the agent-check follow the manual,with net.tcp.service[service.ntp , ip],
    but the return value is 0, menas error.

    the ntpd running status is confirmed by using the command "ntpdate ip" from zabbix server

    i found the log with "connection refuse"
    and i found although the ntp server use the port 123 with UDP, the src/libs/zbxsysinfo/simple/ntp.c use the function "zbx_tcp_connect" which use SOCK_STREAM, not the SOCK_DGRAM......

    has anyone monitor the ntp server sucessfully and can give me a sample how to do it?
  • MrKen
    Senior Member
    • Oct 2008
    • 652

    #2
    Using the zabbix agent, I use proc.num[ntpd]. This shows the number of ntp daemons running (always = 1).
    And have a trigger defined for 'doesn't equal 1'.

    Works for me.

    MrKen
    Disclaimer: All of the above is pure speculation.

    Comment

    • j-luo
      Junior Member
      • Nov 2009
      • 7

      #3
      thank you very much

      so it means the service.ntp is useless?

      i can only use proc.num[ntpd] to get the count of daemon , not the seconds since 1970 declared by manual for net.tcp.service[service.ntp]

      Comment

      • MrKen
        Senior Member
        • Oct 2008
        • 652

        #4
        Originally posted by j-luo
        so it means the service.ntp is useless?

        i can only use proc.num[ntpd] to get the count of daemon , not the seconds since 1970 declared by manual for net.tcp.service[service.ntp]
        Useless?? Maybe. But it wouldn't work for me. But proc.num tells me what I want to know - that the service is running. I also have an item with system.localtime, so I can quickly compare the times between servers.

        BTW, net.tcp.service will return a value of 0, 1, or 2, not the seconds since 1970.

        MrKen
        Disclaimer: All of the above is pure speculation.

        Comment

        • j-luo
          Junior Member
          • Nov 2009
          • 7

          #5
          thank you very much

          that's what i want to do... compare the time between host and server...
          thank you for the information of system.localtime

          Comment

          • Tenzer
            Senior Member
            • Nov 2007
            • 316

            #6
            You could take a look at the PHP script I have posted previously, which queries a NTP server, and makes sure that it replies, instead of just checking that the service is running.

            Also, there is a page on the wiki, which contains some information about monitoring DNS and NTP.

            Comment

            Working...