Grant-ClusterAccess
Grant-ClusterAccess
Grants access to a failover cluster, either full access or read-only access.
Syntax
Parameter Set: InputObject
Grant-ClusterAccess [-User] <StringCollection> [-Cluster <String> ] [-Full] [-InputObject <PSObject> ] [-ReadOnly] [ <CommonParameters>]
Detailed Description
The Grant-ClusterAccess cmdlet grants access to a failover cluster, either full access or read-only access. To provide someone with read-only access to the cluster, use the ReadOnly parameter.
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 |
-Full
Specifies that the user gets full cluster access. If no access level is specified, then the user gets read-only cluster access.
Aliases |
none |
Required? |
false |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
-InputObject<PSObject>
Specifies the cluster on which to grant access for the given user.
Aliases |
none |
Required? |
false |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
true (ByValue) |
Accept Wildcard Characters? |
false |
-ReadOnly
Specifies that the user gets read-only cluster access. If no access level is specified, then the user gets read-only cluster access.
Aliases |
none |
Required? |
false |
Position? |
named |
Default Value |
none |
Accept Pipeline Input? |
false |
Accept Wildcard Characters? |
false |
-User<StringCollection>
Specifies the user for whom to grant cluster access.
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.
- Microsoft.FailoverClusters.PowerShell.Cluster
Outputs
The output type is the type of the objects that the cmdlet emits.
- None
Examples
Example 1
This example grants full access to the local cluster to johnj99 in the contoso domain.
PS C:\> Grant-ClusterAccess –User contoso\johnj99 -Full
Example 2
This example grants read-only access to the local cluster to johnj99 in the contoso domain.
PS C:\> Grant-ClusterAccess –User contoso\johnj99 -ReadOnly