Part 1 – Prepare Dual Boot Windows Server 2012 using Native Boot to VHD

Part 2 – Install & Configure Hyper-V

Part 3 – Create the Active Directory Virtual Machine

Part 4 – Create the Storage and Cluster Virtual Machines

Part 5 – Checkpoints (No longer called Snapshots!!)

 

Objectives

In this series of exercises, you will explore the following:

•Install Hyper-V

•Modify Hyper-V Settings.

•Create Virtual Machines and Differencing Disks.

•Modify Settings for Virtual Machines.

•Create Domain

•Get connectivity working between guest machines

•Add computer to domain

****Warning, this post may change several times as the server changes from Preview to Beta to G.A., any major changes will be highlighted in a new color as new corrections are required.****

 

Prerequisites

◦ Computer running Windows 7, 8, or Windows Server 2008 R2 or later

◦ At least 60 GB of free disk space (75 GB preferred)

◦ 4gb memory (8gb preferred)

◦ x64 compatible processor with hardware assisted virtualization (Intel VT or AMD-V technology)

◦ At least one disk without encryption technology (Bitlocker or 3rd party)

◦ Disk Drives Configure as Basic Disks (Not Dynamic)

NOTE: Before beginning this lab, please confirm that your computer is configured with hardware virtualization technology and hardware memory protection BOTH ENABLED. To confirm these settings, you may need to shut down and reboot your computer into BIOS Setup.

 

Part 1 – Prepare Dual Boot Windows Server 2012 using Native Boot to VHD

1. Log on to your computer as an Administrator account

2. Download and extract the Windows Server 2012 R2 Preview.

Open Windows Explorer.

Create the following Directory Structure at the root of Drive C: or D: [use the one with the most space or the fastest disk]

<drive letter>:\Images

<drive letter>:\Images\Base

3. Download, extract and copy the file named AutoBootVHD8.cmd to the Images folder.

4. Make a copy of the Server2012 VHD into the \Images folder and \Images\Base folder then rename both to Server2012EVAL.vhd {You may need to turn on viewing file extensions to properly change the name.}

5. The Images\Server2012EVAL.VHD file will be used for the Boot2VHD. The file under the Base directory will be used later as a Parent disk for VMs. Either right click and Mount or go into Disk Management (in Computer Management) and attach only the \Images VHD, note the new drive letter that is provided. Do not confuse this with the copy placed in the Images\Base folder, it will be used later.

6. Open elevated Command Prompt by going to the Start screen, type cmd, right-click cmd, select Run as Administrator

7. Change to the drive you extracted files to by typing the drive letter followed by a colon (eg. D: }

8. Change to the images folder: CD images <enter>

9. Now we will execute the command to automatically setup the dual boot configuration: Important! Before you commit, first make sure a copy of Server2012EVAL.VHD resides in Images\Base {this will be used for VM guests later.}

10. Enter in the following command:

AutoBootVHD8.cmd <drive>:\images\Server2012EVAL.VHD –upgrade <enter>

11. When prompted, enter the DriveLetter of the new Drive that was created (eg: E)

12. Check for errors, Alert lab monitors if any errors

13. Optional: When finished, type msconfig <ENTER> - click Boot tab = to see the new boot option. Click your original operating system (eg: Windows 7 or 8) click Set As Default, Click OK, Click Restart. You will be presented with the choice to boot to Server 2012. (Note when you finish with the labs and no longer wish to continue, you can delete the VHD files and the entry in this Boot tab to clean up the laptop.) An Automatic second reboot may occur after installing drivers.

14. The Administrator account is already preloaded.

15. Type in the password {R2Preview!}. Server Manager should launch momentarily.

16. Click on Local Server. Click on the server name and select to change it. Name the server HYPERV01. Leave the workgroup name as is. Click OK to Reboot.

17. Login {password is R2Preview!} and click on Local Server again. If you are connected to an Ethernet network, change the IP address to 192.168.1.9 subnet mask 255.255.255.0.

 

Part 2 – Install & Configure Hyper-V

1. In Server Manager click “Add roles and features”

2. Before You Begin: Next

3. Installation Type: “Roll-based feature-based installation”; click Next

4. Server Selection: You should see HYPERV01 listed. Click Next

5. Server Roles: Look to see if the checkbox next to Hyper-V is selected, in the popup, click Add Features, click Next.

