Windows Server 2012 – Install and Turn on GUI from Command Line

20
Posted September 17, 2012 by Patrick Kennedy in Software

What happens if you install Windows Server 2012 without the GUI features and then realize that you want to turn on the GUI? For those who are used to GUI based Windows Server administration, seeing a command line interface can be daunting. This guide will help you to go from the command line interface, using PowerShell, to installing and turning on the GUI.

Install the GUI on Windows Server 2012

The first step in this is to enter the PowerShell. At the command line prompt, just enter PowerShell and you will see something like the below:

Windows Server 2012 - Turn on GUI - PowerShell

Windows Server 2012 – Turn on GUI – PowerShell

The next step is to type Install-WindowsFeature Server-Gui-Shell, Server-Gui-Mgmt-Infra in order to get the

Windows Server 2012 - Turn on GUI - Install WindowsFeature

Windows Server 2012 – Turn on GUI – Install GUI

You will see a text based installer. This part of the Windows Server 2012 GUI installation is rather easy and there is plenty of time to grab a drink.

Windows Server 2012 - Turn on GUI - Grab a Drink During Install

Windows Server 2012 – Turn on GUI – Grab a Drink During Install

Once this is complete, you do need to reboot the server before the GUI will be turned on. Unless you have something else going on that you need to shutdown first, you can shutdown  and reboot immediately with shutdown -r -t 0 as seen below:

Windows Server 2012 - Turn on GUI - Reboot

Windows Server 2012 – Turn on GUI – Reboot

The system will then reboot and go through the Windows Server 2012 configuration changes.

Windows Server 2012 - Turn on GUI - Configuring Features

Windows Server 2012 – Turn on GUI – Configuring Features

When the system boots, you will see that the GUI is turned on. The Server Manager dashboard is present on login and everything works.

Windows Server 2012 - Turn on GUI - Installation Successful

Windows Server 2012 – Turn on GUI – Installation Successful

Conclusion

If you are accustomed to the Windows Server 2012 GUI, you may be a bit nervous seeing a command line only interface. Fear not, the guide above uses less than 90 characters of typing to install and turn on the GUI. In total this took me only a few minutes to do the run-through. Also, this guide assumed one has a command line only installation. If you already have the GUI installed, you can use SConfig to turn on the GUI easily.


About the Author

Patrick Kennedy

Patrick has been running ServeTheHome since 2009 and covers a wide variety of home and small business IT topics. For his day job, Patrick is a management consultant focused in the technology industry and has worked with numerous large hardware and storage vendors in the Silicon Valley. The goal of STH is simply to help users find some information about basic server building blocks. If you have any helpful information please feel free to post on the forums.

20 Comments


  1.  
    Rads

    I’m just a day to early, ended up re-installing yesterday before your article.

    Anyhow, the big question is how do you enable WinRM sucesfully so you can actually administer the damn server from a remote W2K12 machine?

    Running W2K12 inside a VM and want to adminsiter it from the W2K12 Hypervisor server admin, it can see the remote W2K12 server but “WinRM negotiation errors” are preventing me from doing anything with it!




  2.  
    zicoz

    Which version of WS2k12 should I use? Standard, Essentials, Foundation of Storage Server?

    I plan to only use it as a fileserver.




  3.  
    Stephen

    Along these lines, the following is from the release notes:

    If you upgrade from a Full installation of Windows Server® 2008 or Windows Server® 2008 R2 to Windows Server 2012 in Server with a GUI mode, and then switch Windows Server 2012 to Server Core mode, conversion back to Server with a GUI mode will fail.

    To avoid this, delete these registry keys with the following commands:

    reg delete HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WINEVT\Publishers\{bc2eeeec-b77a-4a52-b6a4-dffb1b1370cb}

    reg delete HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WINEVT\Publishers\{57e0b31d-de8c-4181-bcd1-f70e880b49fc}

    reg delete HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\WINEVT\Publishers\{8c9dd1ad-e6e5-4b07-b455-684a9d879900}

    After running these commands, restart the upgrade




  4.  
    Hurricane Sandy

    Stephen thx for that. Saw this and helped me.




  5.  
    Ryan

    I keep getting error: the system was unable to find the specific registry key.




  6.  

    Hey it has been stuck on 68% for about 30 minutes is this meant to happen?

    Thanks,
    Nathaniel




  7.  
    Nathaniel

    Don’t worry it did it :) Thanks anyway




  8.  
    Stuart

    For servers not connected to the internet, what is the syntax for specifying a source (the cd).
    The above only works for me if the server has an internet connection.
    Thanks very much…




  9.  
    Alex Richards

    Hi Stuart, to specify the server 2012 disc you need to add ” -source wim:d:\sources\install.wim:4″ assuming your disc drive is the d: drive.

    So it should look like this:
    install-windowsfeature server-gui-shell, server-gui-mgmt-infra -source wim:d:\sources\install.wim:4




  10.  
    OD

    Hi , there its really helpfull for beginers, tnx again GJ




  11.  
    Andy

    Just as a note you will need an internet connection otherwise you will get this error:

    Install-WindowsFeature : The request to add or remove features on the specified server failed.




  12.  
    Abdulla

    Thanks a lot, it worked for me and every time i install it i brows to this form and complete the installation




  13.  
    gerryf

    Stephen – thanks for the tip regarding the reg tweak, sorted this problem for me.




  14.  
    subaram

    i getting error_cbs_download_failure




  15.  
    Krishhna

    Thank You … It was really helpful to me…Had to wait for an hour before the setup completed…




  16.  
    Ryan

    Thanks for the article. This was quite helpful.




  17.  
    Darwish

    I received this error during the installation, any help?

    Install-WindowsFeature : The request to add or remove features on the
    specified server failed.
    Installation of one or more roles, role services, or features failed.
    The source files could not be downloaded.
    Use the “source” option to specify the location of the files that are required
    to restore the feature. For more information on specifying a source location,
    see http://go.microsoft.com/fwlink/?LinkId=243077. Error: 0x800f0906
    At line:1 char:1
    + Install-WindowsFeature Server-Gui-Shell, Server-Gui-Mgmt-Infra
    + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo : InvalidOperation: (@{Vhd=; Credent…Name=localh
    ost}:PSObject) [Install-WindowsFeature], Exception
    + FullyQualifiedErrorId : DISMAPI_Error__Cbs_Download_Failure,Microsoft.Wi
    ndows.ServerManager.Commands.AddWindowsFeatureCommand

    Success Restart Needed Exit Code Feature Result
    ——- ————– ——— ————–
    False No Failed {}




  18.  
    Ahmet KAÇMAZ

    Thanks for the article. This was quite helpful!





Leave a Response

(required)


Newly Reviewed
 
  • Intel 730 SSD
  • Intel DC P3700 400GB Internal View
  • AppliedMicro X-Gene
  • Ubuntu RAID 1 - Step 18 finish partitioning and write changes
  • XeonPhiDie_03
  • Mellanox ConnectX-4