page contents

About the Post

Author Information

HOW TO: Go from GUI to CORE and back to GUI in Server 2012

I have been preparing to upgrade my Windows and SQL certifications for 2012. I was checking out an article on switching from Server GUI to Server core. This article was written for Windows Server 8 Beta and was called How to Turn the GUI Off and On in Windows Server 2012. It gave me the impression you could also start from server core and go to a GUI, but I see the menu was different from the one they showed.

Here is mine and note that option number 12 is to log off the user:

Here is one from that article, take note of option number 12 (Restore GUI):

So it made me wonder how it is done and why not update the information for Server 2012 in the process. (No Beta or RC versions) I started with an installation of Server 2012 with a GUI and decided to remove it. Let’s begin with the process of removing the GUI, which is pretty easy. Also you might be asking yourself, why would I want to have SQL server running as a VM and as Server Core? (Plus are there any advantages you would gain using Windows Server 2012 Hyper-V over VMWare?)

Here is a very brief overview and my opinion:

  • Faster Failover Times for Unplanned Failovers- Unplanned failover in a VM often takes ~5min. AlwaysOn unplanned failovers take <30sec. (Also, remember VMotion doesn’t help with unplanned failovers)
  • Reduced downtime for SQL and Windows patching and upgrades. (Often overlooked as a benefit)
  • Faster DR, as selected workloads can be quickly brought online in a DR scenario
  • Readable Secondary for offloading report traffic

Open Server Manager and then Click on Manage, and then select Remove Roles and Features from the menu.

Select your server from the server pool and click next.

Since the GUI is not a Role, you can just click next again to skip past the Roles section. On the Features page, you need to ensure that the box is unchecked next to the “User Interfaces and Infrastructure” option, and then click next.

Now click the “Restart Destination Server” box, then click remove.

Then you will see Windows make the new changes:

After the reboot, all you have now is a Server core installation with only a command prompt.

Type in “sconfig

Notice the menu has changed since Server 8 Beta and there is no more revert back to GUI option:

I was reading the Windows Server 2012 Pocket consultant and it mentions that you have 3 types of installations now:

  1. Server with a GUI
  2. Server Core
  3. Server with minimal interface

I also found this article on the Microsoft Premier Field Engineers blog called Converting a server with a GUI to or from Server Core. It also talks about the three installations of Windows Server 2012 as well. I will look at exploring Server with a minimal interface at a later time. For now, I am just going to focus on Server GUI and Server Core.

To add the server back to a GUI, you will need to use the new 3.0 PowerShell cmdlet Add-WindowsFeature Server-Gui-Shell to convert it back. Again, this is a very simple method to convert back to a GUI from Core. To get there, type in powershell at the command prompt and then type Add-WindowsFeature Server-Gui-Shell as seen below:

It will start running the job and you will see a status menu, like this one below:

When it is done, you will need to reboot the server and the easiest method is to type shutdown –r –f –t 0 (restart, force, time 0 seconds)

Again, it will make the changes for you while the restart is happening:

After the restart, you are back to the GUI as seen here:

I am really glad to see that Microsoft made this change and I can see a lot of good here. I am a big fan of flexibility and this allows for it, plus I really like the direction PowerShell is headed with this release of Windows.

I think it is great for people who start off with a GUI and then decide that it causes too much of a performance hit or they want to move a server to a regional office where there is no support staff. This allows you to save on resources and also lock down the exposed surface area. More importantly, if you ever ran into a weird issue, you could convert back to GUI mode for easily troubleshooting and you get to do all of this without having to re-install the box. Plus you get to make your boss think you are incredible as well, by doing the task in a very fast manner.

Tags: , , , , ,

Comments are closed.

Copy Protected by Chetan's WP-Copyprotect.