How to Configure XenDesktop for SQL Database Mirroring

Configuring a Site for Use with a Mirrored Database

To configure a XenDesktop site for use with a mirrored SQL Server database, complete the following steps:

  1. Create an empty database on the principal with the “Latin1_General_100_CI_AS_KS” collation sequence.

    Note: If you plan to change the location of your secondary databases (Configuration Logging and Monitoring databases), you can create two more empty databases as above.

  2. Configure the mirror and notice that it starts mirroring. For more information, see How to: Prepare a Mirror Database for Mirroring (Transact-SQL)

  3. Deploy Desktop Studio using Advanced Deployment in one of the following ways:

    1. Create the database automatically; mirroring is detected without user intervention.

    2. Create the database manually; two scripts are generated: one to be executed on the principal and one to be executed on the mirror. If you are executing the scripts using SQL Server Management Studio, enable the SQLCMD mode before executing the scripts. After executing the scripts, test the database connection by clicking Test connection and continue through the remainder of the wizard.

To verify mirroring after the wizard has completed, run the PowerShell cmdlet get-configdbconnection and ensure that the Failover Partner is set in the connection string to the mirror.

Note: If you created separate database locations for the Secondary databases, you can follow the instructions at http://docs.citrix.com/en-us/xenapp-and-xendesktop/7-5/cds-install-config-intro/cds-change-db-location.html to change the location of Configuration Logging and Monitoring database. At this point the main database along with the secondary databases are in the same location.

Joining a Controller

To join a XenDesktop controller to an existing site that is configured to use a mirrored SQL server database, run the Join Existing Site wizard in one of the following ways:

  • Update the database automatically; mirroring is detected without user intervention.

  • Update the database manually; two scripts are generated: one to be executed on the principal and one to be executed on the mirror. If you are executing the scripts using SQL Server Management Studio, enable the SQLCMD mode before executing the scripts.

To verify mirroring after the wizard has completed, run the PowerShell cmdlet get-configdbconnection and ensure that the Failover Partner has been set in the connection string to the mirror.

Removing a Controller

To remove a XenDesktop controller from an existing site that is configured to use a mirrored SQL server database, run the Remove Controller wizard in one of the following ways:

  • Update the database automatically; mirroring is detected without user intervention.

  • Update the database manually; two scripts are generated: one to be executed on the principal and one to be executed on the mirror. If you are executing the scripts using SQL Server Management Studio, enable the SQLCMD mode before executing the scripts.

Related:

  • No Related Posts

Leave a Reply