Get-VMHost

Get-VMHost

Gets a Hyper-V host.

Syntax

Parameter Set: Default
Get-VMHost [[-ComputerName] <String[]> ] [ <CommonParameters>]

Detailed Description

The Get-VMHost cmdlet gets a Hyper-V host.

Parameters

-ComputerName<String[]>

Specifies one or more Hyper-V hosts to be retrieved. NetBIOS names, IP addresses, and fully-qualified domain names are allowable. The default is the local computer — use “localhost” or a dot (“.”) to specify the local computer explicitly.

Aliases

none

Required?

false

Position?

1

Default Value

.

Accept Pipeline Input?

true (ByValue, ByPropertyName)

Accept Wildcard Characters?

false

<CommonParameters>

This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see    about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216).

Inputs

The input type is the type of the objects that you can pipe to the cmdlet.

Outputs

The output type is the type of the objects that the cmdlet emits.

  • Microsoft.Virtualization.Powershell.Host

Examples

Example 1

Gets the local Hyper-V host.

PS C:\> Get-VMHost