Cuberite Forum
MCServer Autoupdate Script (for Linux) - Printable Version

+- Cuberite Forum (https://forum.cuberite.org)
+-- Forum: Cuberite (https://forum.cuberite.org/forum-4.html)
+--- Forum: Discussion (https://forum.cuberite.org/forum-5.html)
+--- Thread: MCServer Autoupdate Script (for Linux) (/thread-1183.html)

Pages: 1 2 3


RE: MCServer Autoupdate Script (for Linux) - xoft - 07-17-2013

It probably doesnt respond well ,because the external stop commands aren't capable of stopping the console input thread. It will correctly shut down the world tick thread, the storage and the networking, but the server will hang there, waiting for a kill.

(07-17-2013, 02:07 AM)tigerw Wrote: If thou meanest this script, it should, once the wget address is changed.

I commend thee, dear sir. It is not often that one finds such a fine example of language on public foraBig Grin


RE: MCServer Autoupdate Script (for Linux) - bearbin - 07-17-2013

You should add auto system detection - it should be quite easy with uname -p (tells your processor type) Smile


RE: MCServer Autoupdate Script (for Linux) - tonibm19 - 07-18-2013

Finally get the restart on crash script working in linux, with crontab.
PHP Code:
<?php
$url 
'localhost';
$port 25565;
$pauseLength 10;
$fp = @pfsockopen($url$port);
if (!
$fp) {
  echo 
'SERVER DOWN! Rebooting it.',"\r\n";
  `
/usr/bin/pkill MCServer`;
  
sleep($pauseLength);
  `
cd /MCS`;
  `
./MCServer`;
} else {
  echo 
'SERVER UP :)';
}
?>
if you want to use it, remember that it assumes that MCServer executable is in /MCS directory.


RE: MCServer Autoupdate Script (for Linux) - tonibm19 - 07-19-2013

tigerw, everytime I log into your server it crashesConfused, sorry, mine also crashes but not too often. Can you enable core dumps in your server? Maybe we can get one. My server doesn't generate crashdumps, I don't know why.


RE: MCServer Autoupdate Script (for Linux) - tigerw - 07-24-2013

(07-19-2013, 05:20 PM)tonibm19 Wrote: tigerw, everytime I log into your server it crashesConfused, sorry, mine also crashes but not too often. Can you enable core dumps in your server? Maybe we can get one. My server doesn't generate crashdumps, I don't know why.

Should be fine now. Before, MCServer wasn't able to create a new player.json for a new player and crashed. It fixed itself. Huh