Did you know?View is smart enough to backup its own database. If you jump onto one of your Connection Servers and navigate to C:\ProgramData\VMware\VDM\backups you should see a slew of .LDF files.
These are your automated backups. You can see when your last backup ran by launching the Horizon View Administration page and navigating to View Configuration > Servers > Connection Servers and looking at the Last Backup column.
Like any good admin, you take your own backupsYou don't want to rely only on these backups. They are local to the Connection Server after all, causing a single point of failure if you lose that VM for any reason. You can always copy the latest LDF to another server somewhere, or you can take a manual backup of the current state of the ADAM database. This is extremely simple and highly recommended!
NOTE: You'll also want to know what your data recovery password is before you can restore any backup you have. If you don't know what it is, you can change it by launching View Administrator > View Configuration > Global Settings > Security > Change data security password
Taking a manual backup of the ADAM database
Before we take the backup, you might be asking, "Do I need to take a backup of all my replica Connection Servers' databases?" The short answer is no, you need only take one backup. This is due to how the restore procedure is carried out (outlined below).
- First off, ensure your View environment isn't currently creating or deleting any VMs and disable all pools from provisioning
- Now get a console to your Connection Server
- Launch an elevated Windows Command Prompt
- Navigate to the directory you want the backup to reside temporarily and run
vdmexport > vdmconfig.ldf
- This created an LDF file on my desktop. You can compare its size to that of your automated backups (they should be similar)
- Let's move this LDF to a backup file share for safe keeping and you've got yourself a current ADAM database backup!
Restoring an ADAM database LDF backup
When it comes time to restore the ADAM database (preferably after Composer and vCenter databases have been restored) the simplest way to get View back up is to reinstall the Connection Server service.
- Uninstall the VMware Horizon View Connection Server software (from Add-Remove Programs / Programs and Features / appwiz.cpl / etc)
- Uninstall the AD LDS Instance VMwareVDMDS software (This is the ADAM instance which gets installed with View)
- Remove the ADLDS Role from Server Configuration
- Reboot the server
- Install the Connection Server software
- Be sure to choose Standard Server during install
- If you have replicas in the environment, we'll deal with those later.
- Decrypt the LDF backup you took earlier by launching command prompt and typing
vdmimport -d -f MyEncryptedexport.LDF > MyDecryptedexport.LDF
- This will prompt you to enter your data recovery password.
- Now you can import the database into the fresh ADAM instance by typing
vdmimport -f VDMConfig.LDF
- If this is your only Connection Server, you've successfully completed the database restore and View should be fully operational. If you have any replicas in the environment, these servers will need to be re-installed as replicas. Follow the same uninstall process from steps 1 - 4 and ensure you choose Replica during install.
For more information, check out VMware's KB for performing an end-to-end backup.
[…] View administrators should be familiar with the backup and restore procedure. Once again, having the right KB on hand will equip you to quickly restore data if needed. Be sure to bookmark Performing an End to End Backup and Restore for View. I also wrote about this process here. […]
ReplyDelete[…] View administrators should be familiar with the backup and restore procedure. Once again, having the right KB on hand will equip you to quickly restore data if needed. Be sure to bookmark Performing an End to End Backup and Restore for View. I also wrote about this process here. […]
ReplyDelete