When I setup a script media type, I get the following behavior.
If I send two parameters to the script, the script work fine.
The log record is as follows
9802:20160814:182406.743 In zbx_popen() command:'/usr/lib/zabbix/alertscripts/test.sh '+30693XXXXXX' 'OK: Viva is Up''
If I send three parameters to the script, the script does not execute
The log record for it, is as follows
10107:20160814:183057.375 In zbx_popen() command:'/usr/lib/zabbix/alertscripts/test.sh '+30693XXXXXX' 'OK: Viva is Up' 'Trigger: Viva is Up
As you can see, two single quotes are missing from the end of the command.
One single quote to close the string for the third parameter and one to close the string for the whole command.
Can anyone help on this?
If I send two parameters to the script, the script work fine.
The log record is as follows
9802:20160814:182406.743 In zbx_popen() command:'/usr/lib/zabbix/alertscripts/test.sh '+30693XXXXXX' 'OK: Viva is Up''
If I send three parameters to the script, the script does not execute
The log record for it, is as follows
10107:20160814:183057.375 In zbx_popen() command:'/usr/lib/zabbix/alertscripts/test.sh '+30693XXXXXX' 'OK: Viva is Up' 'Trigger: Viva is Up
As you can see, two single quotes are missing from the end of the command.
One single quote to close the string for the third parameter and one to close the string for the whole command.
Can anyone help on this?
Comment