Add-ClusterResourceDependency
Updated: August 15, 2012
Applies To: Windows Server 2012
Add-ClusterResourceDependency
Syntax
Parameter Set: InputObject Add-ClusterResourceDependency [[-Resource] <String> ] [[-Provider] <String> ] [-Cluster <String> ] [-InputObject <PSObject> ] [ <CommonParameters>]
Detailed Description
The Add-ClusterResourceDependency cmdlet adds a resource to the list of resources on which a particular resource depends, using AND as the connector, within a failover cluster. Existing dependencies will remain in the list.
A dependent resource is brought online after the resources on which it depends. A dependent resource is taken offline before the resources on which it depends.
Parameters
-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.
|
Aliases |
none |
|
Required? |
false |
|
Position? |
named |
|
Default Value |
none |
|
Accept Pipeline Input? |
false |
|
Accept Wildcard Characters? |
false |
-InputObject<PSObject>
Specifies the cluster resource for which to add the dependency.
|
Aliases |
none |
|
Required? |
false |
|
Position? |
named |
|
Default Value |
none |
|
Accept Pipeline Input? |
true (ByValue) |
|
Accept Wildcard Characters? |
false |
-Provider<String>
Specifies the cluster resource on which to add a dependency.
|
Aliases |
none |
|
Required? |
false |
|
Position? |
2 |
|
Default Value |
none |
|
Accept Pipeline Input? |
false |
|
Accept Wildcard Characters? |
false |
-Resource<String>
Specifies the name of the cluster resource for which to add a dependency.
|
Aliases |
none |
|
Required? |
false |
|
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.
Inputs
The input type is the type of the objects that you can pipe to the cmdlet.
- Microsoft.FailoverClusters.PowerShell.ClusterResource
Outputs
The output type is the type of the objects that the cmdlet emits.
- Microsoft.FailoverClusters.PowerShell.ClusterResource
Examples
Example 1
This example adds the resource named Cluster Disk 4 to the list of resources on which the resource called FileServer-(cluster1FS12)(Cluster Disk 2) depends, using AND as the connector.
PS C:\> Add-ClusterResourceDependency –Cluster "FileServer-(cluster1FS12)(Cluster Disk 2)" –Resource "Cluster Disk 4"
Name State Group ResourceType ---- ----- ----- ------------ FileServer-(clus... Online cluster1FS12 File Server
Related topics
