Back up a VMware ESX Server 3.x Virtual Machine's Files using Consolidated Backup and the
ProxyHost iDataAgent
Overview
Before You Begin
Configure the Environment
Create the PreScan
and PostBackup Batch Files
ProxyHost
iDataAgent Backup of a Virtual Machine
- File Backup
Related Topics
The illustration below shows an example of how the ESX Server, Virtual Machine(s),
and VCB Proxy Server are configured when using the ProxyHost and Windows File
System
iDataAgents to back
up the files for a VMware Virtual Machine running Windows 2003 Server:

- You must already be familiar with VMware ESX Server software.
- These procedures are based on a stand-alone VMware ESX Server version
3.x
or later.
- When entering data in the CommCell Console screens (e.g., when configuring
a subclient) all paths which contain a space must be in quotes, as shown in
the examples.
- The following conventions are used in all of the examples; for each
example, substitute the correct names for your environment instead of using
these:
- ESX server = esxserver.mydomain.com
- VCB Proxy Server = proxy.mydomain.com
- Virtual Machine = vmsys1.mydomain.com
ESX Server
- For backups performed from the VCB Proxy Server, the ESX Server installation
must support a SAN and the Consolidated Backup software features. Contact VMware
for proper installation and licensing requirements. No other software or modifications
are necessary on the Service Console in order to run Consolidated Backup.
Virtual Machines
- All Virtual Machines to be backed up from a VCB Proxy Server must reside
in a SAN. The SAN disks must be accessible by any VCB Proxy Servers to be used.
- Install the Window File System and ProxyHost
iDataAgents on the Virtual Machine;
since ProxyHost preserves the original mapping of files, folders, volumes
letters, etc., in the backup, this provides enhanced operability
for browse and restore (only when Windows is the guest operating system.)
VCB Proxy Server
- Windows 2003 Server with Service Pack 1 must be installed.
- Must have access to the SAN disks where the Virtual Machines reside.
- Consolidated Backup software must be obtained from VMware and installed
on each VCB Proxy Server to be used.
- Once the Consolidated Backup software is installed, the following changes/additions
must be made on each VCB Proxy Server:
The PreScan and PostBackup batch files are executed during the backup, to trigger
the VMware utilities to create a snapshot of the Virtual Machine's VMFS
disk image,
and do the following:
- Analyze, discover, and mount the disk image to the VCB Proxy Server as a
volume ready for backup (file backup.)
For a file backup of a Virtual Machine from the VCB Proxy Server, two batch files
are required; the PreScan batch file and PostBackup batch file.
PreScan Batch File – File Backup
For file backups of Virtual Machines with Windows 2003 Server as the guest operating
system, create the file prescan.bat in the
..\generic subdirectory referenced above. This batch
file will need the following contents:
cd <location of Consolidated Backup installation>\generic
cscript pre-command.wsf <location of Consolidated
Backup installation <FQDN of VM to backup> [<backup type>]
where <backup type> is either
fullvm or file.
Default is file.
Example for file backup:
cd "C:\Program Files\VMware\VMware Consolidated
Backup Framework\generic"
cscript pre-command.wsf "C:\Program Files\VMware\VMware
Consolidated Backup Framework" "vmsys1.mydomain.com" file
The cscript pre-command.wsf accesses part of
the installed Consolidated Backup package and performs the following when
prescan.bat is executed:
- The mount point on the VCB Proxy Server is determined. In this case it will
be C:\mnt which was created previously. (This
value can be changed by editing the config.js
file, also discussed previously.)
- The entire Virtual Machine File System, in this example
vmsys1.mydomain.com, will now be mounted under
C:\mnt using the following convention:
C:\mnt\<VM name>\letters\C
C:\mnt\<VM name>\letters\D
.
.
.
and so on. Assuming vmsys1.mydomain.com has
a single C: drive, it would mount to the VCB
Proxy Server as follows:
C:\mnt\vmsys1.mydomain.com\letters\C
Post Backup Batch File – File Backup
For file backups of Virtual Machines with Windows 2003 Server as the guest operating
system, once the backup is completed, the files will need to be unmounted from the
VCB Proxy Server. Create the file postbackup.bat
in the ..\generic subdirectory referenced above.
This batch file will need the following contents:
cd <location of Consolidated Backup installation>\generic
cscript post-command.wsf <location of Consolidated
Backup installation> <FQDN of mounted Virtual Machine>
Example:
cd "C:\Program Files\VMware\VMware Consolidated
Backup Framework\generic"
cscript post-command.wsf "C:\Program Files\VMware\VMware
Consolidated Backup Framework" "vmsys1.mydomain.com"
The cscript post-command.wsf accesses part of
the installed Consolidated Backup package and performs the following when
postbackup.bat is executed:
- The mount is removed from the VCB Proxy Server, leaving only the
C:\mnt directory.
To perform a file backup of a Virtual Machine with Windows 2003 Server as the
guest operating system, perform these steps:
- Install both the ProxyHost and the Windows File System
iDataAgents on the Virtual Machine;
install the Windows File System iDataAgent
on the designated VCB Proxy Server running the Consolidated Backup software.
For instructions, see
Installation.
- Create the PreScan and PostBackup batch files if you have not already done
so. See Create the PreScan
and PostBackup Batch Files.
- Create a subclient for the ProxyHost iDataAgent
on the Virtual Machine. See
Create
a New Subclient for instructions and use the following information:
General Tab:
Content Tab:
- Backup Host: Select the name of the designated VCB Proxy Server. In
our example, this would be proxy.mydomain.com.
- Content: C:\
This is what will be backed up from the VM
- Backup Host BCV Path: C:\mnt\vmsys1.mydomain.com\letters\C
This is the path where the Virtual Machine will be mounted on the VCB
Proxy Server once prescan.bat executes.
Pre/Post Process Tab:
- PreScan: "C:\Program Files\VMware\VMware
Consolidated Backup Framework\generic\prescan.bat"
- PostBackup: "C:\Program Files\VMware\VMware
Consolidated Backup Framework\generic\postbackup.bat"
- Select On BackupHost.
This specifies that these scripts will run on the VCB Proxy Server, not
on the Virtual Machine.
- Select Run Post Backup process for all attempts.
Storage Device Tab:
- Select the appropriate Storage Policy.
The following occurs when a backup is performed using the ProxyHost subclient
you created.
- The PreScan batch file, prescan.bat, will
execute on the VCB Proxy Server, proxy.mydomain.com,
invoking the VMware vcbMounter utility, which
creates a snapshot of the Virtual Machine, then mounts the root file system
(C:\) of vmsys1.mydomain.com
to C:\mnt\vmsys1.mydomain.com\letters\C on
proxy.mydomain.com. The Virtual Machine continues
to function normally.
- The backup runs on the VCB Proxy Server, proxy.mydomian.com.
Note that it does not run on the Virtual Machine, even though the subclient
was configured there.
- After the backup completes, postbackup.bat
executes on the VCB Proxy Server, removing the mount
C:\mnt\vmsys1.mydomain.com\letters\C on
proxy.mydomain.com, and deleting the snapshot.
NOTES
- Full, Incremental, Differential, and Synthetic Full Backups are supported.
- When performing file system restores, the ProxyHost
iDataAgent will provide mapping of
the mount c:\mnt\vmsys1.mydomain.com to
c:\, greatly simplifying the process.