Forum Moderators: bakedjake

Message Too Old, No Replies

Cron Job Help :-)

Open File Command?

         

Iklekid

12:39 pm on Jan 2, 2003 (gmt 0)

10+ Year Member



Hi, I can run cron jobs on my hosting package! I have been told I cant run the Cron vefry often as it uses a lot of CPU time!

Is there a way for the cron job to open a file and keep it open? The page I want to open is a php file and has a refresh script for every 15 minutes!

What i want is for the cron tab to execute the file every 24 hours but the page to be kept open so that it refreshes every 15 minutes!

Is this possible at all? If yes what would I have to put in the command line?

Thanks in advance!

Iklekid

Duckula

3:18 am on Jan 3, 2003 (gmt 0)

10+ Year Member



By your request, you want

1. Execute a script every 24 hours.
2. Keep it on memory so it executes itself every 15 minutes.

That doesn't look very sound. Your web server has not a "included web browser", so the refresh would not be as easy as keeping Mozilla permanently open.

I'd recommend to simply put different directives on cron, one for the daily execution, let's say everyday at 4:00 am, and others for the quarter hour execution. Forking every fifteen minutes is not a cpu sink, so you'll be fine :) The only savings by keeping open the script would be on I/O anyway.

Iklekid

9:30 am on Jan 3, 2003 (gmt 0)

10+ Year Member



ok thanks Duckula! Ill run the cron job every 15 mins and see if my hsot ses anything!

Thanks :-)

Iklekid