EXEC and SYSTEM delay
am 08.07.2009 22:15:08 von alberto
------=_NextPart_000_00D8_01C9FFE7.434603C0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Fellows:
I'm experimenting problems with a call that I made to exec or system. =
The problem is that the script await for the function finish and that =
take's a lot of time.
I need a way to use those functions in order to continue without await =
for it.
Saludos Fraternales
_____________________________
Atte.
Alberto Garc=EDa G=F3mez M:.M:.
Administrador de Redes/Webmaster
IPI "Carlos Marx", Matanzas. Cuba.
------=_NextPart_000_00D8_01C9FFE7.434603C0--
Re: EXEC and SYSTEM delay
am 23.07.2009 14:48:18 von Sam Stelfox
Well if the server your running on is linux based (and I haven't tried
this) you could try adding a nohup and background the task for example
rather than doing:
system('updatedb');
try
system('nohup updatedb &');
It should background the task and let it continue running even when the
php script finishes it's execution. Like I said I haven't tested it. As
a side note I used 'updatedb' in the example because it was the longest
running task I could think of off the top of my head and requires root
priveledges... You really shouldn't run your scripts as root. *A public
server announcement*
Alberto García Gómez wrote:
> Fellows:
>
> I'm experimenting problems with a call that I made to exec or system. The problem is that the script await for the function finish and that take's a lot of time.
>
> I need a way to use those functions in order to continue without await for it.
>
> Saludos Fraternales
> _____________________________
> Atte.
> Alberto García Gómez M:.M:.
> Administrador de Redes/Webmaster
> IPI "Carlos Marx", Matanzas. Cuba.
>
--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php