Mar 13, 2010, 4:41 PM
So, the script is actually being executed, but the backticks command is failing, is that correct?
Re: [dzordzyk] Executing script from cron.d
If so then the problem is a difference in the environment. In this case it's the path environment. This is one of the main reasons you should provide full paths when shelling out.
$ps_output = `ps ax | grep "$service" | grep -v $0 | grep -v grep`;
adjust the path as needed
$ps_output = `/bin/ps ax | /bin/grep "$service" | /bin/grep -v $0 | /bin/grep -v grep`;
(This post was edited by FishMonger on Mar 13, 2010, 4:44 PM)