Ad Widget

Collapse

Zabbix Agent and Include?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • jsosic
    Member
    • Apr 2008
    • 47

    #1

    Zabbix Agent and Include?

    I'm using an Include directive in my zabbix_agentd.conf, and it looks like this:

    Code:
    ...snip...
    ####### INCLUDE CONFIGURATIONS #######
    Include=/etc/zabbix/agent-conf.d
    ...snip...
    And, for example, my "/etc/zabbix/agent-conf.d/ntpd.conf" looks like this:
    Code:
    # ntpd
    UserParameter=ntp.offset,/usr/sbin/ntpq -pn | /usr/bin/gawk 'BEGIN { offset=1000 } $1 ~ /\*/ { offset=$9 } END { print offset }'
    UserParameter=ntp.jitter,/usr/sbin/ntpq -pn | /usr/bin/gawk 'BEGIN { offset=1000 } $1 ~ /\*/ { offset=$10 } END { print offset }'
    UserParameter=ntp.delay,/usr/sbin/ntpq -pn | /usr/bin/gawk 'BEGIN { offset=1000 } $1 ~ /\*/ { offset=$8 } END { print offset }'
    Now, I'm puzzled, when I strace zabbix_agentd, this file is listed as opened, but ntp.offset, ntp.jitter and ntp.delay seems to be ZBX_NOTSUPPORTED from the logs. If I move the enteries from ntpd.conf to zabbix_agentd.conf, then everything seems to work fine.

    Is this a bug with the agent, and Include directive?! The weirdest thing is that I have some plugins added this way that work ok, and other's dont...

    I really would not like to have to go through Agent code and to debug it, I just don' have the time... And the patch for zabbix_sender I wrote isn't even commented on this forums by anybody, so I guess it's pointless.
  • jsosic
    Member
    • Apr 2008
    • 47

    #2
    Alexei, have read this? Please post anything...

    Comment

    • jsosic
      Member
      • Apr 2008
      • 47

      #3
      OK, solution is here:

      Comment

      Working...