Category Archives: Quick Tips

Enhanced Session Mode

Enhanced Session Mode (ESM) enables an improved user experience when managing Hyper-V virtual machines. With ESM enabled, an administrator can share devices and the clipboard with a guest VM.  It is also possible to modify the resolution of the VMConnect console.  In addition to improved graphics performance, ESM improves the security of the connection to the guest VM.

The following local resources can be shared via ESM

  • Audio
  • Printers
  • Clipboard (Copy/Paste)
  • USB devices
  • Logical Drives
  • PnP devices
  • Smart Cards

Requirements for Enhanced Session Mode

  • Guest OS supports RDP
    • Client OS: Windows 8.1 Pro/Enterprise
    • Server OS: 2012R2
  • Remote Desktop Service is running in the guest
    • ‘Allow remote connections to this computer’ or NAP do not need to be enabled
  • Hyper-V host must have ‘Enhanced session mode’ enabled in the Hyper-V server settings
  • User must be a member of the local ‘Administrators’ group or a member of the ‘Remote Desktop Users’ group in the guest VM

Enable Enhanced Session Mode

  • In Hyper-V Manager, right click on the host and select ‘ Hyper-V Settings…’.
  • Select the ‘Enhanced Session Mode Policy’ Task Item, then select the check-box labeled ‘Allow enhanced session mode’.
  • If you would like the ESM to be active by default when available select ‘Enhanced Session Mode’ user settings and select the check-box labeled ‘Use enhanced session mode’.
    ESM

PowerShell Commands

Set-VMHost -EnableEnhancedSessionMode $True

Toggle ESM per VMConnect Instance

Leverage the taskbar icon to enable/disable enhanced session mode for a particular VM connect session.
ESM-VMConnect2

Additional Resources

TechNet – Use local resources on Hyper-V virtual machine with VMConnect
WindowsItPro – Enhanced Session Mode in Windows Server 2012 R2

Hyper-V Unknown Devices

Hyper-V Unknown Devices

In Windows Server 2012 R2 Hyper-V, Microsoft made a couple of enhancements within virtual machines that provide new capabilities for guests that support the associated features.  These features include Automatic Virtual Machine Activation, and Enhanced Session Mode.

 Automatic Virtual Machine Activation

Automatic Virtual Machine Activation provides customers with an easier way to manage VM guest license activations when their VMs are running on a Datacenter Edition of Windows server 2012 R2.  Because Datacenter Edition provides unlimited virtual machine licenses for Windows Server VMs, VMs running Windows Server 2012 R2 on 2012 R2 hosts will be automatically activated, reducing the effort of administrators for purposes of license activation.

 Enhanced Session Mode

Enhanced Session Mode provides administrators with enriched tools for interacting with virtual machines through the console connection.  In previous versions of Hyper-V, administrators could connect to VMs using Virtual Machine Connection, which had limited functionality, particularly if you wanted to copy and paste something into your VM.  Now with 2012 R2 Hyper-V, guests with supported operating systems provide true RDP capabilities, but via the VMBus, which means these connections can be made without a network connection.

Below is a Device Manager windows for a Windows Server 2008 guest running in a Windows Server 2012 R2 Hyper-V VM. Note the two Unknown devices:

Device manager showing two unknown devices in a 2008R2 Hyper-V guest

Device manager showing two unknown devices in a 2008R2 Hyper-V guest

Taking a look at the Properties of each device and specifically look at the Hardware IDs, we can see one that starts with 3375. This is the new virtual device used for Automatic Virtual Machine Activation.

Hardware ID for Automatic Activation in Hyper-V 2012R2

Hardware ID for Automatic Activation in Hyper-V 2012R2

Looking at the Properties and Hardware IDs on the other device, we see that it starts with f8e6. This is the new virtual device used for Enhanced Session Mode.

Hardware ID for Enhanced Session Mode in a 2012R2 Hyper-V Guest

Hardware ID for Enhanced Session Mode in a 2012R2 Hyper-V Guest

Automatic Virtual Machine Activation and the new Enhanced Session Mode features are new to Windows Server 2012 R2 and later, thus earlier guests (Windows Server 2012 and earlier) don’t know what these devices are and show these as unknown devices.  These unknown devices can be safely ignored in the older operating systems.

Additional Resources

TechNet: Virtual Machine Connection – Enhanced Session Mode Overview
MSDN Code: Hyper-V enhanced session mode sample
TechNet: Automatic Virtual Machine Activation