Implicit Remoting for SharePoint 2013

I need to be able to use implicit remoting to a SharePoint 2013 server. Using the information in the article below I have set it up and am trying to import the session, but am getting the following error:

import-pssession: Running the get-Command command in a remote session returned no results.

Not sure if it makes a difference, but the psversion on the server is 3 and the psversion on the client machine is 5.

Any suggestions are welcome


That’s a known problem with SP2013. Implicit Remoting doesn’t work with it very well. There are authentication problems, as well as what you’re running into. “Don’t use SP2013” is the most common answer I see. I mean… it is pushing 6 years old.

Yep on get off SP2K13, but we know how many enterprises are, meaning slow to move for whatever the reason. I still have to deal with this at many customers I get called to engage with. Legacy everything, but they want to do all this new stuff. Argh!!!

You do not say how you PSRemoting environment is setup. SP requires extra steps to do this.

Understand the security ramifications of some remote session types, and specifically SharePoint.

MS TechNet has had this documented for over 4 years now.

How to enable Remote PowerShell for SharePoint 2013 for Non-Administrators

See also:

Once you get all setup as required…
(In all my use cases to date, I just had to do this - the below has not worked in all scenarios)

# On the SharePoint Server
Enable-PSRemoting -Force Enable-WSManCredSSP -Role Server -Force
Enable-WSManCredSSP -Role Server -Force

# On your management 
# Client (this has to be done once per unique managment client)
Enable-WSManCredSSP -Role Client -DelegateComputer * -Force
Set-ItemProperty HKLM:\SYSTEM\CurrentControlSet\Control\Lsa\Credssp\PolicyDefaults\AllowFreshCredentials -Name WSMan -Value WSMAN/*
Set-ItemProperty HKLM:\SYSTEM\CurrentControlSet\Control\Lsa\Credssp\PolicyDefaults\AllowFreshCredentialsDomain -Name WSMan -Value WSMAN/*

you should be able to do this. Well, I have, and it’s worked in my use cases as needed.

SharePointSession = New-PSSession -ComputerName SharePointServerFqdn `
-Authentication Credssp -Credential ResourceAdministrator
Invoke-Command -Session SharePointSession `
-scriptblock {Add-PsSnapin Microsoft.SharePoint.PowerShell}
Import-PSSession SharePointSession