Sentora Support Forums
Best way to do a VPS Backup (Ubuntu) - Printable Version

+- Sentora Support Forums (https://senforums.mach-hosting.com)
+-- Forum: Sentora Forum Archives (https://senforums.mach-hosting.com/forumdisplay.php?fid=5)
+--- Forum: Sentora Public Support Forums v1.0.x (https://senforums.mach-hosting.com/forumdisplay.php?fid=32)
+---- Forum: General Support Forum v1.0.x (https://senforums.mach-hosting.com/forumdisplay.php?fid=36)
+---- Thread: Best way to do a VPS Backup (Ubuntu) (/showthread.php?tid=1268)

Pages: 1 2


Best way to do a VPS Backup (Ubuntu) - apinto - 03-13-2015

Hello,
I've been using Sentora on a VPS hosted with OVH.
So far, so good, it still has a long path to walk but sentora is going at a very good rhythm, Good Work!

Backups
I do know Sentora has a backup system, but that is only for sentora files and configs.
My question is: What is the best way to backup a Ubuntu 14.04 VPS?


Please consider the following:
  • It's a relatively limited VPS, I do not have the possibility to make backups from another disk (with the system offline).
  • My goal is to be able to easily restore the system in case of failure or to be able to move to another server, this includes Ubuntu user configs, Installed Packages, Sentora (inc Apache, Bind9 and other components of Sentora) and everything else I may not be taking in consideration.
  • (opcional) Backups would be done to my local machine, so they will not require a lot of free space on the VPS.
What I have already tried:
  • rsync Was a good option, however it has problems with crucial system files that are in use.
  • .tar user and config files and save a installed packages list, also a good option, probably my best chance at this moment; however I feel hard to know what to backup/restore and I would like a more automated solution.
I did searched the forum, and yes there are similar threads, however I felt that they either went into very specific use cases or did not got an appropriate solution.

Note: To thank the community for helping me with this I will make a detailed tutorial, here on Sentora Forum, with a How To Properly Backup your VPS Server.

Thank you in advance for the time you may spend helping me.

Kind Regards,
António Pinto


RE: Best way to do a VPS Backup (Ubuntu) - Blooddarkness - 03-13-2015

Your service provider do not offer backup?


RE: Best way to do a VPS Backup (Ubuntu) - Me.B - 03-13-2015

If you use a VPS, it's trivial you can do easily snapshots for backup and that do the trick.

If you want to do it on your side, depend on your goal. Full restore in one wave, then you need to have a low level disk backup system, or restoring DB, Emails, websites and key config files, then you will need to build a strategy for each services with it's requirement.

M B


RE: Best way to do a VPS Backup (Ubuntu) - apinto - 03-13-2015

It would be trivial, but as I said the service provider doesn't provide snapshots neither backups.
That is why I'm asking help Smile


RE: Best way to do a VPS Backup (Ubuntu) - Me.B - 03-13-2015

If it's very important you should think about changing ISP, beside that check the second part where

Disk cloning:

http://www.cyberciti.biz/open-source/linux-based-disk-cloning-imaging-software/

Or only as I Said backup DB/ Websites/emails.

M B


RE: Best way to do a VPS Backup (Ubuntu) - apinto - 03-13-2015

This server wont be used for anything critical, its cheap, good to test things.
Even without anything critical, I wanted to have a easy rollback process (because as I'm testing new things it might easily break).

I'll check your suggestion and post feedback after.

Thank you.


RE: Best way to do a VPS Backup (Ubuntu) - apinto - 03-19-2015

Hello again.
After some investigation I dumped the idea of a full system backup due to my VPS restrictions and the fact that it probably will be faster to restore Sentora configs and user data/files than to restore a full system backup of 10gb over the internet...

This brings me to a few questions (maybe newbie ones...):
How do I do a full SENTORA Backup, so that I can just install Sentora and restore all the configs, user accounts, DNS entries, vhosts changes, etc?

The current backup system only backups the user hostfiles and databases,
What about the sentora itself?
What folders should I keep a backup of?

There are some folders that I know I should backup (like /etc/sentora/) but I'm not sure if I'm missing anything.

Sorry for such a newbie question, I did searched around but could not find anything to help.

Thank you for your time!


RE: Best way to do a VPS Backup (Ubuntu) - xanaul - 03-23-2015

i'd also am interested in this.

almost because i'm thinking of implementing a poor man's high availablity solution:

[vps1] & [vps2]

have concurrent copies of the exact same data ( user, web, etc ) that are synced on a weekly/nightly basis. but only [vps1] is turned on and active. [vps2] has all services turned off.

if one or the other fails for some reason, a manual dns change-over is done to point the dns server ips to the ip of vps2, but sentora needs to allow a way to 'change' the ip all it's services belong to, in a cli/scripted way.. that could be triggered as part of the manual failover routine, and restart all services afterwards.

for example, vps1 is rebooted or reassigned a new ip, how do you ensure sentora picks up and configures all the virtual hosts to now point to the new ip within the box?


RE: Best way to do a VPS Backup (Ubuntu) - Me.B - 03-23-2015

sentora default vhosts to all ip's ;-)


RE: Best way to do a VPS Backup (Ubuntu) - xanaul - 03-24-2015

(03-23-2015, 07:04 PM)Me.B Wrote: sentora default vhosts to all ip's ;-)

So the initial setup where it resolves the subdomain to an ip is not relevant?
How would the sentora box hosted DNS server module modify the inherent A records to the new ip? and the apache configs, if they are hardcoded ( not sure if they are )