Thursday, May 8, 2014

Configuring Converged networking for Windows Server 2012 or Windows Server 2012 R2 by System Center Virtual Machine Manager 2012 R2

Administrators can configure converged networking by performing PowerShell in Windows Server 2012 or Windows Server 2012 R2. In System Center Virtual Machine Manager (SCVMM) 2012 R2, administrators can configure converged networking from virtual machine manager console. Before configuring converged networking for Hyper-V hosts, administrators need to define "Logical Network", "Port Profiles", "Logical Switches" and so on in SCVMM. After configuring all related components in SCVMM, administrators can assign these settings to Hyper-V hosts.

Goals
  • Configuring NIC teaming for the Hyper-V host
  • Creating virtual NICs for the Hyper-V host
  • Assigning VLAN for virtual NICs
  • Creating Logical Networks for Management, Cluster and Live Migration
  • Creating VM Networks for Management, Cluster and Live Migration

In this lab, we will configure the following items in SCVMM 2012 R2.

1. Define "Logical Networks" and "VM Networks" for a Hyper-V host because the Hyper-V host use virtual NICs to connect a Hyper-V switch.
2. Create "Port Profiles" and "Port Classifications" for the NICs of Hyper-V host.
3. Create a "Logical switch" with uplink ports and virtual ports settings.

Lab environment
  • 1 physical server named HV02 with 4 x Intel 1Gb NICs
  • All NICs connected a single physical switch
  • HV02 is installed Windows Server 2012 R2 Datacenter
  • HV02 is installed Hyper-V role
  • HV02 is a member server of test.tls1.lab domain
  • HV02 connected to 172.16.0.0/16 which is a management network

To install SCVMM 2012 R2 and configuring the service accounts, please read Installing System Center Virtual Machine Manager 2012 R2 in Windows Server 2012 R2

Lab
Logical Networks and VM Networks
First of all, we need to define logical networks and VM networks for Hyper-V environment. A logical network is a physical network which Hyper-V hosts connected. VM Networks is a virtual network for virtual machines or virtual NICs to route the traffic.

1. On VMM01, log in as VMMAdmin.
2. Launch "Virtual Machine Manager Console".
3. Log in as "Use current Microsoft Windows session identity" option on Virtual Machine Manager.


4. On "Virtual Machine Manager" window, select "Fabric".


5. Next to "Fabric" pane, select "Logical Networks".


6. On the menu, click "Create > Create Logical Network".


7. On "Create Logical Network Wizard" window, next to "Name", enter "Dev-Lan".
8. Next to "Select the option which describes this logical network", select "One connected network".
9. Check "Create a VM network with the same name to allow virtual machines to access this logical network directly" to create a VM network for virtual NICs connect it.


10. Click "Next".
11. On "Network Site" window, click "Add".
12. Check :All Hosts".
13. Click "Insert row".
14. Next to "VLAN", enter "0".
15. Next to "IP subnet", enter "172.16.0.0/16".


16. Click "Next".
17. On "Summary" window, click "Finish".


A logical Network and a VM network have been created.



18. Repeat step 6 - 17 to create Dev-Cluster and Dev-LM and then assign the following VLANs and network.

Dev-Cluster: 192.168.101.0/24 - VLAN 101
Dev-LM: 192.168.102.0/24 - VLAN 102





Administrators can select "Create IP Pool" for logical networks. Using "Create IP Pool", virtual machines can receive IP, Gateway, DNS and WINS from IP pools which are related to the logical network. This function is similar DHCP.



Port Profiles and Port Classifications
There are 2 types of Port Profiles in SCVMM. 1 for virtual machines and another one for Hyper-V hosts. By default, some port profiles come with SCVMM 2012 R2. Now, we will create a port profile for the Hyper-V host.

1. Still in "Virtual Machine Manager Console", select "Port Profiles".
2. On the menu, click "Create > Create > Hyper-V Port Profile".


3. On "Create Hyper-V Port Profile" window, next to name, enter "1Gb pNIC Team".
4. Select "Uplink port profile".
5. Next to "Load balancing algorithm", select "Dynamic".
6. Next to "Teaming mode", select "Switch Independent".


Uplink port profile is applied to physical NICs and Virtual network adapter port profile is applied to virtual NICs.

Remark: "Dynamic" algorithm is a new feature on Windows Server 2012 R2. It doesn't support previous Windows.

7. Click "Next".
8. On "Network configuration" window, check all network sites.


9. Click "Next".
10. On "Summary" window, click "Finish".


