Troubleshooting the Hyper-V Connector

Document created by mark.lillywhite Employee on Jul 17, 2017Last modified by mark.lillywhite Employee on Jul 17, 2017
Version 2Show Document
  • View in full screen mode

Standalone Hyper-V

Snow uses remote WMI calls to get information.
The following classes are examples of what is used:
  • Msvm_ComputerSystem
  • Msvm_KvpExchangeComponent
  • Win32_BIOS
  • Win32_ComputerSystem
  • Win32_NetworkAdapter
  • Win32_NetworkAdapterConfiguration
  • Win32_OperatingSystem
  • Win32_PhysicalMemoryArray
  • Win32_Processor 

This means that remote WMI calls need to be enabled.

You can try the following PowerShell command to try the call from the machine running SIM (start PowerShell as the same user the SIM is configured with):

  • Get-WmiObject -Class Win32_BIOS -ComputerName Server01

Replace "Server01" with the hostname of the Hyper-V server.

To get the virtual machines from the Hyper-V server the class Msvm_ComputerSystem is used. To get a list of the virtual machines and the host itself you can run the following command:

  • Get-WmiObject -Class Msvm_ComputerSystem -Namespace root\virtualization\v2 -ComputerName Server01

Replace "Server01" with the hostname of the Hyper-V server.


System Center VMM
Uses a remote PowerShell session and executes PowerShell scripts to gather information.
This requires PowerShell Remoting to be enabled on the Hyper-V server. This is usually enabled, but need to be verified.
Some notes about PSSessions:
  • To connect to a remote computer, you must be a member of the Administrators group on the remote computer.
  • In Windows Vista and later versions of Windows, to start an interactive session on the local computer, you must start Windows PowerShell with the "Run as administrator" option.
  • When you use Enter-PSSession, your user profile on the remote computer is used for the interactive session. The commands in the remote user profile, including commands to add Windows PowerShell snap-ins and to change the command prompt, run before the remote prompt is displayed.
  • Enter-PSSession uses the UI culture setting on the local computer for the interactive session. To find the local UI culture, use the $UICulture automatic variable.
  • Enter-PSSession requires the Get-Command, Out-Default, and Exit-PSSession cmdlets. If these cmdlets are not included in the session configuration on the remote computer, the Enter-PSSession commands fails.
  • Unlike Invoke-Command, which parses and interprets the commands before sending them to the remote computer, Enter-PSSession sends the commands directly to the remote computer without interpretation.
  • If the session that you want to enter is busy processing a command, there might be a delay before Windows PowerShell responds to the Enter-PSSession command. You will be connected as soon as the session is available. To cancel the Enter-PSSession command, press CTRL+C.
How to check if remoting and the required module is working
Open a PowerShell console as the user configured for the SIM.
Enter the following command to open a remote session to the VMM server (replace Server01 with the hostname of the Hyper-V host):
  • Enter-Pssession -ComputerName Server01
When the session is open, try to import the Virtual Machine Manager module which we use during the SIM import:
  • Import-Module VirtualMachineManager
Try to get some information from the server:
  • Get-VMMServer localhost
  • Get-VM
If all this is working and we are still seeing something wrong in the inventory files we probably need to check for the things missing using this PowerShell session.
9 people found this helpful