2 out of 15 rated this helpful - Rate this topic

Manage Hyper-V Server 2012 Remotely

Published: September 4, 2012

Applies To: Hyper-V Server 2012

This topic explains the various methods available for managing a Hyper-V Server. You can manage the server in the following ways:

  • Locally and remotely using Windows PowerShell

  • Remotely using Server Manager

  • Remotely using an MMC snap-in

  • Remotely with Remote Desktop Services

 

Task Description

1.1 Manage with Windows PowerShell

You can manage Hyper-V servers using Windows PowerShell either locally or remotely.

1.2 Manage with Server Manager

By running Server Manager on a remote computer, you can connect to a Hyper-V server.

1.3 Manage with Microsoft Management Console

By using a Microsoft Management Console (MMC) snap-in, you can connect to a Hyper-V Server.

1.4 Manage with Remote Desktop Services

By using another computer running Windows, you can use Remote Desktop Services to run scripts and tools on a Hyper-V Server.

There are some important limitations and tips to keep in mind when you work with a Hyper-V Server:

  • If you close all command prompt windows and want to open a new Command Prompt window, press CTRL+ALT+DELETE, click Start Task Manager, click More Details, click File, click Run, and then type cmd.exe. Alternatively, you can log off and log back on.

  • If you close all Windows PowerShell windows, you can open a new one by running PowerShell at a command prompt.

  • Any command or tool that attempts to start Windows Explorer will not work. For example, start . used from a command prompt will not work.

  • There is no support for HTML rendering or HTML help in Server Core mode.

  • There are no notifications for activation, new updates, or password expiration because these notifications require the Windows Explorer shell, which is not present.

  • If you need to write a script for managing a Hyper-V Server that requires the secure inclusion of an administrative password, see How Can I Mask Passwords Using an InputBox?.

  • Hyper-V Server supports Windows Installer in quiet mode so that you can install tools and utilities from Windows Installer files.

  • When installing Windows Installer packages on Hyper-V Server mode, use the /qb option to display the basic user interface.

  • To change the time zone, run Set-Date.

  • To change international settings, run control intl.cpl.

  • Control.exe will not run on its own. You must run it with either Timedate.cpl or Intl.cpl.

  • Winver.exe is not available. To obtain version information use Systeminfo.exe.

noteNote
This topic includes sample Windows PowerShell cmdlets that you can use to automate some of the procedures described. For more information, see Using Cmdlets.

You can accomplish most management tasks locally or from a remote computer by using Windows PowerShell cmdlets and scripts. To start Windows PowerShell, run powershell in a command prompt.

For more information about working with Windows PowerShell, including running it remotely, see Starting Windows PowerShell.

Server Manager is a management console in Windows Server® 2012 that helps IT professionals provision and manage both local and remote Windows-based servers from their desktops, without requiring either physical access to servers, or the need to enable Remote Desktop protocol (RDP) connections to each server. Although Server Manager is available in Windows Server 2008 R2 and Windows Server 2008, Server Manager has been completely redesigned for Windows Server 2012, to support remote, multi-server management, and help increase the number of servers an administrator can manage.

noteNote
You must use the version of Server Manager in Windows Server 2012 or that is available as part of the Remote Server Administration Tools for Windows 8 for Windows 8 download package. Older versions of Server Manager will not work.

To enable your local server to be managed by Server Manager running on a remote server, run the Windows PowerShell cmdlet Configure-SMRemoting.exe –Enable.

Many snap-ins for Microsoft Management Console (MMC) can be use remotely to manage your Hyper-V server.

  1. Start an MMC snap-in, such as Computer Management.

  2. In the left pane, right-click the top of the tree and click Connect to another computer. (In the Computer Management example, you would right-click Computer Management (Local).)

  3. In Another computer, type the computer name of the Hyper-V Server and click OK. You can now use the MMC snap-in to manage the Hyper-V server as you would any other computer running a Windows Server operating system.

  1. If the Hyper-V Server is not a member of a domain, establish alternate credentials to use to connect to the Hyper-V server by typing the following command at a command prompt on the remote computer:

    cmdkey /add:<ServerName> /user:<UserName> /pass:<password>

    Where:

    ServerName is the name of the Hyper-V server

    UserName is the name of an administrator account

    To be prompted for a password, omit the /pass option.

  2. When prompted, type the password for the user name that is specified in the previous step.

  3. If the firewall on the Hyper-V Server is not already configured to allow MMC snap-ins to connect, follow the steps in To configure Windows Firewall to allow MMC snap-in(s) to connect. Then return to this procedure.

  4. On a different computer, start an MMC snap-in, such as Computer Management.

  5. In the left pane, right-click the top of the tree and click Connect to another computer. (In the Computer Management example, you would right-click Computer Management (Local).)

  6. In Another computer, type the computer name of the Hyper-V Server and click OK. You can now use the MMC snap-in to manage the Hyper-V Server as you would any other computer running a Windows Server operating system.

  • To allow all MMC snap-ins to connect, run

    Enable-NetFirewallRule -DisplayGroup "Remote Administration"

  • To allow only specific MMC snap-ins to connect, run:

    Enable-NetFirewallRule -DisplayGroup "<rulegroup>"

    Where:

    Rulegroup is one of the values from the table below, depending on which snap-in you want to connect.

 

MMC snap-in Rule group

Event Viewer

Remote Event Log Management

Services

Remote Services Management

Shared Folders

File and Printer Sharing

Task Scheduler

  • Performance Logs and Alerts

  • File and Printer Sharing

Disk Management

Remote Volume Management

Windows Firewall with Advanced Security

Windows Firewall Remote Management

noteNote
Some MMC snap-ins do not have a corresponding rule group that allows them to connect through the firewall. However, enabling the rule groups for Event Viewer, Services, or Shared Folders will allow most other snap-ins to connect. Additionally, certain snap-ins require further configuration before they can connect through Windows Firewall:

  • Disk Management. You must first start the Virtual Disk Service (VDS) on the Hyper-V server. You must also configure the Disk Management rules appropriately on the computer that is running the MMC snap-in.

  • IP Security Monitor. You must first enable remote management of this snap-in. To do this, at a command prompt, type:

    Cscript \windows\system32\scregedit.wsf /im 1

  • Reliability and Performance. The snap-in does not require any further configuration, but when you use it to monitor a Hyper-V server, you can only monitor performance data. Reliability data is not available.

You can use Remote Desktop to manage a Hyper-V.

  1. On the Hyper-V Server, run:

    cscript C:\Windows\System32\Scregedit.wsf /ar 0

    This enables the Remote Desktop for Administration mode to accept connections.

  2. On another computer, click Start, click Run, type mstsc, and then click OK.

  3. In Computer, enter the name of the Hyper-V Server, and click Connect.

  4. Log on using an administrator account.

  5. When the command prompt appears, you can manage the computer using the Windows command-line tools.

  6. When you have finished remotely managing the Hyper-V Server, type logoff in the command prompt to end your Remote Desktop session

noteNote
If you are running the Remote Desktop Services client on a previous version of Windows, you must turn off the higher security level that is set by default in Windows Server 2012. To do this, after step 1, type the following command at the command prompt:cscript C:\Windows\System32\Scregedit.wsf /cs 0

Did you find this helpful?
(1500 characters remaining)

Community Additions

ADD
© 2013 Microsoft. All rights reserved.