Configuring MS Hyper-V Server for remote administration

As this was a bit tricky here are the notes:

On the hyper-v 2012 R2 console:

  1. Configure date and time (select #9).
  2. Enable Remote Desktop (select #7). Also select the ‘Less Secure’ option.
  3. Configure Remote Management (select #4 then #1).
  4. Add local administrator account (select #3). Username and password need to be exactly the same as the account you are going to use on the client computer to manage this Hyper-V Server.
  5. Configure network settings (select #8). Configure as a static IP. Same subnet as your home network. Don’t forget to configure the DNS IP.
  6. Set the computer name (select #2). Rename the server.

    Reboot the server (select #12).

  7. Remote Desktop to server. On your client machine, remote to the server via the IP address you assigned it. Use the credentials of the local administrator account you created earlier.
  8. Launch PowerShell. In the black cmd window, run the following command: start powershell
  9. Run the following commands:
    • Enable-NetFirewallRule -DisplayGroup “Windows Remote Management”
    • Enable-NetFirewallRule -DisplayGroup “Remote Event Log Management”
    • Enable-NetFirewallRule -DisplayGroup “Remote Volume Management”
    • Set-Service VDS -StartupType Automatic

      Reboot the server (select #12).
  10. Enable Client Firewall Rule. 
    On your client machine, launch an elevated PowerShell prompt and type the following command:
    • Enable-NetFirewallRule -DisplayGroup “Remote Volume Management”

      for german client use:
      Enable-NetFirewallRule -DisplayGroup “Remotevolumenverwaltung”
    • ii c:\windows\system32\drivers\etc
  11. Add server hostname and IP to hosts file. 
    Right click hosts and select properties. In the security tab, add your username. Give your account modify rights.This is needed because some remote management tools we need to use rely on the hosts file to resolve the name. Without doing this you are highly likely to encounter some errors while trying to create VHDs and such. Error you might see: There was an unexpected error in configuring the hard disk.

 

Access hyperv Server only via DNS, access via IP will not work!

 

I have to confirm these traps on next install, but it seems that:

  • timezone betwen client and server have to match, so that remote-desktop works
  • reboot after rename and firewall reconfiguration are necessary

-------------------------

Add client to list of trusted hosts:

winrm set winrm/config/client @{TrustedHosts="RemoteComputerName"}

 

 Access hyper-v 2012 server via hyper-v manager from workgroup to workgroup:

see: http://blog.mpecsinc.ca/2009/06/hyper-v-error-access-denied-unable-to.html

 

  • Close the Hyper-V Manager
  • Click Start and type: %windir% [Enter].
  • A Windows Explorer window will open to the Windows directory.
  • Type: dcomcnfg in the Search Windows field at the top right hand of the Explorer window.
  • You will see the following in your search results:image
  • Right click on dcomcnfg and Run As Administrator.
  • Authenticate with the local admin credentials if UAC prompts for credentials, or Continue if it does not.
  • Open the Component Services node, then the Computers node, then right click on My Computerand click on Properties.
  • Click on the COM Security tab.
  • You will see the following:image
  • Click the Edit Limits button under Access Permissions.
  • Enable Remote Access for Anonymous Logon
  • Before and after shot:image
  • Click Apply and OK.
  • Close the Component Services console and the Windows Explorer window.
  • Start the Hyper-V Manager and continue through the UAC.