NAUbackup / VmBackup

XenServer simple backup script
228 stars 62 forks source link

NFS Mount point for VmBackup #54

Closed loefflerman closed 6 years ago

loefflerman commented 6 years ago

Hi @all, first of all : great project !

I have a general question in understanding the concept of VmBackup. In my first try I mounted a NFS SR as Backup repository and struggled a bit with the pathnames to the Backup- and Logfile Directory but i got it to work. Now I digged deeper and found out that the concept is not to mount a NFS or CIFS SR. But what if poolmaster changes ? A direct NFS mount would only be available on one server. Do i get something wrong here ? And how about using a NFS SR as backup destination ? whats the drawbacks ?

I'm curious .. Regards, Markus

NAUbackup commented 6 years ago

Hi, Markus, and thank you first off.

The export from your server will be to your XenServers(s) as something like 10.11.12.13:/myshare 10.11.12.14:/myshare etc. and you'll create a directory on your XenServer(s) and mount the remote NFS share as nfshost.mydomain.org:/myshare /nfsmount (with various flags, of course) and then use /nfsmount as the directory you point to. I can supply more detailed NFS mount examples, if that would help.

As to the pool master, you can handle that with your cron job. We have separate jobs on each memmber of a XenServer pool and one is for the pool master, the other for a pool slave. As the cron job runs, it checks if the host is the pool master and if not, exits. The other cron job runs - if needed - only to back up anything you might have on any local SRs. If you don't have any VMs you want to back up on local SRs, you don't need the extra cron job.

Voila! That's pretty much all there is to it.

As to an NFS mount as a backup SR, first off you really don't want to mix contents on an SR with non-standard Citrix files. It could confuse things and even more importantly, if that area gets corrupted, you have defeated the idea of keeping you backups totally separate from your XenServer installation. We have actually two separate standalone servers that do the duty of backup devices and all backups go first to a primary. Then, asynchronously, the backups get synchronized to a secondary server and its storage, which are located in a totally separate building as part of our DR plan.

--Tobias

NAUbackup commented 6 years ago

I added documentation to the README file with details on how to set up an external NFS export on a remote server and configure it as well as the XenServer end. Please take a look and see if that was a helpful addition. It's at the very bottom of the README file.