Ad Widget

Collapse

UserParameter wierdness

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • erisan500
    Senior Member
    Zabbix Certified Specialist
    • Aug 2005
    • 285

    #1

    UserParameter wierdness

    Hi all,

    I have digitemp installed to poll the values of 1wire devices (like temp, hum., etc)

    But i can't get it to work in Zabbix.

    zabbix_agentd.conf:
    Code:
    UserParameter=digi.rack.top,/opt/digitemp -c /opt/digi.conf -q -t 0
    UserParameter=digi.rack.mid,/opt/digitemp -c /opt/digi.conf -q -t 1
    I can run digitemp as user zabbix with no problems:
    Code:
    [zabbix@mgmt bin]$ /opt/digitemp -c /opt/digi.conf -q -t 0
    20.937500
    When I run as user zabbix zabbix_agentd -t digi.rack.top i get:
    Code:
    [zabbix@mgmt bin]$ ./zabbix_agentd -t digi.rack.top
    digi.rack.top								 [t|20.937500]
    So i can assume digitemp and the zabbix_agentd are working ok (?)

    When I run as user zabbix zabbix_get -s localhost -k digi.rack.top i get:
    Code:
    [zabbix@mgmt bin]$ ./zabbix_get -s localhost -k digi.temp.top
    ZBX_NOTSUPPORTED
    Anyone got i clue what could be wrong?

    Greetings
    EriSan
    Zabbix Certified Specialist
  • Alexei
    Founder, CEO
    Zabbix Certified Trainer
    Zabbix Certified SpecialistZabbix Certified Professional
    • Sep 2004
    • 5654

    #2
    Version of ZABBIX?
    Alexei Vladishev
    Creator of Zabbix, Product manager
    New York | Tokyo | Riga
    My Twitter

    Comment

    • erisan500
      Senior Member
      Zabbix Certified Specialist
      • Aug 2005
      • 285

      #3
      Oops, sorry,

      the latest 1.1
      EriSan
      Zabbix Certified Specialist

      Comment

      • erisan500
        Senior Member
        Zabbix Certified Specialist
        • Aug 2005
        • 285

        #4
        Some additional log info:

        Run zabbix_agentd -t digi.rack.top
        Result in zabbix_agentd.log:

        Code:
        013920:20060704:102413 Run remote command [/opt/digitemp -c /opt/digi.conf -q -t 0] Result [10] [20.812500]
        Run zabbix_get -s localhost -k digi.rack.top
        Result in zabbix_agentd.log:

        Code:
        004905:20060704:102442 In check_security()
        004905:20060704:102442 Connection from [127.0.0.1]. Allowed servers [127.0.0.1] 
        004905:20060704:102442 Before read()
        004905:20060704:102442 After read() 2 [14]
        004905:20060704:102442 Got line:digi.rack.top
        004905:20060704:102442 Run remote command [/opt/digitemp -c /opt/digi.conf -q -t 0] Result [0] []
        004905:20060704:102442 Sending back:ZBX_NOTSUPPORTED
        Any help welcome
        EriSan
        Zabbix Certified Specialist

        Comment

        • erisan500
          Senior Member
          Zabbix Certified Specialist
          • Aug 2005
          • 285

          #5
          Solved

          I got it working finaly.

          It seems that the digitemp command is executed as "Others" instead of the zabbix user when callled from zabbix_get.
          So after adding rw permissions to the serial port for the others group it started working.

          Alexei, is this intended behavior?

          Greetings
          EriSan
          Zabbix Certified Specialist

          Comment

          Working...