none
Forum FAQ: How to install PowerShell feature on a Windows Server 2008 R2 Server Core server and a Microsoft® Hyper-V™ Server 2008 R2.

    General discussion

  • Question

     

    PowerShell feature is a very useful management tool for system administrators, especially on Server Core server  and Microsoft Hyper-V Server 2008 R2 which do not have UI. How can I install PowerShell feature on a Windows Server 2008 R2 Server Core server?

     

    Answer

     

    PowerShell feature depends on the NetFx2-ServerCore feature to be installed properly. To install the PowerShell feature, we need to first install NetFx2-ServerCore feature and then install MicrosoftWindowsPowerShell feature. To do so, please perform the following steps:

     

    1.            Use the following command to displays a list of features and their status:

     

    DISM /Online /Get-Features

     

    2.            Enables the NetFx2-ServerCore feature:

     

    DISM /Online /Enable-Feature /FeatureName: NetFx2-ServerCore

     

    3.            Enables the PowerShell feature:

     

    DISM /Online /Enable-Feature /FeatureName: MicrosoftWindowsPowerShell

     

    When you finish the above steps, you will be able to find the C:\Windows\system32\WindowsPowerShell folder and launch the shell.

     

    Note: It is recommend that you use DISM to install the features instead of OCSETUP in Windows Server 2008 R2. DISM is a new tool in Windows Server 2008 R2 and is more intelligent than OCSETUP.

     

    In addition, there are some other useful CMDLET you can use:

     

    DISM /online /enable-feature /featurename=ServerManager-PSH-Cmdlets

    DISM /online /enable-feature /featurename=BestPractices-PSH-Cmdlets

     

    More Information

     

    Microsoft® Hyper-V™ Server 2008 R2

    http://www.microsoft.com/hyper-v-server/en/us/default.aspx

     

    Windows PowerShell Getting Started Guide

    http://msdn.microsoft.com/en-us/library/aa973757(VS.85).aspx

     

    Applies to

     

    Windows Server 2008 R2

    Microsoft® Hyper-V™ Server 2008 R2

    Monday, February 22, 2010 6:03 AM

All replies

  • Is there a way I can install DISM or even better, the whole R2 features to a 2008 R1 server core installation?

    We are running server core 2008 R1.

     

    Tuesday, May 10, 2011 6:59 AM