I have a script that I need to run for two hours during the day. I know how to use cron to start the script, but is there anyway to use cron to stop the script at the two hour mark?
The script grabs data from the web and updates a db. The script doesn't know when to start or stop. It just has an infinite loop that keeps grabbing the data so I can't stop the script from within itself.
Thanks.