Installing Hyper-V and Deploying Windows Server 2008 as Your First Virtual Machine - Part I

Installing Hyper-V and Deploying Windows Server 2008 as Your First Virtual Machine - Part I

January 26, 2012
Introduction
Hyper-V is the next level of virtualization, with Windows Server 2008 you no longer need to deploy an application such as Virtual Server 2005 or Virtual PC or other virtualization technology in order to build your virtual machines. 
Hyper-V is one of the new roles available with Windows Server 2008 where you can install it and then start creating your virtual machines, take different snapshots for every virtual machine and much more. You can use a virtualized computing environment to improve the efficiency of your computing resources by utilizing more of your hardware resources.


In this two parts article, I will show you how to install the Hyper-V role and then in part two I will install Windows Server 2008 as a virtual machine with Hyper-V.

Hyper-V requires specific hardware. You will need the following:
  • An x64-based processor. Hyper-V will be available only in the x64-based versions of Windows Server 2008, the x64-based versions of Windows Server 2008 Standard, Windows Server 2008 Enterprise, and Windows Server 2008 Datacenter.
  • Hardware-assisted virtualization. This is available in processors that include a virtualization option; specifically, Intel VT or AMD Virtualization
  • Hardware Data Execution Protection (DEP) must be available and be enabled. Specifically, you must enable Intel XD bit (execute disable bit) or AMD NX bit (no execute bit).


Before installing Hyper-V, let me show you a table that will summaries the differences between Hyper-V and Virtual Server 2005 R2

Hyper-VVirtual Server 2005 R2
Performance / Scalability
32-bit VMsYesYes
64-bit VMsYesNo
Multi-Processor VMsYesNo
VM Memory Support64 GB per VM3.6 GB per VM
Resource ManagementYesYes
Availability
Guest to Guest FailoverYesYes
Host to Host FailoverYesYes
Host MigrationYesYes
VM SnapshotsYesYes
Management
Scriptable/ExtensibleYes, WMIYes, COM
User InterfaceMMC 3.0 InterfaceWeb Interface

Perform the following steps to install Hyper-V
  1. Click Start > Server Manager

  2.  From the left side panel inside Server Manager, click on Roles

  3.  The Roles page will open, where it shows you the number of roles you have installed on your machine, Click on Add Roles

  4. The Add Roles Wizard page will open, click on Next

  5. From the list of roles available, select Hyper-V > Click Next

  6. The Introduction to Hyper-V page will open, take a few moments to read it , and then click on Next

  7. The Create Virtual Networks page will open, You can create many virtual networks on your virtualization server to provide a variety of communications channels. For example, you can create networks to provide the following:
  • Communications between virtual machines only.
  • Communications between the virtualization server and virtual machines.
  • Communications between a virtual machine and a physical network by creating an association to a physical network adapter on the virtualization server.

    You can either select the Network Adapter that will be attached with the Virtual machines now, or you can do this later using the Virtual Network Manager , Click Next
    You use the Virtual Network Manager to add, remove, and modify the virtual networks. The Virtual Network Manager is available from Hyper-V Manager.

    As a best practice, it is recommended that you have at least two network adapters on your machine, so that one of the Network adapters is used by the host, and the other network adapter is used by the guest virtual machines



  1. On the Confirm Installation Selection page, click Install



    Installation will be initialized and once completed, you will be informed that a restart is required, click Close



  2. You will be asked if you want to restart your server now, click Yes

  3. Once you log on again to your machine, the installation will resume, and then on the installation result page, you will get notified if the installation encountered any errors or it was completed successfully > Click Close





SummaryIn part 1 of this two parts article, I showed you what are the differences between Hyper-V and Virtual Server 2005, also what are the requirement for Hyper-V, and then finally installed Hyper-V on our Windows Server 2008. In part 2 of this article, I will install Windows Server 2008 as a virtual machine using Hyper-V


Identifying Hyper-V Version

Identifying Hyper-V Version

January 26, 2012
Introduction: You installed Windows Server 2008, and you intend to Install Hyper-V role, but you are wondering which version of Hyper-V is included with your Windows Server 2008 DVD ? is it the Beta version that is included with the RTM version of Windows Server 2008 ? Or is it the RTM version of Hyper-V?

You might be in a situation also, where you have already installed Hyper-V role, but does not know which version you are running. In this article, I'm going to show you two methods to identify which hyper-V version your Windows Server has .




When Windows Server 2008 was RTM back in February 2008, Hyper-V was included in Beta version.
And then we had two release candidates, RC0 and RC1, till Hyper-V was RTM on June 26- 2008.

If you already had Hyper-V role installed , then you can identify the version you are running by :

  • Using the Command line
  • Using the Hyper-V Manager Console
