Re: rebooting linux using php
| From: | Jason Reid | Date: | Thu, 18 Jul 2002 21:27:15 +0000 |
| Subject: | Re: rebooting linux using php | ||
| References: | 1 2 3 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-108338@lists.php.net to get a copy of this message | ||
Or you could do that using php:
#!/usr/local/bin/php -q
<?
echo
/usr/bin/shutdown -Fr now;
?>
(Note those are backticks, not apostrophes)
Jason Reid
jason@achost.ca
--
AC Host Canada
www.achost.ca
"Scott Fletcher" <scott@abcoa.com> wrote in message
news:20020718202308.75157.qmail@pb1.pair.com...
> If you're going to use the cron file (or crontab) then php wouldn't work
> because it is a programming languages for the web pages. For cron files
or
> crontab, you can use the bash shell or ksh or whatever you have. It's
> simple. All you had to do is to create a file on hte Unix/Linux machine
and
> do the following ...
>
> --clip--
> #!/usr/bash
>
> /usr/bin/shutdown -Fr now
> --clip--
>
> Then edit the crontab or cron to put in the time you want the machine to
be
> rebooted.
>
>
> "1lt John W. Holmes" <holmes072000@charter.net> wrote in message
> news:016201c22e91$ddb5a5c0$a529089b@TB447CCO3...
> > >>-Can we reboot a linux server using a php page?
> > >Yes.
> > >>-And is it recommended?
> > >No.
> >
> > Can I get the URL of that page so I can put it in my cron file?
> >
> > ---John Holmes...
> >
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>