Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases now! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Hyper-V Network Virtualization Cookbook

You're reading from   Hyper-V Network Virtualization Cookbook Over 20 recipes to ease the creation of new virtual machines in the networking layer using Hyper-V Network Virtualization

Arrow left icon
Product type Paperback
Published in Nov 2014
Publisher
ISBN-13 9781782177807
Length 228 pages
Edition 1st Edition
Tools
Arrow right icon
Author (1):
Arrow left icon
Ryan Boud Ryan Boud
Author Profile Icon Ryan Boud
Ryan Boud
Arrow right icon
View More author details
Toc

Table of Contents (11) Chapters Close

Preface 1. Installing Virtual Machine Manager FREE CHAPTER 2. Configuring Networks for Hyper-V Network Virtualization 3. Creating the Gateway for Virtual Machine Communications 4. IP Address Management Integration with VMM for Hyper-V Network Virtualization 5. Windows Server Gateway Configuration 6. Implementing Network Isolation in Hyper-V 7. Network Access Control Lists A. VM Templates B. Planning the Virtual Machine Manager Index

Installing a highly available Virtual Machine Manager server

This recipe provides the steps required to install VMM on a multiserver environment. This will involve creating several Windows Server Failover Clusters:

  • A cluster of two servers for a SQL Server 2012 AlwaysOn Availability Group
  • A cluster of two servers for VMM Management Server
  • A cluster of two servers for the VMM Library Server

A multiserver installation for VMM can give you a great deal of flexibility and resiliency in the overall installation.

Getting ready

You will need three Windows Server Failover Clusters created for this recipe. You will need to create a Computer object in Active Directory for each of the following clustered roles:

  • SQL Server Availability Group Listener: in this example it will be SysCtrDBS-AGL
  • The name of the VMM Client Access Point; in this example, it will be VMMMS
  • The name of the File Server Client Access Point; in this example, it will be VMMLibServer

Please ensure that you have created the computer account objects for SysCtrDBS-AGL, VMMMS, and VMMLibraryServer in Active Directory and granted sufficient privileges to the associated Cluster computer accounts for these objects. Additionally, please ensure that these computer account objects are disabled in Active Directory.

How to do it…

The following diagram shows you the high-level steps involved in this recipe and the tasks required to complete this recipe:

How to do it…

The preceding steps will result in the following VMM components being installed in the following configuration:

  • The VirtualManagerDB database will be installed on a new SQL Server 2012 AlwaysOn Availability Group
  • VMM 2012 R2 Management Server will be installed on two servers with the System Center Virtual Machine Manager service being a clustered role
  • A clustered file server with the VMM Library share deployed

To learn how to install the following components, please visit the following links for Microsoft TechNet:

SQL Server

The first step is to create the SQL Server 2012 AlwaysOn Availability Group (this is a feature of SQL Server Enterprise Edition) for VMM to be installed against. It is assumed that you have installed SQL Server 2012 SP1 on both of your cluster nodes, but have not created the AlwaysOn Availability Group and the associated Listener. Now, you need to perform the following steps:

  1. On the first SQL node, for this example DEMO-SQL01, open the SQL Server Configuration Manager application, right-click on the SQL Server Service instance under SQL Server Services and click on Properties. On the AlwaysOn High Availability tab, check the Enable AlwaysOn Availability Groups checkbox. Then, restart the SQL Server service after enabling this checkbox.
    SQL Server
  2. Perform the same task on the second SQL Server node.
  3. On the first SQL node, open SQL Server Management Studio and create a database called TmpVMMDB. A database is required to create the AlwaysOn Availability Group against. Once VMM has been installed, the database can be removed.
    SQL Server
  4. Ensure the Recovery Model dropdown of the database is set to Full. Perform a full backup of the TmpVMMDB database. If you do not do this, you will not be able to create the Availability Group.
    SQL Server
  5. On the first SQL node, open SQL Server Management Studio, expand the AlwaysOn High Availability folder, right-click on Availability Groups, and select New Availability Group Wizard, as shown in the following screenshot:
    SQL Server
  6. Read the introduction screen and click on Next.
  7. Provide a name of the Availability Group; in this example, it will be SysCtrDBs. Click on Next.
    SQL Server
  8. Select the TmpVMMDB database to be added to the Availability Group. Click on Next.
  9. On the Specify Replicas page, click on Add Replica and enter the name of the other SQL node. Click on Connect.
  10. Once the server has been added, set the options as shown in the following screenshot:
    SQL Server
  11. Click on the Listener tab and select the option to Create an availability group listener. In this example, it will be called SysCtrDBs-AGL. It will listen on port 1433 and have a static IP address. Once configured, click on Next.
    SQL Server
  12. On the Select Initial Data Synchronization page, enter a file share that the account the SQL Server Agent service is running under has Full control over. Click on Next.
    SQL Server
  13. The next screen will validate the settings you have entered to ensure the Availability Group can be created. Click on Next.
  14. After the Availability Group is created, you will have a DNS entry for SysCtrDBs-AGL and under Failover Cluster Manager, you will see Role.
    SQL Server

You can then install VMM using the AlwaysOn Availability Group listener name as the name of the SQL Server.

