The Data Protection for VMware command-line interface can be used to run backup tasks in a virtualized environment.
vmcli command >>-vmcli------ -f backup----------------------------------------> >--+---------------------------------------+--------------------> '- -t--backup_type--+-----------------+-' '- ,--backup_type-' >---- -I--backupObjectListFile----+------------------+----------> '- -D--deviceClass-' >--+--------------+---------------------------------------------> '- -H--esxHost-' >--+-------------------------------------------------------------------+--> '- --vmbackupmode--SNAPSHOT_INCL_MEM|SNAPSHOT_EXCL_MEM|SUSPEND|ASIS-' >--+---------------------------------+--------------------------> '- --start--scheduleStartDateTime-' >--+------------------------------+-----------------------------> '- --interval--intervalSeconds-' >--+-----------------------------+--+------------------+--------> '- --end--scheduleEndDateTime-' '- --priority--1-5-' >--+-------------------+----------------------------------------> '- --name -taskName-' >--+---------------------------------------+--+-----------+-----> '- --description -descriptionInFile.txt-' '- --runnow-' >--+----------------------------+------------------------------>< | (1) | '- -o--datamovernodename-----'
You can start the task immediately or create a schedule for it by using the --start, --interval, and --end parameters. The --start parameter postpones the task until a specified date and time. If you specify the --interval parameter, with the --start parameter, the task reruns at the specified interval. The --end parameter indicates the date and time when the task rerun ends.
You must specify the datastores that you want to back up in the input file that is specified by the -I backupObjectListFile parameter. You can specify a name for the task with the --name parameter and descriptive information for the task with the --description parameter.
If Tivoli Storage Manager for Virtual Environments is not installed, the backup type is always FCM and you can omit this parameter from the backup commands. For a Tivoli Storage FlashCopy Manager for VMware backup, you can overwrite the AUXILIARY_ESX_HOST and VM_BACKUP_MODE parameters in the Tivoli Storage FlashCopy Manager for VMware profile with command-line parameters -H and --vmbackupmode.
The backup snapshots are sent to the Tivoli Storage Manager server storage asynchronously by the fcmcli daemon.vmcli command >>-vmcli------ -f backup----------------------------------------> >--+-------------------------------------+----------------------> '- -t -backupType--+----------------+-' '- ,--backupType-' >---- -I--backupObjectListFile----+---------------+-------------> '- -B--backupID-' >--+-------------------+----------------------------------------> '- --name -taskName-' >--+---------------------------------------+--+-----------+-----> '- --description -descriptionInFile.txt-' '- --runnow-' >--+-------------------------+--+------------------------+----->< '- -d--datacenternodename-' '- -o--datamovernodename-'
To back up a datastore, enter the following command:
Where:
# Lines starting with # and blank lines will be ignored
#
# Wildcards ? and * are supported
# ? - any single character
# * - any character sequence (also empty)
# Wildcards are allowed for datastorename and
# vmname identifier
#
# Include statements are optional
# Includes may comprise datastoreurl and datastorename identifier
#
# Exclude statements are optional
# Exclude statements begin with a "!"
# Excludes may comprise datastorename, datastoreurl,
# vminstanceuuid and vmname identifier
#
#Include datastore with this URL in the backup
datastoreurl:dsUrl
#Include datastore with this name in the backup
datastorename:dsName
#Include datastores matching the wildcard string in the backup datastorename:
datastorename:ds?am*
#Include VM matching this instance uuid in the backup. Fails if it is not
#found within the included datastores which additionally need to be specified
#in the infile when this option is used
vminstanceuuid:vmInstanceUuid
Comments are allowed and must be marked with a '#' sign
at the beginning of the line.# Lines starting with # and blank lines will be ignored
#
# Wildcards ? and * are supported
# ? - any single character
# * - any character sequence (also empty)
# Wildcards are allowed for datastorename and
# vmname identifier
#
# Include statements are optional
# Includes may comprise datastoreurl and datastorename identifier
#
# Exclude statements are optional
# Exclude statements begin with a "!"
# Excludes may comprise datastorename, datastoreurl,
# vminstanceuuid and vmname identifier
#
#Exclude VM with this uuid from the backup
!vminstanceuuid:vmUuid
#Exclude VM with this name from the backup (needs to be unique)
!vmname:vmName
#Exclude all vms matching this wildcard string from the backup
!vmname:vmN*
#Exclude datastore with this URL from the backup
!datastoreurl:dsUrl
#Exclude all datastores matching this wildcard string from the backup
!datastorename:ds?am*
Comments are allowed
and must be marked with a '#' sign at the beginning of the line.