Installing Virtual Server VM Additions on Windows Server 2008 & Windows Vista

Virtual Machine Additions are a very important component of Virtual Server 2005 (and Virtual PC 2007). Running VM Additions on a VM is not a must, but you’d better do it as soon as possible, even as the first thing to do right after finishing the installation phase of the OS itself.

Note: if for some reason, you’re using VMware products to virtualize Windows Server 2008 Server Core, you might be interested in reading my Installing VMware Tools on Windows Server 2008 Server Core Installations article.
Virtual Machine Additions adds the following enhancements to a guest operating system:

  • Improved mouse cursor tracking and control
  • Greatly improved overall performance
  • Virtual machine heartbeat generator
  • Optional time synchronization with the clock of the physical computer

You can use several methods to install the VM Additions:

  • Through the Virtual Server administrative website
  • Through VMRC Plus
  • Unattended installation
  • Through scripting

Additionally, if you’ve got Microsoft System Center Virtual Machine Manager (SCVMM) installed, you can also:

  • Install the VM Additions from the VMM console
  • Use PowerShell

Let’s see how each method is carried on:

Using VMRC Plus to Install the VM Additions

If you’ve got VMRC Plus installed you can easily install VM Additions by performing these steps:
 

  1. In the VMRC Plus console, point to the virtual machine you want to install the VM Additions on, and then double-click it to turn it on.

 

  1. Once the virtual machine has started, point to the virtual machine name, and then double-click it to remote control it.

 

  1. Log on to the virtual machine as an administrator or member of the Administrators group.

 

  1. Once the guest operating system is loaded, in the Console Manager window click Media > Install Current VM Additions.

 

  1. Inside the VM, follow the prompts and perform the installation.

 

  1. You must reboot the guest virtual machine in order for the VM Additions to function properly.

Using the Virtual Server administrative website to Install the VM Additions

To install Virtual Machine Additions through the Virtual Server administrative website please follow these steps:

  1. Open the Virtual Server Administration website.

 

  1. In the navigation pane, under Virtual Machines, point to Configure and then click the appropriate virtual machine.

 
 

  • In Status, point to the virtual machine name, and then click Turn On.

 
 
 

  • Once the virtual machine has started, point to the virtual machine name, and then click Remote Control.

 
 
 

  • Log on to the virtual machine as an administrator or member of the Administrators group.

 
 
 

  • Once the guest operating system is loaded, press the HOST KEY to release the mouse pointer, and then in the lower-left corner under Navigation, click Configure virtual_machine_name, where virtual_machine_name is the name of the VM you wish to install the VM Additions on.

 
 
 

  • In Configuration, click Virtual Machine Additions, click Install Virtual Machine Additions, and then click OK.

 
 
 

  • Under Status, point to the virtual machine name, and then click Remote Control.

 
 
 

  • Click in the Remote Control window to return to the guest operating system. The Virtual Machine Additions installation wizard will start. Proceed through the wizard.

 
 
 

  • Once the wizard is complete, you will be prompted to restart the virtual machine to complete the installation.

 

Using Unattended Installation to Install the VM Additions

To perform an unattended installation, place the Virtual Machine Additions image file (.ISO) to a location where it can be accessed by the virtual machines. Logon to the VM and in a command prompt window from within the VM type the following command:

​setup.exe -s -v"/qn [Reboot=ReallySuppress]"

Using Scripted Installation to Install the VM Additions

The script to install Virtual Machine Additions in a running guest OS is fairly straightforward, but for a good scripting guide I suggest you look at Desmond Lee’s excellent article:

Microsoft Certified Professional Magazine Online – Feature Article: Scripting Basics for Virtual Server 2005 R2, Part 2

Using the SCVMM Administrator Console to Install the VM Additions

First, it is recommended that you add the Virtual Machine Additions to your VMM Library. This will allow you to use the same ISO image for all of your virtual machines.
To add Virtual Machine Additions to your VMM Library:

  1. Copy the VMAdditions.iso file to a share in the Virtual Machine Manager library and then refresh the library server. The default location is C:’Program Files’Microsoft Virtual Server’Virtual Machine Additions.

 

  1. If you do not see the VMAdditions ISO file in Library view or when you browse for a known image file, disable any filters and manually refresh the library.

To install Virtual Machine Additions on an existing virtual machine:

  1. In Virtual Machines view, right-click the virtual machine on which you want to install Virtual Machine Additions, and then click Properties

 
 

  • In the Virtual Machine Properties dialog box, display the Hardware Configuration tab.

 
 
 

  • If there is no DVD drive, add a DVD drive to the IDE device by clicking DVD on the New menu bar to add one.

 
 
 

  • Click Known image file, click Browse to open the Select ISO dialog box, click the VMAdditions.iso file, and then click OK.

 
 
 

  • Start the virtual machine. Virtual Machine Additions will install from within the running virtual machine.

 

Using SCVMM and PowerShell to Install the VM Additions

Coming from this blog – VMM Beta 2: Installing VM Additions:
Here is a PowerShell script you can run on the VMM server that will do that. It assumes that you have an ISO called VMAdditions.iso in a library share managed by VMM. The VM Additions are installed with Virtual Server 2005 R2 SP1 in the <yourinstalldrive>’Program Files’Microsoft Virtual Server’Virtual Machine Additions folder. So you first either copy this ISO to the library for use on all VMs, or modify the script to use the copy local to the host your VM is on.
Copy the following text and save it as Install-VMAdditions.ps1:

​ # Install-VMAdditions.ps1
$vm = $args[0]
if ($vm.Status -eq ‘Running’ )
{
$vmadditions = get-iso | where { $_.Name –eq ‘VMAdditions’ }
Set-VirtualDVDDrive –VirtualDVDDrive $vm.VirtualDVDDrives[0] -Link –ISO
$vmadditions
}
else
{
write-host "The VM must be Running before you can install VM Additions."
}

To use this script:

​$vm = get-vm –Name “My VM”
C:'Scripts'Install-VMAdditions.ps1 $vm

The VM Additions installer will launch automatically inside the guest OS.
Notes:

  • The VM does not need to be running order to attach an ISO to a Virtual DVD drive, but the VM does need to be running in order to install VM Additions.
  • On the Set-VirtualDVDDrive lines, the –Link¬ parameter means: Point to the ISO inside the library instead of copying it to the host.

Reinstalling Virtual Machine Additions for use with Virtual PC

If you move a virtual machine that was created with Microsoft Virtual PC to Virtual Server, we recommend that you reinstall Virtual Machine Additions, even if it was installed in Virtual PC. This is because the version of Virtual Machine Additions included with Virtual Server has been updated.
Current VM Addition versions are:

  • VM Additions in VS 2005 R2 SP1 = 13.813
  • VM Additions in VPC 2007= 13.803

Links:
VMM Beta 2: Installing VM Additions
Microsoft Certified Professional Magazine Online | Feature Article: Scripting Basics for Virtual Server 2005 R2, Part 2