VMM Management Server

When you install VMM, the installation process can detect if it is running on a Windows Server Failover Cluster and will install itself as a clustered role. There is very little difference in the installation process from installing VMM on a standalone server. However, it must be noted that the System Center Virtual Machine Manager service must run under a domain account and that the Distributed Key Management container must be created in Active Directory and configured for use during installation. The svc_VMMSrvc account must be a member of the Local Administrators group on the server.

As an alternative to precreating the database as we did in the previous recipe, you could make sure the Install_VMM account has sysadmin privileges on the SQL Server instance.

VMM Management Server

Installing of the first cluster node

As seen in the following screenshot, the cluster has been created; however, there are no roles on the cluster:

Installing of the first cluster node

The installation process of VMM is very similar to installing VMM on a single server; however, there are few differences. The steps for installation are as follows:

  1. When installing VMM management server role, the VMM installation will ask you if you want to make it highly available. Click on Yes.
    Installing of the first cluster node
  2. When selecting the SQL Server to use for the installation of VirtualManagerDB, you must select SQL Server AlwaysOn High Availability Group Listener.
    Installing of the first cluster node
  3. You will be prompted to enter the name of the Client Access Point for the VMM instance and the IP address you want to assign, which is VMMMS in this case.
    Installing of the first cluster node
  4. When installing VMM on a failover cluster, you will not be able to create a library share on the server.
    Installing of the first cluster node
  5. After the installation is complete, the VMMMS role can be seen in Failover Cluster Manager, as shown in the following screenshot:
    Installing of the first cluster node
  6. If you examine the VMMMS role, you can see that only one node can possibly own the role at the moment.
    Installing of the first cluster node

SQL Server tasks

Once the first VMM installation is complete, there are a number of SQL Server tasks that need to be performed:

  1. Add the SVC_VMMSrvc SQL Login to the other SQL Server node.
  2. Alter the recovery model of the VirtualManagerDB database to Full.
  3. Create a full backup of VirtualManagerDB.
  4. Add VirtualManagerDB to the AlwaysOn High Availability Group.
  5. Remove TmpVMMDB from the AlwaysOn High Availability Group.

Adding SVC_VMMSrvc SQL Login to the other SQL Server node

The SQL Server Logins that have been created by the VMM installation process must be created in every other node of the SQL Server AlwaysOn High Availability Group. Failure to complete this will result in VMM inability to access the database should it failover. This is because unlike Failover Clustering, which protects the entire SQL Server instance, SQL Server AlwaysOn High Availability Groups only protect databases.

  1. As shown in the following screenshot, the SVC_VMMSrvc Login is not present on the second SQL Server node in the AlwaysOn High Availability Group, DEMO-SQL02:
    Adding SVC_VMMSrvc SQL Login to the other SQL Server node
  2. Add the SQL Login for the SVC_VMMSrvc account by executing the following T-SQL in SQL Server Management Studio:
    CREATE LOGIN [DEMO\SVC_VMMSrvc] FROM WINDOWS
    GO

Altering the recovery model of the VirtualManagerDB database to Full

All databases that are to be included in a SQL Server AlwaysOn High Availability Group must use the Full recovery model.

To alter the recovery model, open the first SQL Server node in SQL Server Management Studio, right-click on the database, and click on Properties. In the Select a page section, click on Options and change the Recovery model to Full, as shown in the following screenshot:

Altering the recovery model of the VirtualManagerDB database to Full

Creating a full backup of VirtualManagerDB

In SQL Server Management Studio, perform a full backup of the VirtualManagerDB database.

Adding VirtualManagerDB to AlwaysOn High Availability Group

To add VirtualManagerDB to the AlwaysOn High Availability Group, perform the following steps:

  1. Open SQL Server Management Studio, navigate to AlwaysOn High Availability | SysCtrDBs (Primary), right-click on Availability Databases, and click on Add Database. This is shown in the following screenshot:
    Adding VirtualManagerDB to AlwaysOn High Availability Group
  2. Read the introduction screen and click on Next.
  3. Select VirtualManagerDB, ensure the database has "Meets requirements". If not, ensure you have changed the Recovery model option to Full and created a full backup. Click on Next.
  4. On the Select Initial Data Synchronization page, the share that was previously used will be shown. Change this share if necessary. Click on Next.
  5. You will then be prompted to connect to the second node of the AlwaysOn High Availability Group. Click on Connect. Then, click on Connect again. Click on Next.
  6. Ensure the validation checks are all passed; if not, rectify the failures. Click on Next.
  7. On the Summary page, click on Finish.

The VirtualManagerDB database will then be added to the AlwaysOn High Availability Group.

Removing TmpVMMDB from AlwaysOn High Availability Group

Now that the VirtualManagerDB database has been added to the AlwaysOn High Availability Group, the TmpVMMDB database can be removed from the SysCtrDBs AlwaysOn High Availability Group. To do this, perform the following steps:

  1. Open SQL Server Management Studio, navigate to AlwaysOn High Availability | SysCtrDBs (Primary) | Availability Databases, right-click on TmpVMMDB, and click on Remove Database from Availability Group. This is shown in the following screenshot:
    Removing TmpVMMDB from AlwaysOn High Availability Group
  2. In the Remove Database from Availability Group 'SysCtrDBs' screen, click on OK.
  3. The copies of TmpVMMDB can then be deleted from each of the SQL Servers.

