Install GUI on Windows Server Core

In our past post we told how we prepare standard client virtual machines and showed how we created a standard Windows Server 120 Core image using our new Ultralight tariff for 2019 rubles as an example.

The support service began to receive requests on how to work with Server 2019 Core without the usual graphical shell. We decided to show how to work with Windows Server 2019 Core and how to install a GUI on it.

Install GUI on Windows Server Core

Do not repeat this on working machines, do not use Server Core as a desktop, disable RDP, secure your information system, security is the main feature of the β€œCore” installation.

In one of our next articles, we will look at the program compatibility table with Windows Server Core. In this article, we will touch on how to install the shell.

Shell by third-party means

Install GUI on Windows Server Core

1. Complicated but most economical way

Server Core does not have the familiar explorer.exe out of the box, to make life easier for us, we will download explorer++. It replaces everything that the original explorer can do. Only explorer++ was considered, but almost any file manager will do, including Total Commander, FAR Manager and others.

Downloading files.

First we need to download the file to the server. This can be done via SMB (shared folder), Windows Admin Center and Invoke-WebRequest, it works with the -UseBasicParsing option.

Invoke-WebRequest -UseBasicParsing -Uri 'https://website.com/file.exe' -OutFile C:UsersAdministratorDownloadsfile.exe

Where -hate is the URL of the file, and -OutFile is the full path to download it, specifying the file extension and

Using Powershell:

Create a new folder on the server:

New-Item -Path 'C:OurCoolFiles' -ItemType Directory

Sharing the shared folder:

New-SmbShare -Path 'C:OurCoolFiles' -FullAccess Administrator 
-Name OurCoolShare

On your PC, the folder is connected as a network drive.

Install GUI on Windows Server Core
Through the Windows Admin Center, create a new folder by selecting an item in the menu.

Install GUI on Windows Server Core

Go to the shared folder and click the send button, select the file.

Install GUI on Windows Server Core
Adding a shell to the scheduler.

If you don't want to start the shell manually every time you log in, then you need to add it to the task scheduler.

$A = New-ScheduledTaskAction -Execute "C:OurCoolFilesexplorer++.exe"
$T = New-ScheduledTaskTrigger -AtLogon
$P = New-ScheduledTaskPrincipal "localAdministrator"
$S = New-ScheduledTaskSettingsSet
$D = New-ScheduledTask -Action $A -Principal $P -Trigger $T -Settings $S
Register-ScheduledTask StartExplorer -InputObject $D

Without a scheduler, you can run via CMD:

CD C:OurCoolFilesExplorer++.exe

Method 2. Launch native Explorer

Install GUI on Windows Server Core
Remember, no GUI

Server Core App Compatibility Feature on Demand (FOD), will return to the system: MMC, Eventvwr, PerfMon, Resmon, Explorer.exe and even Powershell ISE. More details can be found on MSDN. It does not expand the existing set of roles and features.

Launch Powershell and enter the following command:

Add-WindowsCapability -Online -Name ServerCore.AppCompatibility~~~~0.0.1.0

Then restart the server:

Restart-Computer

Install GUI on Windows Server Core

After that, you can even run Microsoft Office, but you will lose about 200 megabytes of RAM forever, even if there are no active users on the system.

Install GUI on Windows Server Core
Windows Server 2019 with Features on Demand installed

Install GUI on Windows Server Core
Windows Server 2019 Core

That's all. In the next article, we will look at the program compatibility table with Windows Server Core.

Install GUI on Windows Server Core

Source: habr.com

Add a comment