6. Features; Enable Wireless LAN Service, click Next.

7. Hyper-V – Virtual Switches, we will manually add the switch later, click Next.

8. Select “Restart the destination server automatically if required” and click Install. (Note if you do not have a network adapter listed that means you need to install a NIC driver possibly but we can do that later)

9. Migration screen click Next (we will enable this later)

10. Default Stores, click Next

11. Confirmation: Turn on checkbox to “Restart destination server automatically if required”, in the popup, click Yes to restart automatically, then click Install.

12. After Reboots, Login to server {password = R2Preview!}

13. Click Close on Installation Progress Page (may take a min or two for the box to come up}

14. Open Hyper-V Manager. {Go to the Start screen, type in Hyper-V Manager, right click, Pin to Taskbar} Click on Hyper-V Manager.

15. Click on your server name in the left pane

16. In Actions Pane, click Hyper-V Settings.

17. In left Pane click Virtual Hard Disks enter D:\images\Hyper-V [substitute your drive letter]

18. In left Pane click Virtual Machines enter D:\images\Hyper-V and click OK [substitute your drive letter]. Click on OK.

19. In the Actions Pane, click Virtual Switch Manager.

20. In the Create virtual switch pane, click Internal and then click Create Virtual Switch.

21. Enter IT Camp Lab for the Name and click OK.

22. Create one more virtual switch with following information:

Type: Internal

Name: IT Camp Heartbeat {This switch will be used later for the Cluster lab}

23. Later, you will want to come back in here to create an External network that will be linked to your physical NIC. But, let’s not do that now.

 

Part 3 – Create the Active Directory Virtual Machine

1. If not already logged in, login to Server as Administrator account.

2. Open Hyper-V Manager. Click the Server Name in the left pane

3. In Actions Pane, Click New ->Virtual Machine

4. Before You Begin screen: Click Next

5. Specify Name Type: DC Click Next

6. Check Store the virtual machine in a different location option and click Next. Select Generation 1. Click Next.

7. Assign Memory, if your machine has more than 8GBs of RAM, bump up the RAM to 1024[Optional: Turn on checkbox Use Dynamic Memory for this virtual machine] Click Next

8. Configure Networking, Set Connection to IT Camp Lab click Next

9. For Connect Virtual Hard Disk setting, select Attach a virtual hard disk later and click Finish

10. In Actions Pane, click New -> Hard Disk

11. Before You Begin screen, click Next.

12. Choose Disk Format: VHD

13. Choose Disk Type: Differencing

14. Specify Name and Location:

Name: DC.vhd

Location: D:\Images\Hyper-V\DC

Select the parent disk: D:\Images\Base\Server2012EVAL.vhd, click Finish.

15. Right Click DC and choose Settings.

16. Click IDE Controller 0 and click Add.

17. Click Browse and navigate directory structure to D:\Images\Hyper-V\DC\DC.vhd and click Open, click OK.

18. Start DC. {Right-Click DC – Select Start}

19. Right click the VM and select Open Console. Issue a CTRL+ALT+END.

20. When Server has finalized configuring devices, log in to the server {Password is still R2Preview!}

21. Go to the Start Screen – Type Network – Click Settings – Click Network and Sharing Center.

22. Click Change Adapter Settings (Left Pane)

23. Right Click Ethernet – Select Properties; Click TCP/IP v4 – Select properties; Use the following IP Address:

IP Address: 192.168.1.10

Subnet Mask: 255.255.255.0

Default Gateway: <Leave Blank>

Preferred DNS: 127.0.0.1

24. Click OK, click Close, then close Network Connections, close Network and Sharing Center.

25. Start Screen, Right-Click “This PC”, Select Properties, click Change Settings, click Change; type DC in the computer name field, click OK, click OK, click Close, click Restart Now.

26. Login to server (CTRL-ALT-End: R2Preview!)

27. Go to the Start Screen, type in Powershell. Right click and run Powershell as Administrator.

28. Enter in the following command: Add-windowsfeature Ad-Domain-Services <Enter>

Important! Once installation has begun minimize the DC console and begin building the Storage and Cluster Virtual Machines by following the next Part of the Lab guide, checking back on the AD machine from time to time to see if it is ready for the    next step of creating the domain.

29. The next step is to create the forest and Promote to Domain Controller. At the PowerShell prompt enter the following commands:

