Ad Widget

Collapse

UserParameter

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • olejak
    Junior Member
    • Aug 2016
    • 11

    #1

    UserParameter

    Hi,

    I have a stange issue with UserParameter.

    When I run the zabbix agent (3.0.4) as a daemon I have a UserParameter that not will get checked.

    From the agent log file (DebugLevel=5)
    Code:
    4507:20161018:135728.897 Requested [<UserParameter.name>]
    4507:20161018:135728.897 In zbx_popen() command:'<Shell command>'
    4550:20161018:135728.897 zbx_popen(): executing script
    4507:20161018:135728.897 End of zbx_popen():6
    4507:20161018:135728.901 In zbx_waitpid()
    4507:20161018:135728.901 zbx_waitpid() exited, status:0
    4507:20161018:135728.901 End of zbx_waitpid():4550
    4507:20161018:135728.901 EXECUTE_STR() command:'<Shell command>' len:25 cmd_result:'sh: <Shell command>: command not '
    4507:20161018:135728.901 Sending back [sh: fw: command not found]
    BUT, when I test the item-key via the cli I get this:
    Code:
    ./zabbix_agentd -t <UserParameter.name> -c /home/ezmon/etc/zabbix_agentd.conf
    <UserParameter.name>                [t|538]
    The log file says that the command is not found. When I run the command as the user the agent is running as the command works, no problem.

    Also I find it strange that item-key test works.

    Any input would be appreciated.
  • olejak
    Junior Member
    • Aug 2016
    • 11

    #2
    Solved

    Solved it by adding the right PATH to the init script

    Comment

    Working...