SharePoint 2010 Management Shell – .Net 4.0 runtime version error

Written by Tamer Maher El-Sharkawy, Premier Field Engineer


When you launch a SharePoint 2010 Management Shell you might receive one or both of the following errors:

  • “Microsoft SharePoint is not supported with version 4.0.30319 of the Microsoft .Net runtime”
  • “The local farm is not accessible. cmdlets with feature dependency are not registered.”

This could happen because the PowerShell version used by the shell isn’t the correct one.


At the command prompt run the following commands:

PS C:\ > $ver=$host | select version

PS C:\ > $ver.Version

Major  Minor  Build  Revision

-----  -----  -----  --------

3      0      -1     -1

If the version indicated is not “2”, the shell is indeed trying to execute with an unsupported runtime, and you get the error above.


First, try Import System Modules as shown:


If that does not resolve the issue, you can navigate to the Sharepoint Management Shell shortcut properties then add "-version 2" to the string in the Target field. Example:

C:\Windows\System32\WindowsPowerShell\v1.0\PowerShell.exe –version 2 -NoExit" & ' C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\CONFIG\POWERSHELL\Registration\\sharepoint.ps1 ' "


Tamer Maher, MCP, MCTS, MCITP

Comments (15)
  1. I am trying to find the "Import System Modules" is that something that I should download / have?

  2. Kent Nordström says:

    The example shortcut above does not work. The -Version 2 needs to be before -NoExit.

    Working shortcut is.

    C:WindowsSystem32WindowsPowerShellv1.0PowerShell.exe -Version 2 -NoExit " & ' C:Program FilesCommon FilesMicrosoft SharedWeb Server Extensions14CONFIGPOWERSHELLRegistration\sharepoint.ps1 ' "

  3. Konnie says:

    Thank you Kent.  This syntax fixed my problem.  I am still not sure why it broke all the sudden.  I have been using sharePoint 2010 Management Shell several months without a problem.  All of the sudden it stopped working.  Wonder if it was due to updates.  Anyway,  all fixed.

  4. Does NOT work for many processes that automatically use PowerShell like a scheduled task or PowerPivot with SSRS.

  5. I am actually getting an error launching the SharePoint Management Shell  for SP2013 on a Windows Server 2012.

    select : The term 'Select-Object' is not recognized as the name of a cmdlet,

    function, script file, or operable program. Check the spelling of the name, or

    if a path was included, verify that the path is correct and try again.

    At C:Program FilesCommon FilesMicrosoft SharedWeb Server

    Extensions15CONFIGPOWERSHELLRegistrationSharePoint.ps1:1 char:16

    + $ver = $host | select version

    +                ~~~~~~

       + CategoryInfo          : ObjectNotFound: (Select-Object:String) [], Comma


       + FullyQualifiedErrorId : CommandNotFoundException

    Any ideas?

    Thanks in advanced!

  6. Dan_IT says:

    I tried this and the powershell starts then exits

  7. Leo says:

    thanks, man!!!

  8. K1 says:

    Thanks a lot

  9. pradeep says:

    @Lou – did you find a solution for Select issue ?

  10. pradeep says:

    Hi Leu,

    I fixed the 'select-object' problem in the following way. Hope it helps…

    I found $env:psmodulepath as C:Usersuser_nameDocumentsWindowsPowerShellModules;;C:Program FilesAppFabric 1.1 for Windows ServerPowershellModules;C:Program FilesAppFabric 1.1 for Windows ServerPowershellModules

    As you can notice that AppFabric module path has repeated itself. I guess AppFabric has messed up with the psmodulepath while it got installed. So, I modified the PSModulePath variable under registry (at HKEY_LOCAL_MACHINESystemCurrentControlSetControlSession ManagerEnvironment) to include


    After this change, I am able to execute select & other basic cmdlets.

  11. SharePoint Online training says:

    Information was good, I like your post.
    Looking forward for more on this topic.">SharePoint Online training

  12. SharePoint consulting says:

    I absolutely love your blog and find nearly all of your post’s to be precisely what I’m looking for.">SharePoint consulting

  13. Mike says:

    Any updates to this issue? I’m getting the error “Event ID 3: Cmdlet Invoke-MbcaModel reported warning Microsoft SharePoint is not supported with version 4.0.30319.36415 of the Microsoft .Net Runtime.” Every night just after 2:00am.

    My syntax is as Kent describes above:

    C:\Windows\System32\WindowsPowerShell\v1.0\PowerShell.exe -Version 2 -NoExit ” & ‘ C:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\14\CONFIG\POWERSHELL\Registration\\sharepoint.ps1 ‘ ”

    This is on an SBS 2011 box. Thanks!

Comments are closed.

Skip to main content