Cuberite Forum

Full Version: MCServer Autoupdate Script (for Linux)
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
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
You should add auto system detection - it should be quite easy with uname -p (tells your processor type) Smile
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.
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.
(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
Pages: 1 2 3