Install-ADDSForest –domainname "corp.contoso.loc" <Enter>

Ok to use different domain name if you like

Enter password R2Preview! <Enter>

Re-enter password R2Preview! <Enter>

A <ENTER> (for – Yes To All)

Log back into server with the R2Preview! password – You are now logged into the domain!

 

Part 4 - Create the Storage and Cluster Virtual Machines

1. Log on to Server as Administrator account.

2. Open Hyper-V Manager. Click the Server Name in the left pane

3. In Actions Pane, Click New ->Virtual Machine

4. Before You Begin screen, click Next

5. Specify Name type Storage

6. Check Store the virtual machine in a different location option, select <drive letter>:\Images\Hyper-V\Storage and click Next. Select Generation 1. Click Next.

7. Assign Memory, again more memory the better but only when hardware allows [Optional: Turn on checkbox Use Dynamic Memory for this virtual machine] Click Next

8. Configure Networking, Set Connection to IT Camp Lab click Next

9. For Connect Virtual Hard Disk setting, select Attach a virtual hard disk later and click Finish

10. In Actions Pane, click New -> Hard Disk

11. Before You Begin screen, click Next.

12. Choose Disk Format: VHD

13. Choose Disk Type: Differencing

14. Specify Name and Location:

Name: Storage.vhd

Location: D:\Images\Hyper-V\Storage

Select the parent disk: D:\Images\Base\Server2012EVAL.vhd click Finish.

15. Right Click the Storage Virtual Machine and choose Settings.

16. Click IDE Controller 0 and click Add.

17. Click Browse and navigate directory structure to <drive letter>:\Images\Hyper-V\Storage\Storage.vhd and click Open, click OK.

18. Start Storage. {Right-Click Storage – Select Start} Open the Console.

21. Use R2Preview! as the password – Click Finish

22. Configure IP with the following settings by going to the Start screen, type Network, click Settings, click Network and Sharing Center, click Change Adapter Settings (Left Pane)

23. Right Click Ethernet – Select Properties, click TCP/IP v4 – Select properties; Use the following:

IP Address: 192.168.1.11

Subnet Mask: 255.255.255.0

Default Gateway: <Leave Blank>

Preferred DNS = 192.168.1.10

24. Change Computer Name to Storage and join corp.contoso.loc domain by going to the Start screen, type in Computer, Right-Click Computer, select Properties; click Change settings, click change, type Storage under Computer Name, Select Member of Domain, type corp.contoso.loc under Domain, click OK. In the popup use Adminstrator and R2Preview! for the credentials, click OK on the welcome dialog; click OK on the Restart dialog, click close on system properties.

25. Click Restart Now.

26. Click the left arrow and select “Other User”; Type corp\administrator for username and P@ssword for the password then press <Enter>

27. You are now logged into the domain.

Important! Repeat the steps in this part of the lab to create Cluster1 and Cluster2 machines in the same manner:

Name and Disk: Cluster1.vhd Location: D:\Images\Hyper-V\Cluster1 IP: 192.168.1.21

Name and Disk: Cluster2.vhd Location: D:\Images\Hyper-V\Cluster2 IP: 192.168.1.22

 

Part 5 – Checkpoints

1) In Hyper-V Manager, highlight all VMs (DC, Storage, Cluster1, and Cluster2). (Note: You can select multiple VMs by holding down the CTRL key while selecting VMs.)

2) Right Click and select Checkpoint. Provide a proper name for this point in time, and then you are done!

End of Lab 1 Guide

 

Stay Tuned for the Follow-Up Guides soon!

Lab Guide 2 – Windows 2012 R2 Preview - Storage

Lab Guide 3 – Windows 2012 R2 Preview - Continuously Available File Shares

Lab Guide 4 – Windows 2012 R2 Hyper-V Over SMB

Lab Guide 5 - Windows 2012 R2 Enabling Hyper-V Replica

Lab Guide 6 - Windows 2012 R2 Shared Nothing Live Migration

 

More Information

Windows Server 2012 Product Download

http://aka.ms/ws2012r2tplg

Microsoft Virtual Academy

http://aka.ms/tpva

Windows Server 2012 Virtual Labs

http://technet.microsoft.com/en-us/windowsserver/hh968267.aspx

Windows Azure 90-Day Free Trial Page

http://aka.ms/mshosting