Get-VMNetworkAdapterVlan
Get-VMNetworkAdapterVlan
Gets the virtual LAN settings configured on a virtual network adapter.
Syntax
Parameter Set: VMName
Get-VMNetworkAdapterVlan [[-VMName] <String[]> ] [-ComputerName <String[]> ] [-VMNetworkAdapterName <String> ] [ <CommonParameters>]
Parameter Set: ManagementOS
Get-VMNetworkAdapterVlan -ManagementOS [-ComputerName <String[]> ] [-VMNetworkAdapterName <String> ] [ <CommonParameters>]
Parameter Set: ResourceObject
Get-VMNetworkAdapterVlan [-VMNetworkAdapter] <VMNetworkAdapterBase[]> [ <CommonParameters>]
Parameter Set: VMObject
Get-VMNetworkAdapterVlan [-VM] <VirtualMachine[]> [-VMNetworkAdapterName <String> ] [ <CommonParameters>]
Parameter Set: VMSnapshot
Get-VMNetworkAdapterVlan [-VMSnapshot] <VMSnapshot> [ <CommonParameters>]
Detailed Description
The Get-VMNetworkAdapterVlan cmdlet gets the virtual LAN settings configured on a virtual network adapter.
Parameters
-ComputerName<String[]>
Specifies one or more Hyper-V hosts on which the virtual LAN settings configured on a virtual network adapter are 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? |
named |
Default Value |
none |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
-ManagementOS
Specifies that the virtual LAN settings are to be retrieved from the management (i.e. parent, or host) operating system.
Aliases |
none |
Required? |
true |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
-VM<VirtualMachine[]>
Specifies the virtual machine in which the virtual LAN settings configured on a virtual network adapter are to be retrieved.
Aliases |
none |
Required? |
true |
Position? |
1 |
Default Value |
none |
Accept Pipeline Input? |
True (ByValue) |
Accept Wildcard Characters? |
false |
-VMName<String[]>
Specifies the name of the virtual machine in which the virtual LAN settings configured on a virtual network adapter are to be retrieved.
Friendly name of the virtual machine
Aliases |
none |
Required? |
false |
Position? |
1 |
Default Value |
none |
Accept Pipeline Input? |
True (ByValue) |
Accept Wildcard Characters? |
false |
-VMNetworkAdapter<VMNetworkAdapterBase[]>
Specifies the virtual network adapter for which the virtual LAN settings are to be retrieved.
Aliases |
none |
Required? |
true |
Position? |
1 |
Default Value |
none |
Accept Pipeline Input? |
True (ByValue) |
Accept Wildcard Characters? |
false |
-VMNetworkAdapterName<String>
Specifies the name of the virtual network adapter for which the virtual LAN settings are to be retrieved.
Aliases |
none |
Required? |
false |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
-VMSnapshot<VMSnapshot>
Specifies the snapshot in which the virtual LAN settings are to be retrieved.
Aliases |
none |
Required? |
true |
Position? |
1 |
Default Value |
none |
Accept Pipeline Input? |
True (ByValue) |
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.
Examples
Example 1
Gets the virtual LAN settings for each virtual network adapter in all virtual machines on the system.
PS C:\> Get-VMNetworkAdapterVlan