Installing the second node

The SVC_VMMSrvc account must be a member of the Local Administrators group on the server. You need to perform the following steps for this:

  1. When selecting to install the VMM Management Server role, the VMM installation will ask you to add this server to the already highly available installation. Click on Yes.
    Installing the second node
  2. During the installation of VMM, there are few decisions to be made. When prompted to choose the SQL Server, all the options are grayed out as shown in the following screenshot:
    Installing the second node
  3. On the next screen, the options are grayed out as these are controlled by the cluster and the Distributed Key Management information has already been populated. However, you must enter the password for the service account as shown in the following screenshot:
    Installing the second node
  4. After the installation completes, if you investigate the VMMMS role, you can see that both nodes are now possible owners of the role.
    Installing the second node

VMM Library Server

The VMM Library Server can use a Clustered File Server that has been created as File Server for general use rather than Scale-Out File Server for application data. To do so, perform the following steps:

  1. Open Failover Cluster Manager on one of the cluster nodes that will host the VMM Library Server.
  2. Right-click on the cluster and click on Configure Role.
    VMM Library Server
  3. Click on Next.
  4. Click on File Server.
  5. Click on Next.
  6. Select File Server for general use.
  7. Click on Next.
  8. Enter the name of the Client Access Point for the File Server; in this case, VMMLibServer. Then, enter an IP address and click on Next.
  9. Select the available storage to be assigned to the File Server. Click on Next.
  10. Click on Next.
  11. Click on Finish.
  12. The VMMLibServer role can be seen in Failover Cluster Manager.
    VMM Library Server
  13. To add a share to the File Server, right-click on the VMMLibServer role and click on Add File Share.
    VMM Library Server
  14. In the File share profile, select SMB Share – Quick. Click on Next.
  15. Select the appropriate volume. Click on Next.
  16. Enter a name in the Share name field, in this case Library. Enter a description for the share, as shown in the following screenshot:
    VMM Library Server
  17. Click on Next.
  18. Uncheck the Allow caching of share checkbox. Click on Next.
  19. The minimum permissions required for a VMM Library share is for the SYSTEM account to have full access in Share Permissions and NTFS Permission. However, as users may need to contribute content to the share, ensure the appropriate users and/or security groups have the appropriate permissions. Click on Next.
  20. Click on Create. This share is ready for use by VMM as a Library Share. You must ensure that the svc_VMMAgntRA account has administrative rights on both nodes of the file server cluster.

Adding a VMM Run As account for the SVC_VMMAgntRA account

Before the Library Server can be added to the VMM, you must create a Run As Account in VMM. This determines the credentials that VMM uses to manage remote systems. Perform the following steps:

  1. Open the VMM Console on one of the VMM servers. Remember to connect to VMMMS:8100 as shown in the following screenshot:
    Adding a VMM Run As account for the SVC_VMMAgntRA account
  2. Navigate to the Settings section and click on Security. You can see the default Run As Accounts created by the VMM installation.
    Adding a VMM Run As account for the SVC_VMMAgntRA account
  3. Click on Create Run As Account on the ribbon bar, enter the details as appropriate, and click on OK.
    Adding a VMM Run As account for the SVC_VMMAgntRA account

Adding Cluster to VMM

You also need to add Cluster to VMM. For this you need to perform the following steps:

  1. Open the VMM console on one of the VMM servers. Remember to connect to VMMMS:8100 as shown in the following screenshot:
    Adding Cluster to VMM
  2. Navigate to the Fabric workspace, expand the Infrastructure option, right-click on Library Servers, and then click on Add Library Server.
    Adding Cluster to VMM
  3. Select the VMM Agent Run As account, as shown in the following screenshot, and click on Next.
    Adding Cluster to VMM
  4. Enter VMMLibServer in the Computer name field and click on Add. VMM can then see the clustered role and all the servers that form that role. Click on Next.
    Adding Cluster to VMM
  5. Select the Library share created previously and check the checkbox under Add Default Resources. Click on Next.
    Adding Cluster to VMM
  6. Review the summary and click on Add Library Servers.
  7. Once the VMM job is complete, you will see the two nodes of the File Server cluster and the Client Access Point listed in the Library Servers section, as shown in the following screenshot:
    Adding Cluster to VMM

How it works…

While installation of VMM in a highly available configuration can be time consuming, it can help reduce, if not eliminate, the number of single points of failure for the installation.

Through the use of failover clusters (including SQL Server AlwaysOn High Availability Groups), each component can be made highly available. Each role can move from one server in the cluster to another. This allows the VMM service and its required components to remain online while underlying aspects are maintained such as the Windows Server installations.

Tip

As domain user service accounts are used for all services, ensure these accounts are allowed the Log on as a service privilege.

You have been reading a chapter from
Hyper-V Network Virtualization Cookbook
Published in: Nov 2014
Publisher:
ISBN-13: 9781782177807
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime