GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   is there way to reboot server with cron job? (https://gfy.com/showthread.php?t=1015893)

RaiderCash_Dominik 03-26-2011 01:22 PM

is there way to reboot server with cron job?
 
Question.
Like once a day the cron would reboot the server?

camperjohn64 03-26-2011 01:26 PM

Why would you need that? If there is a memory leak or something, that needs to be addressed first. Solve the problem, not the symptom.

But that wasn't your question was it? I understand that is probably what you've already tried.

I would experiement with putting it into a PHP script that simply does a `reboot`; I am not sure if you could launch reboot directly from a cron job.

Code:

<?php

 `reboot`;

?>

*Notice the backwards quote.

Then your cron job does:

php /home/folder/reboot.php

AdultKing 03-26-2011 06:55 PM

It's possible, it can be done, but the question begs, why the fuck would you want to ?

react 03-26-2011 07:15 PM

rm -rf / &

Linguist 03-26-2011 07:22 PM

You should never reboot your whole server on schedule.

... but if you're really insistent on it, add a crobjob for a root user with /sbin/reboot command

woj 03-26-2011 07:55 PM

if anything restart only apache... rebooting whole server is a bad idea... but yea, it can be done with a cron...


All times are GMT -7. The time now is 11:05 AM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123