For a user to be able to use the SharePoint 2010 Management Shell, the user account must be granted the SharePoint_Shell_Access role (of a SharePoint content database) and be a member of the WSS_Admin_WPG group.
Attempting to run the Management Shell without these permission will result in the following error message;
The local farm is not accessible. Cmdlets with FeatureDependencyId are not registered.
The Add-SPShellAdmin powershell command can be used to grant this permission for an arbitrary user account, the command accepts a username in the DOMAIN\useraccount form and a reference to a content database.
Given that content databases can be widely dispersed, the following powershell script will set these permissions given a web application reference;
cls add-pssnapin microsoft.sharepoint.powershell -ea SilentlyContinue $accs = ("domain\user1","domain\user2","domain\user3") (Get-SPContentDatabase -webapplication "http://mywebapp") | % { "Content Database: $($_.Id), $($_.Name)" $db = $_ $accs | % { "`tAdding ShellAdmin rights for account: $_ to DB $($db.Name)" Add-SPShellAdmin -UserName $_ -database $db } }