Add-VMSwitch
Add-VMSwitch
Adds a virtual switch to an Ethernet resource pool.
구문
Parameter Set: NetworkByName
Add-VMSwitch [-Name] <String[]> [-ResourcePoolName] <String[]> [-ComputerName <String[]> ] [ <CommonParameters>]
Parameter Set: NetworkByObject
Add-VMSwitch [-VMSwitch] <VMSwitch[]> [-ResourcePoolName] <String[]> [ <CommonParameters>]
자세한 설명
The Add-VMSwitch cmdlet adds a virtual switch to an Ethernet resource pool.
매개 변수
-ComputerName<String[]>
Specifies an array of Hyper-V hosts. The cmdlet adds the virtual switch on the Hyper-V hosts that you specify.
별칭 |
없음 |
필수 여부 |
false |
위치 |
named |
기본값 |
. |
파이프라인 입력 적용 여부 |
false |
와일드카드 문자 허용 여부 |
false |
-Name<String[]>
Specifies the name of the virtual switch to be added.
별칭 |
없음 |
필수 여부 |
true |
위치 |
1 |
기본값 |
없음 |
파이프라인 입력 적용 여부 |
true (ByValue) |
와일드카드 문자 허용 여부 |
true |
-ResourcePoolName<String[]>
Specifies the name of the resource pool to which the virtual switch is to be added.
별칭 |
없음 |
필수 여부 |
true |
위치 |
2 |
기본값 |
없음 |
파이프라인 입력 적용 여부 |
false |
와일드카드 문자 허용 여부 |
true |
-VMSwitch<VMSwitch[]>
Specifies the virtual switch to be added to the Ethernet resource pool.
별칭 |
없음 |
필수 여부 |
true |
위치 |
1 |
기본값 |
없음 |
파이프라인 입력 적용 여부 |
true (ByValue) |
와일드카드 문자 허용 여부 |
false |
<CommonParameters>
이 cmdlet은 일반 매개 변수 -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer 및 -OutVariable을 지원합니다. 자세한 내용은 다음을 참조하세요. about_CommonParameters(https://go.microsoft.com/fwlink/p/?LinkID=113216).
입력
입력 유형은 cmdlet에 파이프할 수 있는 개체의 유형입니다.
출력
출력 유형은 cmdlet이 내보내는 개체의 유형입니다.
- None by default; Microsoft.HyperV.PowerShell.VMNetwork if –PassThru is present.
예제
Example 1
Adds virtual switch Test to Ethernet resource pool Engineering Department.
PS C:\> Add-VMSwitch -Name Test -ResourcePoolName "Engineering Department"
Example 2
Adds virtual switch Test to Ethernet resource pool Engineering Department.
PS C:\> Get-VMSwitch –Name Test | Add-VMSwitch –ResourcePoolName "Engineering Department"