Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

We currently run SharePoint 2010 Enterprise in our production environment and are looking at updated our build and deploy framework that is written in PowerShell. It would be nice to take advantage of PowerShell v3 in some instances, however, with all that I have read warning not to install PowerShell v3 in a PowerShell 2010 environment I am wondering if there are other opertaions that might be affected by this install as well. With some of the warnings about installing PowerShell v3 with SharePoint 2010 I can think of workarounds, as will some others in my IS group, so to be prepared I would like to get an idea about the background operations that SharePoint does and what is affected.

Working around the issues with the Management Console is possible by changing shortcuts, the Remoting we would be doing would need updating, but so long as we have the final version of the WMF in place that should not be an issue. So I would like to know if:

  1. Are there SP Jobs or processes that utilize PowerShell at all? Many of the cmdlets we use to get details on SP Content Databases or processes could potentially be used by the various background jobs that run, but I do not know for sure.
  2. Do the Scheduled Jobs use PowerShell at all? I do not know all the details of the Jobs as I usually deal with SP on an Administrative level using the Central Admin Console and only use the Management Console when troubleshooting issues.
  3. Are there areas that might be affected that I have not touched on? SP is complex, and has many moving parts I do not normally deal with, so I do not want to forget something else.
  4. If we updated to SharePoint 2013 would these issues be resolved? I realize this is a bigger project, but it would be nice to have some information on this for anyone who is using SP 2013.
share|improve this question

1 Answer 1

PowerShell v3 uses .NET v4 and SharePoint 2010 uses .NET v3.5. This means that you cannot use any of the new features of PowerShell v3 in your SharePoint 2010 environment. So if your original plan is to use any of the new features of PowerShell in a SharePoint 2010 environment, it won't work.

However, If you want to use the new features of PowerShell v3 (and .NET 4) outside of SharePoint on the same server it is possible. PowerShell v3 installation will be done alongside PowerShell v2 - and you can still manage your farm with PowerShell v2 using this command line:

>powershell.exe -version 2

But you will unfortunately lose the capability of Windows PowerShell ISE, a favorite tool among SharePoint Admins (me included).

Reference: PowerShell V3: A Few of My Favorite Things

Looking at our 14-hive we find one significant file located at \14\CONFIG\POWERSHELL\Registration named SharePoint.ps1, contatining a signature to connect PowerShell with SharePoint through the command Add-PSSnapin. If this file is affected on installing PowerShell v3, I do not know, but Microsoft themselves have listed the installation of PowerShell v3 as a Known Compatability Issue.

As you say, there are numerous of blogs saying don't, as the article Do not install the Windows Management Framework 3.0 (KB2506143) on SharePoint 2010 Servers. However, the problem listed only regards Management Shell, not the farm. And since you can load the version 2, it shouldn't be a problem running v2 scripts.

The same goes from Microsofts own reply:

Posted by Microsoft on 6/7/2012 at 12:34 PM

This is not an issue with Windows PowerShell. This is an issue with SharePoint 2010. The SharePoint team is aware of this compatibility issue and plans to address it in an upcoming release or service pack.

That release or service pack haven't, to my best of knowledge, been made available to the public.

Conclusion

To be absolutely sure that you won't damage your farm, migrate to SharePoint 2013. But if you already have installed PowerShell v3, and you (or your users) don't experience any lack of features, you're probably safe. Just remember to use version 2 when scripting your 2010 SharePoint farm.

share|improve this answer

Your Answer

 
discard

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.