Sign up ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I'm trying to use the following script:

$password = ConvertTo-SecureString "xxxx" -AsPlainText -Force
$cred = New-Object System.Management.Automation.PSCredential("domain\Administrator", $password)
$session = New-PSSession -Credential $cred
Invoke-Command -Session $session -ScriptBlock { New-Cluster -Name "ClusterTest" -Node HOSTNAME }

To remotely create a cluster (it's for testing purposes) on a Windows Server 2012 VM. I'm getting the following error:

An error occurred while performing the operation.
    An error occurred while creating the cluster 'ClusterTest'.
    An error occurred creating cluster 'ClusterTest'.
    No credentials are available in the security package
    + CategoryInfo          : NotSpecified: (:) [New-Cluster], ClusterCmdletException
    + FullyQualifiedErrorId : New-Cluster,Microsoft.FailoverClusters.PowerShell.NewClusterCommand

All of my other remote commands (installing/making changes to DNS, DHCP, NPAS, GP, etc) work without an issue. Why is this one any different? The only difference is in the -ScriptBlock tag. Help!

share|improve this question
Have tried Administrator@domain instead of domain\Administrator? – HopelessN00b Aug 30 '12 at 20:58
@HopelessN00b Yeah, I just tried it. No such luck. – TheSciz Aug 30 '12 at 23:27
Then I'm out of ideas. All the Google results on that error seemed entirely unrelated. Unless... if you manually provide New-Cluster with credentials, does it fail with the same error? – HopelessN00b Aug 30 '12 at 23:30
How would I go about doing that? @HopelessN00b – TheSciz Aug 31 '12 at 4:44
@TheSciz The Invoke-Command cmdlet has a -Authentication parameter that allows different authentication methods to be used. See Get-Help Invoke-Command -Full and… for more info. – Bernie White Oct 4 '12 at 9:08

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.