MAbans
Registered
Thanks to some help from KSV I was able to figure out how to use PHP to launch a php script using the Terminal. From there I was able to configure crontab to run the php script at regular intervals. The problem is that stats I'm gathering with the PHP is from a gaming server and I need it to happen at faster interval than 1 min.
So I decided to use the sleep(), which give it a slight pause, function in php and configure it with in a for {} statment to run for a full year. Now if I was to run the php script like this:
it would continue to run the php even after me closing my terminal window, and at the regular interval I desire, but it does cease to work after a reboot. I read that I can configure /etc/rc to launch the desired command on system start, but when I set it up, looking like so:
Nothing happens. Clearly I'm doing something wrong. What insight can anyone provide on this? Thank you in advance..
So I decided to use the sleep(), which give it a slight pause, function in php and configure it with in a for {} statment to run for a full year. Now if I was to run the php script like this:
Code:
nohup php script.php &
it would continue to run the php even after me closing my terminal window, and at the regular interval I desire, but it does cease to work after a reboot. I read that I can configure /etc/rc to launch the desired command on system start, but when I set it up, looking like so:
Code:
##
# Run php script to gather halo stats
##
nohup php script.php &
Nothing happens. Clearly I'm doing something wrong. What insight can anyone provide on this? Thank you in advance..