In Windows Server 2008 and 2008 R2, you could not switch between the Server Core and Server With A GUI options, post-installation. If you chose to install Server with a GUI (called Full Installation in 2008/2008R2) or Server Core, you were stuck with your choice, as there were no means to convert between the two different options, post-installation.
With Windows Server 2012 and later, Microsoft added support for post-installation conversion between Server Core and GUI. In addition to that, Microsoft also added a third option, which can only be configured post-installation, the Minimal Server Interface option. In this blog post we will review the three installation options, and then we will go through how to convert Server 2012 R2 between the different installation options.
1. Installation Options
Server With A GUI will not be covered here, as all Windows Administrators should be well acquainted with that installation option.
1.1 Server Core
In Server 2012 R2, Server Core is actually the default installation option, instead of the Server With A GUI option. Server Core is as we all know a stripped down version of Server 2012 R2. There is no Start menu, no desktop Explorer shell, no Microsoft Management Console (MMC), and virtually no graphical applications. All you see when you start the computer is a single window with a command prompt.
All management of the server has to either be done remotely – through Server Manager, Remote Server Administration Tools (RSAT) or Powershell, or locally through the command prompt or Powershell. The benefits of Server Core are following;
⋅Less disk space required for the installation
⋅Smaller attack surface
⋅Less servicing overhead, as it requires fewer software updates. Meaning there will be fewer restarts, and thus less downtime.
⋅More of the system hardware is devoted to running essential services, as some of the most memory-intensive and processor-intensive elements of Server 2012 R2 are not present.
The following roles are not available in Server Core; Active Directory Federation Services, Application Server, Fax Server, Network Policy and Access Services, Remote Desktop Gateway, Remote Desktop Session Host, Remote Desktop Web Access, Volume Activation Services, Windows Deployment Services.
1.2 Minimal Server Interface
The Minimal Server Interface is a compromise between Server Core and Server With A GUI, you get to keep some of the GUI elements, while (some of) the most hardware-intensive elements are removed.
The following elements are removed; User interface (Start screen and desktop), Windows Explorer, Internet Explorer and some Control Panel utilities such as Devices and Printers Center, Display, Firewall, Windows Update, Fonts, Programs and Features, Network and Sharing Center.
What you are left with are Server Manager, MMC, Device Manager and Windows PowerShell Integrated Scripting Environment (ISE).
2. Converting between installation options
2.1 Using Server Manager
We will be performing the following conversions using Server Manager, from Server With A GUI to Minimal Interface, and then Minimal Interface to Server Core.
2.1.1 Launch the Remove Roles and Features Wizard
2.1.2 On the Features to remove page, scroll down to User Interfaces and Infrastructure, where you will have two choices you can remove
Graphical Management Tools And Infrastructure
This feature includes various infrastructure components and components that provide the Minimal Server Interface. You can not remove only this feature, if you remove it, Server Graphical Shell and Windows PowerShell ISE features will also have to be removed. Meaning if you remove this feature, your server will be converted to Server Core. The Powershell name for this feature is Server-Gui-Mgmt-Infra.
Server Graphical Shell
This feature includes components that provide the full GUI. If you remove just this feature you will be left with the Minimal Server Interface. The Powershell name for this feature is Server-Gui-Shell.
Btw, the Desktop Experience feature provides Windows 8.1 features such as desktop themes, photo management, and Windows Media Player. All of those features must be manually enabled after installing the Desktop Experience feature. The Powershell name for this feature is Desktop-Experience. This feature is useful in Virtual Desktop Infrastructure (VDI) environments.
2.1.3 Remove the check box for Server Graphical Shell, then click Next
2.1.4 Click Remove to start the Removal process.
2.1.5 When the feature has been removed, you will be told that you must restart the server to finish removing the feature. Click Close, then restart the server.
2.1.6 Log on to the server again, and you will be presented with the command prompt. But you can launch Server Manager and MMC by using the following two commands respectively, servermanager and mmc.
2.1.7 Now remove the Graphical Management Tools And Infrastructure feature.
2.1.8 Once you restart the server (by running shutdown -r -t 0 for example), and log on again, you will notice that it is no longer possible to start Server Manager or MMC, because you have now converted the server to the Server Core edition.
2.2 Using PowerShell
We will convert from Server Core to Server With A GUI, using the Powershell.
2.2.1 Start a Powershell session, by typing powershell
2.2.2 Run the following command to convert the server from Server Core to Server With A GUI
Install-WindowsFeature Server-Gui-Mgmt-Infra, Server-Gui-Shell -Restart -Source C:\windows\winsxs
The path C:\windows\winsxs for the –Source parameter in the preceding command specifies that binaries for the features can be found in the side-by-side store (%windir%\winsxs folder)
Alternatively, you could allow the necessary feature binaries to be downloaded and installed from Windows Update by omitting the –Source parameter as follows,
Install-WindowsFeature Server-Gui-Mgmt-Infra, Server-Gui-Shell -Restart
Note that if you previously converted a Server With A GUI installation to a Server Core installation and did not remove the binaries for these features, the binaries remain staged in the WinSxS folder and therefore do not need to be downloaded from Windows Update. Which holds true for this case.
2.2.3 If you just wanted to convert from Server Core to Minimal Server Interface, you would have used this cmdlet
Install-WindowsFeature Server-Gui-Mgmt-Infra -Restart
3. The side-by-side store
Most feature binaries are available locally in the side-by-side store (%windir%\winsxs folder) on installations of Server 2008 and later. But when you perform a clean installation of Server 2012 or later using the Server Core installation option, the feature binaries for the Graphical Management Tools And Infrastructure feature and Server Graphical Shell feature are not staged in the local side-by-side store.
Which means that when you install these features on such a setup, you must specify an alternate source for their binaries. It can be a mounted .wim file of a Windows Server 2012 or later installation of the same service pack level. Alternatively you can allow the feature binaries to be downloaded and installed from Windows Update, or you can define the source in a GPO.
The GPO setting is found in the following location
Computer Configuration\Policies\Administrative Templates\System\Specify Settings For Optional Component Installation And Component Repair
Since I am defining a UNC path here, I will have to give the computer account of the machine where I am installing the binaries, permission to access the files in the shared folder. Since the Trusted Installer process runs within the machine account’s context.
4. Features on Demand
The Features On Demand capability in Windows Server 2012 and later, enables administrators to remove packages from the WinSxS folder, which could not be done on installations of previous versions of Windows. This can reduce the disk footprint of the installation and enhance the security, as you remove binaries for features that will not be needed.
If you want to convert a Server With A GUI installation to a Server Core installation, and remove the binaries for the Server-Gui-Mgmt-Infra and Server-Gui-Shell features, you can run the following Powershell command,
Uninstall-WindowsFeature Server-Gui-Mgmt-Infra, Server-Gui-Shell -Remove