Using the Command Line
Open CMD, and then type the following line and hit the Enter key
wmic datafile where name="c:\\windows\\system32\\vmms.exe" get version
and the result would look like :
If you have the RTM version of Hyper-V , the version would be 6.0.6001.18016
If you have Release Candidate 1, the version would be 6.0.6001.18010
If you have Release Candidate 0, the version would be 6.0.6001.18004
and it would be 6.0.6001.17101 if you have the beta version of Hyper-V that was included with the RTM version of Windows Server 2008
Using Hyper-V Manager Console
The second method is by using the Hyper-V Manager console. Open Hyper-V Manager Console, click on Help > About Hyper-V Manager ...
If you have the RTM version of Hyper-V , the version would be 6.0.6001.18016
If you have Release Candidate 1, the version would be 6.0.6001.18010
If you have Release Candidate 0, the version would be 6.0.6001.18004
Finally, if you have the Beta version of Hyper-V that was included with the RTM version 
of Windows Server 2008, then the version would be 6.0.6001.17101
But what if you have installed Windows Server 2008 and intend to install Hyper-V role 
( you have not installed Hyper-V yet ), and you are wondering which Hyper-V version 
your Windows Server 2008 has ! Is it the Beta version that was included with Windows
 Server 2008 that was RTM back in February-2008, or is it the RTM version of 
Hyper-V ( Hyper-V RTM might be slipstreamed with Windows Server 2008 ) ? To 
identify the version of Hyper-V before it is being installed on your machine, then follow the
below steps:
Open Server Manager, expand the Diagnostic node and then click on Device Manager
Expand the System devices node, and select one of the Virtual Machine (vmBus) devices,
 open its Properties
click on the Driver tab, and check the driver version.
If you have the RTM version of Hyper-V , the version would be 6.0.6001.18016
If you have Release Candidate 1, the version would be 6.0.6001.18010
If you have Release Candidate 0, the version would be 6.0.6001.18004
and it would be 6.0.6001.17101 if you have the Beta version of Hyper-V that was included
 with the RTM version of Windows Server 2008.

Summary
Either you have installed the Hyper-V role or not yet, you can identify which version 
of Hyper-V your Windows Server 2008 has. This can be done either by using the command
line, the Hyper-V Manager Console, or by checking the driver version of one of the
 vmBus devices.
Introducing Microsoft Hyper-V Server 2008 - Part 2 : Configuration

Introducing Microsoft Hyper-V Server 2008 - Part 2 : Configuration

January 26, 2012

Introduction
In part 1 of this article, I installed Microsoft Hyper-V Server 2008. Today I'm going to configure Hyper-V Server 2008 by using the Hyper-V ConfigurationWindow.


As shown in part 1 of this article, the desktop of the Hyper-V server contains only two windows; the Command Line window and the Hyper-V Configuration window. If by mistake you closed any of these windows, you can easily re-open anyone of these windows by following the below steps:
Opening the Command Line window
  1. Click CTRL+ALT+DEL > click on Start Task Manager
  2. Click on New Task...
  3. Type cmd > click Enter or OK


Opening the Hyper-V configuration window
  1. In the command line window, type hvconfig and then click Enter


Now lets start configuring our Hyper-V Server. The Hyper-V Configuration window has a list of configuration that you can go through any of them by typing the number of that item and clicking Enter, you are not obliged to go through them in sequence ( ex. from option 1 download to option 13) . But some options can not be completed, before configuring an option that it depends on. For example, you can not join a domain ( option 1 ) or download updates (option 6)  if you have not configured your network settings first ( option 3 ).  That's why I will configure the options in the way I prefer. 
The following configurations are available with the Hyper-V configuration window


Computer Name
  1. Type 2 and click Enter to change the computer name.
  2. Type the new computer name and click Enter

  3. You will be prompted with The computer needs to be restarted in order to complete the operation. The command completed successfully. Click OK

  4. You will be prompted with You must restart your computer to apply these changes. Restart now? , click Yes

  5. After the machine reboots and you logon, you will see the new computer name.



Network Settings
Hyper-V Server network settings can be assigned by a DHCP Server or an IP Address can be assigned manually.
  1. Type 3 and click Enter to configure the Hyper-V Server network settings. 
  2. The Network cards that are attached to your machine will be listed

     
  3. Type the Index# of the adapter you want to configure and click Enter. I only have one network adapter in my server, so I will type 
  4. You will be presented with the current configuration for the network adapter you selected.

     
  5. Type 1 and click Enter to configure the IP address for the selected network adapter
  • To set the network card to receive its IP address from a DHCP Server
  1. Type D and click Enter
  • To set a static IP address
  1. Type S and click Enter 
  2. Type the IP address then click Enter 
  3. Type the subnet mask then click Enter, the default subnet mask is 255.255.255.0 , so you can leave this entry blank and just click Enter 
  4. Type the default gateway then click Enter

  • To configure DNS Server settings for the selected network adapter
  1. Type 2 then click Enter 
  2. Type the IP address of the DNS server then click Enter

     
  3. Click OK on the pop up message box : Preferred DNS server set

     
  4. If you have an alternate DNS server, then type its IP address then click Enter. If you do not have an alternate DNS Server, then keep this entry blank and click Enter 
  5. If in the previous step you had configured an Alternate DNS Server, then click OK on the pop up message box : Alternate DNS server set 
  • To Clear DNS Server Settings, follow these steps:
  1. In the Network Adapter Settings option, type 3 then click OK 
  2. Click OK when the pop up message DNS servers removed. DNS servers will be automatically obtained from network is displayed


