Enable-VMSwitchExtension
Enable-VMSwitchExtension
Enables one or more extensions on one or more switches.
Syntax
Parameter Set: ExtensionName
Enable-VMSwitchExtension [-Name] <String[]> [-ComputerName <String[]> ] [ <CommonParameters>]
Parameter Set: ExtensionNameSwitchName
Enable-VMSwitchExtension [-Name] <String[]> [-VMSwitchName] <String[]> [-ComputerName <String[]> ] [ <CommonParameters>]
Parameter Set: ExtensionNameSwitchObject
Enable-VMSwitchExtension [-Name] <String[]> [-VMSwitch] <VMSwitch[]> [-ComputerName <String[]> ] [ <CommonParameters>]
Parameter Set: ExtensionObject
Enable-VMSwitchExtension [-VMSwitchExtension] <VMSwitchExtension[]> [-ComputerName <String[]> ] [ <CommonParameters>]
Detailed Description
The Enable-VMSwitchExtension cmdlet enables one or more extensions on one or more switches. You can use the Get-VMSystemSwitchExtension cmdlet to enumerate the virtual switch extensions installed on the system.
Parameters
-ComputerName<String[]>
Specifies one or more Hyper-V hosts on which an extension is to be enabled. 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 |
. |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
-VMSwitch<VMSwitch[]>
Specifies the virtual switch on which the extension is to be enabled.
Aliases |
none |
Required? |
true |
Position? |
2 |
Default Value |
none |
Accept Pipeline Input? |
True (ByValue) |
Accept Wildcard Characters? |
false |
-VMSwitchExtension<VMSwitchExtension[]>
Specifies the extension to be disabled.
Aliases |
none |
Required? |
true |
Position? |
1 |
Default Value |
none |
Accept Pipeline Input? |
True (ByValue) |
Accept Wildcard Characters? |
false |
-VMSwitchName<String[]>
Specifies the name of the switch on which the extension is to be enabled.
Aliases |
none |
Required? |
true |
Position? |
2 |
Default Value |
none |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
-Name<String[]>
Specifies the name of the network extension to be enabled.
Aliases |
none |
Required? |
true |
Position? |
1 |
Default Value |
none |
Accept Pipeline Input? |
false |
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.NetworkExtension
Examples
Example 1
Enables WFP (“Microsoft Windows Filtering Platform”) on a virtual switch named External.
PS C:\> Enable-VMSwitchExtension –VMSwitchName External –Name “Microsoft Windows Filtering Platform”