Ad Widget

Collapse

UserParameter not working

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • druber
    Junior Member
    • May 2012
    • 5

    #1

    UserParameter not working

    I am trying to set up a simple graph based on a temperature reading in a wml-file. This works on the command line, but in zabbix_agentd.conf it doesn't work. At least the item ends up with a status of "Not supported". I have managed to set up custom UserParamater successfully before, and I don't think I have done this one differently. Is it something with the commands that doesn't agree with the way things work in the conf-file? Any ideas?

    Code:
    /usr/bin/curl -s www.iis.niva.no/mfs/ws/wap/index.wml | grep -E Temperatur | sed -e 's/Temperatur: //' -e 's/ C<br\/>//'
    Best regards,
    Druber
  • eskytthe
    Senior Member
    Zabbix Certified Specialist
    • May 2011
    • 363

    #2
    Full path to grap and sed?
    Special chars? - check notes re UnsafeUserParameters here:
    http://www.zabbix.com/documentation/...userparameters
    /Erik

    Comment

    • druber
      Junior Member
      • May 2012
      • 5

      #3
      Unsafe parameters is on. Added full paths to grep and sed, but the items still ends up "Not supported". I tried this command on the server, and pointing that to the client it retuned a correct result of 9.8

      Code:
      zabbix_get -s xx.xxx.com -k niva.oslotemp

      Edit, it works, I just wasn't patient enough Thank you, Erik!
      Last edited by druber; 15-05-2012, 13:47.

      Comment

      • druber
        Junior Member
        • May 2012
        • 5

        #4
        Edited my post yesterday; it works after trying Eriks suggestions. I did however have to change "type of information" from "Numeric (unsigned)" to "Numeric (float)" too.

        Comment

        Working...