VMware Cloud Community
rightfoot
Enthusiast
Enthusiast

Live running backups

I have some ESXi servers which are attached to one of my fibre channel arrays.

All of the guests run directly off of the array. The way I back these guests is to power each one off, export it then turn it back on. This is the only way I know of to make an off-storage backup in case that storage ever fails.

My question is, since I've not tested this, could I simply make a full backup of the datastore as all of the guests are running? I realise I would not get a memory snapshot but would I still get a proper copy of the guest which I could re-deploy is needed?

Reply
0 Kudos
11 Replies
vmroyale
Immortal
Immortal

Hello.

Yes you can make a full copy of the datastore while the guests are running, using tools on your SAN.  The key, as you mentioned, is to test it repeatedly for consistency of the VMs.  The exports of powered off VMs will always be consistent, assuming they were shut down properly, but with the full datastore copy you may get mixed results.  What SAN are you using, and what tools do you have on the SAN?

Good Luck!

Brian Atkinson | vExpert | VMTN Moderator | Author of "VCP5-DCV VMware Certified Professional-Data Center Virtualization on vSphere 5.5 Study Guide: VCP-550" | @vmroyale | http://vmroyale.com
Reply
0 Kudos
rightfoot
Enthusiast
Enthusiast

In this case, the esxi servers are connected directly to datadirect/iqstor FC arrays.

The arrays aren't licensed for snapshots or mirroring or anything else interesting of that type where I could make a snapshot to another physical device.

My only option is to stop the guests, export, start them back up and that's becoming a heck of a chore not to mention down time.

We aren't ready or able to afford esx so need to get by in some other way until then.
I can live without many of the features such as live migrations but no one can live without proper backups.

I'm not sure how I would test for consistency other than firing up a backup copy now and then to see if it remains instact and runs?

I need a way to copy the entire datastore while the servers are running so that I have backups which aren't only on the same storage device.

Reply
0 Kudos
DSTAVERT
Immortal
Immortal

An ESXi based snapshot would allow you to copy off the base disk while the VM is running using the datastore browser. Most of the Commercial backup applications would require a non free version of ESXi. Have a look at Trilead for a simple low cost option.

-- David -- VMware Communities Moderator
Reply
0 Kudos
rightfoot
Enthusiast
Enthusiast

>An ESXi based snapshot would allow you to copy off the base disk while the VM is running using the datastore browser.

I'm not sure what an off the base disk means, can you explain this more? Do you mean that I can take a snapshot of the guest, then back up the snapshot itself as a means of accomplishing what I need?

Can such a file be re-deployed later, how does one re-deploy such a backup? I'm used to using export and deploy only using the .ovf files.

It dawns on me that the .mf and .ovf files would never change would they, unless I made a change to the settings.

I notice the snapshot file is much smaller than the Virtual Disk file so not sure how I would put this together.

Reply
0 Kudos
DSTAVERT
Immortal
Immortal

Snapshots in VMware terms are different than storage snapshots. http://kb.vmware.com/kb/1015180

A snapshot is a new disk and all new disk writes are written to that disk. Since the base disk is no longer active it can be copied off. Once the file is copied off you would use the Snapshot Manager to commit the snapshot which merges the snapshot and the base disk.

-- David -- VMware Communities Moderator
Reply
0 Kudos
DSTAVERT
Immortal
Immortal

You can use http://communities.vmware.com/docs/DOC-9852 the ghettoVCB2 script to schedule a cloning operation on any or all your VMs. You would need to use the ghettoVCB script if you are using the free version.

-- David -- VMware Communities Moderator
Reply
0 Kudos
DSTAVERT
Immortal
Immortal

You only need the vmdk files (other than the snapshot delta.vmdk files) and the vmx file to make a complete copy of a VM. If you have also taken a memory snapshot you would also need the vmsn file. Simply point the datastore browser to the location of the files, select the VMX file and add it back to inventory to restore the VM

-- David -- VMware Communities Moderator
Reply
0 Kudos
rightfoot
Enthusiast
Enthusiast

Do you basically mean just copy all of the files then point to that storage from another esxi server or the same one if there is a crash?

Currently, I do move guests around by shutting them off on one esxi server, adding it to inventory on another and firing it back up. Is that all that this really amounts to?

Reply
0 Kudos
DSTAVERT
Immortal
Immortal

That is correct. The only exception is the delta.vmdk files. They should not be copied since they are active. The VMX file should be copied before the snapshot is taken since it will then point to the delta.vmdk. I would have a look at the ghettovcb scripts. If you set up a shared storage location and add it to each ESXi host you would have a destination backup destination. An inexpoensive NAS device that supports NFS or a standard Linux install will work just fine.

-- David -- VMware Communities Moderator
Reply
0 Kudos
rightfoot
Enthusiast
Enthusiast

I use various filer heads which allow me to manage FC storage resources so can copy to network NFS shares.

I'll check out the script and see if I can get that running then update this thread. It might take a few days but if I can work on it today, I will.

Thanks.

Reply
0 Kudos
DSTAVERT
Immortal
Immortal

The ghettoVCB2 script is available at http://communities.vmware.com/docs/DOC-9843 It is well documented. If you aren't using a licensed version you would need http://communities.vmware.com/docs/DOC-8760 but the link was broken during the rescent VMware Communities upgrade.

-- David -- VMware Communities Moderator
Reply
0 Kudos