| Author |
Non-blocking system calls
|
|
| Chris Styles 2006-05-24, 6:58 pm |
| Hi,
I have an application that uses a PHP web front end to run some jobs on a
UNIX box. The jobs that it runs might take a while, so I'd like to run the
job in a non-blocking way so that the front end is free to be refreshed with
updates (from the output of the job)
It seems that system() and exec() are both blocking...
Does anyone have any ideas?
thanks
Chris
| |
| Colin McKinnon 2006-05-24, 6:58 pm |
| Chris Styles wrote:
> Hi,
>
> I have an application that uses a PHP web front end to run some jobs on a
> UNIX box. The jobs that it runs might take a while, so I'd like to run the
> job in a non-blocking way so that the front end is free to be refreshed
> with updates (from the output of the job)
>
> It seems that system() and exec() are both blocking...
>
> Does anyone have any ideas?
Yes - this is a FAQ. Read up on php's fork() and the 'at' command.
C.
| |
| Chris Styles 2006-05-24, 6:58 pm |
|
"Colin McKinnon"
<colin.thisisnotmysurname@ntlworld.deletemeunlessURaBot.com> wrote in
message news:rj2dg.4910$435.3416@newsfe4-gui.ntli.net...
> Chris Styles wrote:
>
>
> Yes - this is a FAQ. Read up on php's fork() and the 'at' command.
>
> C.
Sorry to have asked such a newbie question.... i clearly didn't use the
right keywords in Google....
Thanks...
Chris
| |
| Michael Vilain 2006-05-24, 6:58 pm |
| In article <iZ6dnVgOZ5MZLenZnZ2dnUVZ8smdnZ2d@bt.com>,
"Chris Styles" <chris.styles@no.spam.arm.com> wrote:
> Hi,
>
> I have an application that uses a PHP web front end to run some jobs on a
> UNIX box. The jobs that it runs might take a while, so I'd like to run the
> job in a non-blocking way so that the front end is free to be refreshed with
> updates (from the output of the job)
>
> It seems that system() and exec() are both blocking...
>
> Does anyone have any ideas?
>
> thanks
> Chris
submit a job through "at":
"at -m now <command line>"
--
DeeDee, don't press that button! DeeDee! NO! Dee...
|
|
|
|