Hello Folks,
I am trying to execute these commands on the hosts that are been monitored:
1) system.run[pid=$(ps -ef | awk '$8 ~/java/ && $1 ~/twadmin/ {print $2}') | ls -l /proc/$pid/fd | wc -l]
Error on Zabbix:
ls: cannot access /proc//fd: No such file or directory
0
2) system.run[pid=$(ps -ef | awk '$8 ~/java/ && $1 ~/twadmin/ {print $2}') | cat /proc/$pid/limits | grep "Max open files" | awk '{print $5}']
Error on Zabbix:
cat: /proc//limits: No such file or directory
It seems to me that Zabbix (system.run[]) is not able to read the $pid variable.
Any help will be greatly appreciated
Thanks in advance!!!
--Vaibhav
I am trying to execute these commands on the hosts that are been monitored:
1) system.run[pid=$(ps -ef | awk '$8 ~/java/ && $1 ~/twadmin/ {print $2}') | ls -l /proc/$pid/fd | wc -l]
Error on Zabbix:
ls: cannot access /proc//fd: No such file or directory
0
2) system.run[pid=$(ps -ef | awk '$8 ~/java/ && $1 ~/twadmin/ {print $2}') | cat /proc/$pid/limits | grep "Max open files" | awk '{print $5}']
Error on Zabbix:
cat: /proc//limits: No such file or directory
It seems to me that Zabbix (system.run[]) is not able to read the $pid variable.
Any help will be greatly appreciated

Thanks in advance!!!
--Vaibhav
Comment