Re: Daemon starting
| From: | Danny Shepherd | Date: | Mon, 22 Apr 2002 11:27:18 +0000 |
| Subject: | Re: Daemon starting | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-93969@lists.php.net to get a copy of this message | ||
Not played with them myself but you might want to take a look at the
system() and shell_exec() functions.
HTH
Danny.
----- Original Message -----
From: "Gilles Nedostoupof" <gne@eortc.be>
To: <php-general@lists.php.net>
Sent: Monday, April 22, 2002 12:28 PM
Subject: [PHP] Daemon starting
> Hi all,
>
> I'm looking for a simple method to start a linux daemon from a php
script...
> I've already tried to use sudo by giving rights to apache user to execute
> some scripts from /etc/rc.d/init.d ; I do a exec ("sudo
> /etc/rc.d/init.d/daemon start");
> Sometimes the daemon startup, sometimes no... I need to re-run the script
2
> or 3 times to start the daemon correctly.
> (Same problem with stopping the daemon...)
>
> Anybody have an idea?
>
> Gilles.
>