HarisB
Contributor
Contributor

Backup multiple VMs through VCB and BackupExec

Jump to solution

Hi all,

We are currently going through VCB setup process, and the goal is to eventually have around 60 VMs handled by VCB.

We've managed to get a single VM backup process working, sort of proof of concept.

What we need to do now is modify the process to allow us to backup 60 VMs accross 6 ESX hosts, while excluding 10-12 VMs backed up through regular BackupExec agents (DB servers etc.) We are interested only in FullVM type backup at this point, no file level backups.

I have found BackupExec interoperability module script modifications here:

http://searchservervirtualization.techtarget.com/tip/0,289483,sid94_gci1233940,00.html

According to the article, modifications allow (among other things) use of regular expressions in pre- and post-backup commands; so instead of:

until next backup runs, delete them before starting a new backup (this will allow us to have disk copy in addition to tape copy, tapes go off site so in case of limited disaster we can recover much faster)

2. Exclusion list would be in the form of a .txt file with one VM name per line (same as esxRanger's skippedservers.txt file), and VCB would be looking into this file to determine whether VMs should be backed up or skipped. File is prefered option so we can have backup operators edit the file without diving deeper into VCB.

I sincerely hope someone has done this already and will share it with others. I'm guessing a ZIP with all the modified files and quick instructions would be worth a lot of points

Thanks

Haris

0 Kudos
1 Solution

Accepted Solutions
Desmo
Enthusiast
Enthusiast

The latest VM Convertor allow convertion from a vcb backup - saves having to move the disc files from the proxy to the ESX. Makes the restore process much quicker adn ne messing with moving virtual disc files.

View solution in original post

0 Kudos
9 Replies
GBromage
Expert
Expert

User requirements (nice to have)

1. Leave exported files at <BACKUPROOT> until next

backup runs, delete them before starting a new backup

(this will allow us to have disk copy in addition to

tape copy, tapes go off site so in case of limited

disaster we can recover much faster)

This one's easy - don't run the postexec script at the end of the backup job.

Instead, have it run as the first command in the pre-exec script (so they unmount before the next backup job).

I hope this information helps you. If it does, please consider awarding points with the 'Helpful' or 'Correct' buttons. If it doesn't help you, please ask for clarification!
bjmoore
Enthusiast
Enthusiast

You might want to check out my post over in the VC 2.0 forum.

http://www.vmware.com/community/thread.jspa?threadID=94194&tstart=0

That script will allow you to manage an enter-separated list of vms instead of an elaborate command string, and will also ping the vms before it builds the string to make sure they're responding. Otherwise, the entire backup will fail.

Ben

HarisB
Contributor
Contributor

Hi Ben,

This is a nice script, and I just went through it all to see how it works - good idea, but not quite what I need - instead of pulling a list of VMs to backup from .txt, I need to pull a list of all VMs from VC, and then skip those specified in .txt.

The idea is that we'll much more often create VMs that we want automatically covered by VCB rather than VMs which should be skipped. So less maintenance there, plus the damage from forgetting to update .txt in the first case is no backup at all, while in second case we have an extra backup which we may not need.

I'll post where I stand with this in a minute, you may want to check it out to see if your script can be modified?

Thanks

0 Kudos
HarisB
Contributor
Contributor

Hi all,

I've managed to make the customizations mentioned in my first post work, so right now I am able to backup all VMs from a VC using a single pre-backup line, like this:

"C:\Program Files\VMware\VMware Consolidated Backup Framework\backupexec\pre-backup.bat" VCBTEST rx:*-FullVM

This works rather nicely, the challenge right now remains excluding specific VMs and finding an easy way to restore this stuff. To that end I followed advice given here:

http://www.vmware.com/community/thread.jspa?threadID=58818&tstart=0

about mounting the backup folder as NFS and doing vcbRestore directly from the console, but have found a weird problem: the .VMX file in the backup contains a line similar to this:

scsi0:0.fileName = "VM_HELPER-000001.vmdk

so restoring the VM through the method above results in "a file was not found" error when trying to start the VM. Changing this line in .vmx to point to the correct .vmdk file fixes things, but I'm looking to avoid this and to automate the whole process.

So in addition to other requirements, here is some more to think about (and to score points on) :-).

Cheers

0 Kudos
Desmo
Enthusiast
Enthusiast

The latest VM Convertor allow convertion from a vcb backup - saves having to move the disc files from the proxy to the ESX. Makes the restore process much quicker adn ne messing with moving virtual disc files.

View solution in original post

0 Kudos
HarisB
Contributor
Contributor

Desmo is correct for the restore part - Converter works as advertised and it removes the scsi0:0.fileName = "VM_HELPER-000001.vmdk problem described above.

Since this works nicely I abandoned NFS and vcbRestore approach, no need to complicate life.

As for other things, I've implemented exclusion file and am now looking into replacing ipaddr method with UUID so I can backup VMs that are turned off all the time (templates, duplicated etc.) as well as a couple of VMs without IPs.

Thanks

0 Kudos
OM4EVER
Contributor
Contributor

Converter (the new version) unfortunately has not worked for me in trying to do a restore. It sits at 3% for hours on end. There really don't seem to be any errors in the log files either. VMware support has suggested I go back to winscp and then doing a cmdline vcbrestore specifying the VC server and the full path to my backup. Not sure but I thought this was supposed to be smoother than this. Any ideas?

Thanks

0 Kudos
jmp8600
Enthusiast
Enthusiast

Haris,

Did you find out a way to exclude VM from backup? I am also in the process of setting up backups using VCB, but not able to find a way to exclude few VMs.

Thanks,

-jp

0 Kudos
OM4EVER
Contributor
Contributor

Ok, converter works now. We noticed that we were getting alot of errors on the network switch. Turns out it was either a bad port, cable or something else. In any case Converter does work as advertised. Thanks to all those who mentioned it here on the forums. I stil want to be able to test the vcbrestore cli method, mount a windows share in the esx host and see the vm restored.

0 Kudos