Save Hold - Help Needed
I am quite bleary now from trying to figure this out.
I'm running Minecraft Bedrock Dedicated Server on Ubuntu 24, and the server is running in Screen.
I have a script which sends save hold and save query, and at the moment I am just rsyncing the entire world folder to a backup, but I'd like to do this right.
I can't seem to figure out how to output the results of save query such that I can then copy the specified files. I'd even like to just have a .txt to look through what the list entails, because save query returns around 500 items.
The end goal is to automate backups for the server. Any help, you'd be a lifesaver.
TapeWerm seems to have accomplished something along these lines here: [https://github.com/TapeWerm/MCscripts](https://github.com/TapeWerm/MCscripts), but built for docker, which I am not using in this case. Perhaps I should.
I'm running Minecraft Bedrock Dedicated Server on Ubuntu 24, and the server is running in Screen.
I have a script which sends save hold and save query, and at the moment I am just rsyncing the entire world folder to a backup, but I'd like to do this right.
I can't seem to figure out how to output the results of save query such that I can then copy the specified files. I'd even like to just have a .txt to look through what the list entails, because save query returns around 500 items.
The end goal is to automate backups for the server. Any help, you'd be a lifesaver.
TapeWerm seems to have accomplished something along these lines here: [https://github.com/TapeWerm/MCscripts](https://github.com/TapeWerm/MCscripts), but built for docker, which I am not using in this case. Perhaps I should.
Commentaires
* Downvote this comment if this post is poor quality or does not fit the purpose of r/Minecraft
* Downvote this comment *and report the post* if it breaks the [rules](https://www.reddit.com/r/Minecraft/wiki/rules)
----
(*Vote has already ended*)
Then you can parse that txt file with a simple script to grab just the file paths and rsync only those specific files instead of the whole world folder. Way more efficient than backing up everything
sudo -u mcserviceacct screen -S bedrock -p 0 -X stuff "save hold$(printf '\\r')"
sudo -u minecraft screen -S bedrock -p 0 -X stuff "save query$(printf '\\r')"
sudo -u minecraft screen -S bedrock -X hardcopy query\_output.txt
but unfortunately it just puts out the raw host output from screen, which is over 500 filenames, so it ends up not even being a complete list. Good news is you've got me to output something! Just gotta figure out how to actually capture what the bedrock service is trying to say without it being terminated.