Backup script improvement proposal
Expected Behavior
I propose the following improvement to the backup process. This will reduce expense costs on AWS, as well as reduce space on the VPS server and reduce risks of maxing available space.
- The node backup data is zipped upon generation to reduce space used.
- Data is uploaded on AWS
- The local backup created is deleted to reduce space
Actual Behavior
- Data is backed up without any archiving
- Backup is uploaded on AWS
- Backup remains on the server, which raises a risk of maxing the available space with scheduled backups.
Steps to Reproduce the Problem
- Backup steps as detailed on https://otnode.com/node-backup/
Specifications
- Version: 5.0.0
- Platform: Ubuntu 20
That's a great idea.
One thing to mention some users might not like zip (and prefer 7z), or maybe AWS is not their preferred storage vendor. So adding things is great, but let's also keep an option for the most basic backup process, where script just saves the required content to a backup folder within a container (same as today).
Looking at the code it seems that the AWS script should remove the backup from the node server, we'll test this and see what should be changed if it's not doing that correctly.
I did some backups, the local backup is indeed successfully deleted, so that item 3. is no longer valid. Also a great point that some people do not want to zip it, so maybe include a second modified script which also zips the file before upload. Zipping data saves 40-50% of the file size, which would result in cheaper AWS costs.
This issue is not relevant because it was for v5 and current version of OT-node is v6.