11. On the menu, click "Create > Create > Hyper-V Port Profile".
12. On "Create Hyper-V Port Profile" window, next to name, enter "Dev Host Management".
13. Select "Virtual network adapter port profile".


14. Click "Next".
15. On "Offload Settings", check "Enable virtual machine queue".


16. Click "Next".
17. On "Security Settings" window, clear all check boxes.


18. Click "Next".
19. On "Bandwidth Settings" window, next to "Minimum bandwidth weight", enter "5".


20. Click "Next".
21. On "Summary" window, click "Finish".


22. Repeat step 11 - 21 to create a Virtual network adapter port profile named "Dev Cluster".


After that, administrators can create "Port Classifications" to define the port usage.

23. Select "Port Classifications".
24. On the menu, click "Create > Create > Port Classification".


25. On "Create Port Classification Wizard" window, next to "Name", enter "Dev Host Management".


26. Click "OK".
27. Repeat step 24 - 26 to create "Dev Cluster".


Logical Switches
Now, we will create a Hyper-V switch for the Hyper -V host.

1. Still in "Virtual Machine Manager Console", select "Logical Switches".
2. On the menu, click "Create > Create > Logical Switch".


3. On "Create Logical Switch Wizard" window, click "Next".


Under "Before you create a logical switch", Microsoft listed some points for administrators before creating a logical switch.

1. Create your logical networks and define the network sites that compose the logical network.

We created "Dev-Lan", "Dev-Cluster" and "Dev-LM" logical networks.

2. If you are using Hyper-V extensible virtual switch extensions, install the providers for VMM and add their virtual switch extension managers.

By default, there are some extensions for logical switches. administrators can select to use it or not in a logical switch. We'll select it later.

3. If you are not using a forwarding extension, create native port profiles for uplink adapters that will be used to define the connectivity and behavior of the physical adapters that are connected to the logical switch.

We created 1 uplink port profile named "1Gb pNIC Team" and 2 Virtual network adapter port profiles named "Dev Host Management" and "Dev Cluster".

4. Create native port profiles for virtual adapters that will be used to define the port settings for the native Hyper-V virtual switch.

Same as point 3.

2. On "General" window, next to "Name", enter "HKG-Switch01".


3. Click "Next".
4. On "Extensions" window, leave "Microsoft Windows Filtering Platform", click "Next".


5. On "Uplink" window, next to "Uplink mode", select "Team".
6. Next to "Uplink port profiles", click "Add".
7. On "Select a port profile" window, select "1Gb pNIC Team".


8. Click "OK".
9. On "Uplink" window, click "Next".


10. On "Virtual Port" window, click "Add".


11. On "Configure the virtual port" window, click "Browse".


12. On "Select a Port Profile Classification", select "Dev Host Management".


13. Click "OK".
14. On "Configure the virtual port" window, check "Include a virtual network adapter port profile in this virtual port".
15. Next to "Native virtual network adapter port profile", select "Dev Host Management".


16. Click "OK".
17. Repeat step 10 - 16 to add "Dev Cluster" and "Live migration workload".


18. On "Uplink" window, click "Next".
19. On "Summary" window, click "Finish".



Now, we can assign the logical switch to HV02.

Hyper-V Host configuration
1. Still in "Virtual Machine Manager Console", select "All Hosts".
2. Select "HV02.test.tls1.lab" and then click "Properties".


3. On "hv02.test.tls1.lab Properties" window, select "Virtual Switches".
4. Click "New Virtual Switch > New Logical Switch".


5. Next to "Physical adapters", click "Add" to add more physical NICs.


6. Next to "Adapter", select all Intel NICs.


7. Click "New Virtual Network Adapter" to add a virtual NIC for HV02.


8. On a virtual NIC, next to "Name", enter "Management".
9. Un-check "This virtual network adapter inherits settings from the physical management adapter".
10. Next to "Connectivity", click "Browse".


11. On "Select a VM Network" window, select "Dev-Lan".


12. Click "OK".
13. Next to "Classification", select "Dev Host Management".


14. Next to "MAC address", make sure "Dynamic" is selected.


15. Select "HKG-Switch01", click "New Virtual Network Adapter" to create "Cluster" and "LM" virtual NICS.



16. Click "OK".
17. On pop-up window, click "OK".


Remark: After configuring NIC teaming for HV02, the "Logical network connectivity" settings were automatically configured to physical NICs of HV02.


As a result, the converged network was configured on HV02 by SCVMM 2012 R2.


More information

This posting is provided “AS IS” with no warranties, and confers no rights!

No comments:

Post a Comment