Set-ClusterParameter
Set-ClusterParameter
Controls specific properties of an object in a failover cluster, such as a resource, a group, or a network.
구문
Parameter Set: InputObject
Set-ClusterParameter [[-Name] <String> ] [[-Value] <PSObject> ] [-Cluster <String> ] [-Create] [-Delete] [-InputObject <PSObject> ] [-Multiple <hashtable> ] [ <CommonParameters>]
자세한 설명
The Set-ClusterParameter cmdlet controls specific properties of an object in a failover cluster, such as a resource, a group, or a network.
-- For a disk resource, you can set the disk signature or GUID of a disk, and turn maintenance on or off for that disk.
-- For a Network Name resource, you can set DNS-related information about the resource.
-- For an IP address resource, you can set DHCP-related information about the IP Address resource.
-- For resources used by virtual machines, you can set details about the settings for the virtual machines.
매개 변수
-Cluster<String>
Specifies the name of the cluster on which to run this cmdlet. If the input for this parameter is .
or it is omitted, then the cmdlet runs on the local cluster.
별칭 |
없음 |
필수 여부 |
false |
위치 |
named |
기본값 |
없음 |
파이프라인 입력 적용 여부 |
false |
와일드카드 문자 허용 여부 |
false |
-Create
Causes the cmdlet to create the parameter on the cluster object, if it does not already exist.
별칭 |
없음 |
필수 여부 |
false |
위치 |
named |
기본값 |
없음 |
파이프라인 입력 적용 여부 |
false |
와일드카드 문자 허용 여부 |
false |
-Delete
Causes the cmdlet to delete the parameter from the cluster object.
별칭 |
없음 |
필수 여부 |
false |
위치 |
named |
기본값 |
없음 |
파이프라인 입력 적용 여부 |
false |
와일드카드 문자 허용 여부 |
false |
-InputObject<PSObject>
Specifies the cluster object for which to set the parameters.
별칭 |
없음 |
필수 여부 |
false |
위치 |
named |
기본값 |
없음 |
파이프라인 입력 적용 여부 |
true (ByValue) |
와일드카드 문자 허용 여부 |
false |
-Multiple<hashtable>
Allows multiple cluster parameters to be set simultaneously. These parameters are provided in the form of a hashtable.
별칭 |
없음 |
필수 여부 |
false |
위치 |
named |
기본값 |
없음 |
파이프라인 입력 적용 여부 |
false |
와일드카드 문자 허용 여부 |
false |
-Name<String>
Specifies the name of the cluster parameter to set.
별칭 |
없음 |
필수 여부 |
false |
위치 |
1 |
기본값 |
없음 |
파이프라인 입력 적용 여부 |
false |
와일드카드 문자 허용 여부 |
false |
-Value<PSObject>
Specifies the value to be set for the cluster parameter.
별칭 |
없음 |
필수 여부 |
false |
위치 |
2 |
기본값 |
없음 |
파이프라인 입력 적용 여부 |
false |
와일드카드 문자 허용 여부 |
false |
<CommonParameters>
이 cmdlet은 일반 매개 변수 -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer 및 -OutVariable을 지원합니다. 자세한 내용은 다음을 참조하세요. about_CommonParameters(https://go.microsoft.com/fwlink/p/?LinkID=113216).
입력
입력 유형은 cmdlet에 파이프할 수 있는 개체의 유형입니다.
- Microsoft.FailoverClusters.PowerShell.Cluster
- Microsoft.FailoverClusters.PowerShell.ClusterGroup
- Microsoft.FailoverClusters.PowerShell.ClusterNetwork
- Microsoft.FailoverClusters.PowerShell.ClusterNetworkInterface
- Microsoft.FailoverClusters.PowerShell.ClusterNode
- Microsoft.FailoverClusters.PowerShell.ClusterParameter
- Microsoft.FailoverClusters.PowerShell.ClusterResource
- Microsoft.FailoverClusters.PowerShell.ClusterResourceType
- Microsoft.FailoverClusters.PowerShell.ClusterSharedVolume
출력
출력 유형은 cmdlet이 내보내는 개체의 유형입니다.
예제
Example 1
This example configures the clustered resource called cluster1FS on the local cluster, by setting the value of HostRecordTTL to 300.
PS C:\> Get-ClusterResource –Name cluster1FS | Set-ClusterParameter –Name HostRecordTTL –Value 300
Example 2
This example uses the Multiple parameter to configure the clustered resource called Cluster IP Address, by setting the Address, Network, and EnableDhcp parameters simultaneously.
PS C:\> Get-ClusterResource –Name "Cluster IP Address" | Set-ClusterParameter -Multiple @{"Address"="172.24.22.168";"Network"="Cluster Network 2";"EnableDhcp"=1}
Example 3
This example configures the clustered resource called IP Address to use a new static IP. Because the new address and subnet mask are required, both parameters must be passed to this cmdlet together.
PS C:\> $res = Get-ClusterResource –Name "IP Address"
PS C:\> $param1 = New-Object –ComObject Microsoft.FailoverClusters.PowerShell.ClusterParameter –Property $res,Address,10.55.88.46
PS C:\> $param2 = New-Object –ComObject Microsoft.FailoverClusters.PowerShell.ClusterParameter –Property $res,SubnetMask,255.0.0.0
PS C:\> $params = $param1,$param2
PS C:\> $params | Set-ClusterParameter