Deploying App Volumes in a multi-site scenario takes proper planning and consideration. You need to consider a lot of different factors that will influence the level of availability. For example, how quickly must your users be up and running in case the main site goes down?
VMware explains the two main options for an App Volumes multi-site deployment in the VMware Horizon 7 Enterprise Edition Multi-Site Reference Architecture. The second option covered in the Reference Architecture is to have two App Volumes Manager instances with separate SQL databases. The main drawback to this option is that the entitlements must be reproduced in both sites.
There might be other reasons why you also need this kind of setup, even with a single site (entitlement replication between different staging environments, for example). The configuration in the previous diagram is for two sites, but the following information applies to either a single-site or multi-site deployment.
A simple but very effective way of replicating entitlements is to use a PowerShell script. We want to provide the script to be able to do this. You can either run this script manually or program it through Windows Scheduler.
There are a few things you need for this script to work. Always keep in mind that this script can be run locally on the server, but also can be ran remotely, from an account with proper permissions.
- Windows Management Framework 4.0
- Microsoft .NET Framework 4.5
The script replicates entitlements, but it does not copy AppStacks, so you must make sure that the AppStacks are present in both sites. You can easily do this manually with a simple copy, but you can also automate the copy by creating storage groups (more information in the App Volumes Deployment Considerations paper) and having a setup that resembles the configuration in the previous image.
App Volumes Replication Script
We have posted the suggested App Volumes replication script here
Copy and paste the script, then edit the username, password, source server, and destination server to match your environment. Remember to save the file with a ps1 extension. As mentioned, you can run this script manually by opening a PowerShell window.
We recommend you try this script at least once to see how it works for you, and then, after you are satisfied with the results, you can schedule the script to run at regular intervals by creating a scheduled job.
Important: If you are doing a multi-site deployment and want both sites to be available and have matching entitlements, follow the recommendations in the VMware Horizon 7 Enterprise Edition Multi-Site Reference Architecture. This script will help you to replicate entitlements when using separate databases in multiple sites or in a single site.