Wednesday, September 10, 2014

SharePoint TroubleShooting - Can not access local farm when running script in sharepoint powershell

When you run Get-SPSite or Get-SPWeb in a SharePoint powershell window and get the following error,

Can not access local farm...

It is usually the permission issue. The user execute the power shell cmd is not in the SharePoint_Shell_Access role, just run this command, Add-SPShellAdmin -UserName ... to add the user will be fine,

Here is the reference links,
http://technet.microsoft.com/en-us/library/ee806878(v=office.14).aspx#section2
http://technet.microsoft.com/en-us/library/ff607596(v=office.14).aspx

No comments: