textile_backup icon indicating copy to clipboard operation
textile_backup copied to clipboard

Restore Backup and Restart?

Open Huntooon opened this issue 5 years ago • 8 comments

When restoring a backup the server shuts down, the backup is restored but the server does not start up again. I use a shell script to launch the server automatically on a stop or crash. Is there any way I can modify this script or the mod to auto-restart after a backup restore? I'm quite sure this is standard but I will paste the script below. Any help would be greatly appreciated :)

#!/bin/bash
while true; do
java -server -Xmx10G -XX:MaxPermSize=10240M -jar creative.jar
echo "You have 5 seconds to stop the server using Ctrl-C. Server will restart otherwise"
sleep 5
done

Huntooon avatar Sep 06 '20 14:09 Huntooon

If I understand you correctly, you would like this script to restart server only after backup restore, right?

Szum123321 avatar Sep 06 '20 14:09 Szum123321

I would like the script to restart the server every time it stops, but including backup restore too. Because I have the issue that I restore the backup using the mod but the server does not get started again. Does that make sense?

Huntooon avatar Sep 06 '20 14:09 Huntooon

Oh. I'll see what can be done.

Szum123321 avatar Sep 07 '20 12:09 Szum123321

I'm sorry but for me it all works well. One thing I don't understand is what that -server options is.

Szum123321 avatar Sep 13 '20 13:09 Szum123321

what sort of script do you have running that allows your server to restart on a crash, or /stop command?

Huntooon avatar Sep 17 '20 03:09 Huntooon

Okay so If i launch my server, then do not take any backups and stop the server with /stop then the script I posted above works, and the server restarts automatically. However, if a backup has occurred, whether with /backup start or an automatic one, The server will shut down with /stop but will get stuck on [Server thread/INFO]: Thread Query Listener stopped aka the last line when the server shuts down. so for some reason the script start.sh that I posted does not recognize it when the server stops after it has taken a backup at any point. I have backup on shutdown off as well.

Huntooon avatar Sep 17 '20 03:09 Huntooon

Screen Shot 2021-01-17 at 12 43 45 PM Here is an example of this issue. after the backup is taken, if you do /stop the server gets stuck here.

It should do this: Screen Shot 2021-01-17 at 12 46 33 PM

I did not take a backup before doing /stop in the second picture.

Huntooon avatar Jan 17 '21 17:01 Huntooon

When restoring a backup the server shuts down, the backup is restored but the server does not start up again. I use a shell script to launch the server automatically on a stop or crash. Is there any way I can modify this script or the mod to auto-restart after a backup restore? I'm quite sure this is standard but I will paste the script below. Any help would be greatly appreciated :)

#!/bin/bash
while true; do
java -server -Xmx10G -XX:MaxPermSize=10240M -jar creative.jar
echo "You have 5 seconds to stop the server using Ctrl-C. Server will restart otherwise"
sleep 5
done

try Fabric_BackUp this is a fork from this mod

whes1015 avatar May 09 '22 00:05 whes1015