Add Local Administrator
This option adds a user as a local administrator in the server itself. This option does not create a new user. If your server is on a workgroup and you want to create a new user on the server, then you will need to use the command : Net user username /add

If the server is joined to a domain, then you can set a domain user as a local administrator on this server.
To add a local administrator, follow these steps :
  1. Type 4 and click Enter
  2. Type the username and click Enter, if you the server is joined to a domain, then the username would be domain\username , example : elmajdal\tarek. If the server is in a workgroup, then type the username only as shown in the below image

  3. When prompted, type a password for the user and click Enter
  4. When prompted, type the password a second time and click Enter

  5. Click OK on the confirmation message box User added to local Administrators group. Username.



Domain/Workgroup
By default, Hyper-V Server is joined to the workgroup : WORKGROUP, you can either keep it in the same workgroup, joined it to another workgroup or join it to a domain. In my case, I will keep it in its default workgroup.
If you want to join it to another workgroup, do the following :
  1. Type 1 and click Enter
  2. Type W and click Enter
  3. Type the name of the workgroup you want to join your server to and click Enter

  4. Click OK on the pop up message Welcome to the workgroup: NEW WORKGROUP NAME

To join the server to a domain, do the following :
  1. Type 1 and click Enter
  2. Type D and click Enter
  3. Type the domain name ( ex. ELMAJDAL.NET ) and click Enter
  4. Type the domain username in the following format: domain\user ( ex. ELMAJDAL\TAREK), make sure that this user has the needed permissions to join this server to the domain ( ex. domain admin )

  5. When prompted, type a password for the user and click Enter

  6. You will receive a pop up message You must restart your computer to apply these changes. Restart now? , Click Yes and the server will be restarted


Remote Desktop
  1. Type 7 and click Enter.
  2. Here you have a choice to either selection option 1 or option 2. Option 1 is to allow only clients running remote desktop with Network Level Authentication ( XP SP3, Vista SP1 & Windows Server 2008 ), whereas option 2 to allow clients running any version of remote desktop.

  3. Once you made you selection and clicked on Enter, you will be prompted with a pop up message showing your selection. Click OK


  4. You will notice that the status beside 7) Remote Desktop inside the Hyper-V Configuration window is now displaying as Enabled ( your selection ), where your selection is replaced either by less secure (option 1) or more secure clients only (option 2).


Date and Time
  1. Type 9 and click Enter to configure or modify the Hyper-V Server Date and Time options. 
  2. The Date and Time applet will open, configure the desired settings and then click on OK



Regional and Language Options
  1. Type 8 and click Enter to configure or modify the Hyper-V Server Regional and Language options. 
  2. The Regional and Language Options applet will open, configure the desired settings and then click on OK



Set Automatic Windows UpdateThe current Update settings are displayed in the default Hyper-V Configuration window.

To set updates to automatic
  1. Type 5 and click Enter.
  2. Type A and click Enter 

  3. You will be prompted with Windows Update set to Automatic. System will check for and install updates every day at 3:00AM
  4. Click OK

  5. You will notice that the Windows Updates Settings status has changed to Automatic


Download and Install Updates

The current Update Status is displayed in the default Hyper-V Configuration window.
  1. Type and click Enter to search for updates. Searching for updates will start and if any updates are available, they will be listed.

  2. If there was no updates to download, then just click on any key to exit from the above window, else type Y and click Enter, this will download the updates and then they will be installed.

Log Off User
  1. Type 10 and click Enter
  2. You will be prompted with Are you sure you want to log off?
  3. Click Yes


Restart Server
  1. Type 11 and click Enter
  2. You will be prompted with Are you sure you want to restart?
  3. Click Yes


Shut Down Server
  1. Type 12 and click Enter
  2. You will be prompted with Are you sure you want to shut down?
  3. Click Yes


Exit to Command Line
  1. Type 13 and click Enter to exit to the Command Line.

SummaryIn part two of the article Introducing Microsoft Hyper-V Server 2008, I configured Hyper-V Server so that it is set on the network. In the next and last part of this article, part three,  I will show you how to connect to the server remotely so that you can start creating your virtual machines.