In our past
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.
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
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.
Through the Windows Admin Center, create a new folder by selecting an item in the menu.
Go to the shared folder and click the send button, select the file.
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
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.
Launch Powershell and enter the following command:
Add-WindowsCapability -Online -Name ServerCore.AppCompatibility~~~~0.0.1.0
Then restart the server:
Restart-Computer
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.
Windows Server 2019 with Features on Demand installed
Windows Server 2019 Core
That's all. In the next article, we will look at the program compatibility table with Windows Server Core.
Source: habr.com