Windows Server: Administration, Automation and Security (2016 to 2025)
Exit

Lesson 1 of 14 · Fundamentals and PowerShell

Windows Server: versions, editions, licensing, Core or Desktop Experience

35 min PowerShell 7 (Ubuntu) Versions 2016, 2019, 2022, 2025

Objective

Know which version of Windows Server to install, which edition to buy, how many licenses to plan for and which installation option to choose (Server Core or Desktop Experience). Also understand what roles and features are: the basic vocabulary for the rest of the course.

Key points

  • Four versions are still found in companies: 2016, 2019, 2022 and 2025. Each one is supported for 10 years (5 years of mainstream support, then 5 years of extended support). Windows Server 2016 ends on 12 January 2027.
  • Two main editions: Standard (2 virtual machines per license) and Datacenter (unlimited virtual machines, datacenter features). There is also Datacenter: Azure Edition, reserved for Azure and Azure Local.
  • Licensing is counted per physical core: all cores, with a minimum of 8 per processor and 16 per server. Users who connect also need CALs (client access licenses).
  • Server Core (no graphical desktop) is the option recommended by Microsoft: fewer updates, smaller attack surface. You cannot switch from Core to Desktop Experience after installation.
  • A role is a service provided to the network (DNS, DHCP, AD DS, Hyper-V…). A feature is a supporting tool (BitLocker, backup, clustering…). Both are installed with Install-WindowsFeature.

What is Windows Server?

Windows Server is Microsoft's server operating system. It shares its kernel with Windows 10 and 11, but it is designed to provide services to a whole network: user directory, file sharing, name resolution, IP address distribution, virtualization, remote desktop…

In a typical SME in Casablanca, you often find:

Server Role Why
SRV-DC01 domain controller (AD DS) + DNS employee accounts, single sign-on
SRV-FICHIERS file server shared folders for accounting and sales
SRV-HV01 Hyper-V host runs the other servers as virtual machines
SRV-APP02 business application management software, SQL Server database

Windows Server is deployed on a physical server, as a virtual machine (Hyper-V, VMware), or in the cloud (Azure and other providers). You manage it locally, with PowerShell, with Server Manager, or remotely with Windows Admin Center.

Versions

Since 2016, Microsoft has released an "LTSC" version (Long-Term Servicing Channel) every 2 to 3 years. This is the version installed on the vast majority of servers.

Version Release End of extended support Build number Key new features
Windows Server 2016 October 2016 12 January 2027 14393 Windows containers, Nano Server, Credential Guard, nested virtualization, production checkpoints
Windows Server 2019 October 2018 January 2029 17763 built-in OpenSSH, System Insights, Storage Migration Service, management with Windows Admin Center
Windows Server 2022 August 2021 October 2031 20348 "secured-core" server, TLS 1.3 by default, AES-256 SMB encryption, client-side DNS over HTTPS
Windows Server 2025 November 2024 2034 26100 hotpatch (updates without rebooting), direct upgrade from 2012 R2, delegated managed service accounts (dMSA), AD functional level 2025, SMB over QUIC in all editions, GPU partitioning

The exact dates are on Microsoft's "lifecycle" pages. Get into the habit of checking them before any project: an unsupported server no longer receives security fixes.

Windows Server 2012 and 2012 R2 have been out of support since 10 October 2023. Extended Security Updates (ESU), paid outside Azure, extended them until 13 October 2026: that date has passed, and they no longer receive any fixes. If you find a 2012 R2 at a customer site, it is the top priority of the project, followed closely by the 2016 servers (end in January 2027).

Hotpatch in Windows Server 2025

Normally, the monthly update forces you to restart the server every month, which means 12 restarts per year. With hotpatch, some of the fixes are applied in memory, without a restart: this drops to about 4 restarts per year (one per quarter). On Windows Server 2025 Standard and Datacenter, you must connect the server to Azure Arc (Microsoft's documentation now states that this hotpatch through Azure Arc is offered at no extra cost); it is included in the Datacenter: Azure Edition.

LTSC and Annual Channel

LTSC (long-term channel) Annual Channel (AC)
Release cadence every 2 to 3 years about every 12 months
Support 5 years + 5 years 18 months + 6 months
Installation Core or Desktop Experience Core only
Use classic servers: AD, files, Hyper-V, applications container hosts that want new features quickly

The product name does not tell you the channel. You read it in the display version:

Get-ComputerInfo | Format-List WindowsProductName, OSDisplayVersion
# WindowsProductName : Windows Server 2022 Datacenter
# OSDisplayVersion   : 21H2        <- LTSC (23H2 = Annual Channel)

# The build number is enough to recognize the version
(Get-CimInstance Win32_OperatingSystem).BuildNumber   # 20348 = 2022, 26100 = 2025

Editions

Standard Datacenter Datacenter: Azure Edition
Windows Server virtual machines covered 2 per license (+ the Hyper-V host) unlimited unlimited
Storage Spaces Direct (S2D) no yes yes
Network Controller (SDN), Shielded Hyper-V no yes yes
Hotpatch through Azure Arc (2025) through Azure Arc (2025) included
Where to install it anywhere anywhere Azure and Azure Local only

The two main editions have almost the same roles: AD DS, DNS, DHCP, file server, Hyper-V, IIS, WSUS… The difference is mainly a matter of virtualization rights.

  • Standard: one license (all cores) gives the right to 2 VMs. For 4 VMs, you license all cores twice; for 6 VMs, three times, and so on.
  • Datacenter: one license covers an unlimited number of VMs on that host. It costs about 6 to 7 times the price of Standard; it becomes cost-effective from 12 to 14 VMs per host, and it simplifies management (no need to recount for each new VM).

For very small organizations, some hardware vendors also sell an Essentials edition (small server, one processor, about twenty users at most) preinstalled on their hardware.

Moroccan examples

  • Accounting firm in Casablanca, one physical server for the directory and files, 1 VM: Standard.
  • Private school in Rabat, one host with 2 VMs (domain controller, file server): Standard.
  • Hotel in Marrakech, one Hyper-V host with 16 VMs (booking, accounting, cameras, guest Wi-Fi, testing…): Datacenter.

Licensing

Core licenses

Windows Server 2016 and later are licensed per physical core of the host server:

  1. you count all the physical cores of each processor;
  2. you count at least 8 cores per processor;
  3. you count at least 16 cores per server;
  4. licenses are sold in 2-core packs (with a base of 16).
Server Processors × cores Calculation Core licenses
small server 1 × 4 4 → 8 (minimum per processor) → 16 (minimum per server) 16
medium server 1 × 8 8 → 16 (minimum per server) 16
Hyper-V host 2 × 10 20 20
large host 2 × 16 32 32

Client access licenses (CALs)

Each user (User CAL) or each device (Device CAL) that uses the server must have a Windows Server CAL. For 30 employees who each have a PC and a phone, 30 User CALs cost less than 60 Device CALs. For a factory where 3 shifts share 20 workstations, the Device CAL is the better deal.

Remote Desktop (RDS) also requires RDS CALs, bought separately.

Other models

  • Pay-as-you-go (Windows Server 2025): license billed by the hour through an Azure subscription, for an on-premises server connected to Azure Arc.
  • Azure: a Windows Server VM in Azure includes the license in its price (or reuses your licenses with Azure Hybrid Benefit).
  • Evaluation: the trial image works for 180 days, perfect for a lab.

Server Core or Desktop Experience?

The setup wizard offers four images:

  • Windows Server Standard → Server Core;
  • Windows Server Standard (Desktop Experience);
  • Windows Server Datacenter → Server Core;
  • Windows Server Datacenter (Desktop Experience).
Server Core Desktop Experience
Interface command prompt, PowerShell, sconfig full Windows desktop, File Explorer, MMC consoles
Disk space about 4 GB less larger
Updates and restarts fewer more
Attack surface greatly reduced normal
Administration remote (Windows Admin Center, RSAT, PowerShell) local or remote
Available roles almost all (not those that require a desktop) all

Warning: since Windows Server 2016, the choice is final. Switching from Core to Desktop Experience (or the other way round) requires a reinstallation.

Tip: install Server Core for domain controllers, DNS, DHCP, Hyper-V hosts and file servers. Keep Desktop Experience for servers that run business software requiring a graphical interface, or for a Remote Desktop server.

Roles, role services and features

Term Definition Examples
Role a main service provided to the network AD-Domain-Services, DNS, DHCP, Hyper-V, Web-Server (IIS), UpdateServices (WSUS)
Role service a part of a role FS-DFS-Namespace in "File Services", FS-Resource-Manager (FSRM)
Feature a supporting component BitLocker, Windows-Server-Backup, Failover-Clustering, RSAT-AD-PowerShell
# List everything that exists, and what is installed
Get-WindowsFeature
Get-WindowsFeature | Where-Object Installed

# Search for a role by name
Get-WindowsFeature *DHCP*

# Install a role with its management tools (console, PowerShell module)
Install-WindowsFeature -Name DHCP -IncludeManagementTools

# Simulate without installing anything
Install-WindowsFeature -Name Hyper-V -IncludeManagementTools -WhatIf

# Uninstall
Uninstall-WindowsFeature -Name Telnet-Client

With Desktop Experience, the same work is done in Server Manager → Manage → Add Roles and Features.

Minimum hardware requirements

Item Minimum (Windows Server 2025)
Processor 1.4 GHz, 64-bit, with NX/DEP, SLAT (EPT/NPT) and SSE4.2
Memory 2 GB (4 GB recommended with Desktop Experience), ECC memory on a physical host
Disk 32 GB as the absolute minimum for the system partition
Network 1 Gb/s Ethernet adapter
For some features UEFI with Secure Boot, TPM 2.0 (required for BitLocker with TPM)

In a virtual machine, installation fails with only 1 GB of memory: give it at least 1.3 GB during installation, then reduce if needed. In practice, plan 4 GB for a domain controller and much more for an application server.

By version

Topic 2016 2019 2022 2025
End of extended support 12/01/2027 01/2029 10/2031 2034
In-place upgrade from 2012 or 2012 R2 2012 R2 or 2016 2016 or 2019 up to 4 versions back (from 2012 R2)
Hotpatch no no Azure Edition Azure Edition, or Standard/Datacenter through Azure Arc
SMB over QUIC no no Azure Edition all editions
Highest AD functional level 2016 2016 2016 2025
Pay-as-you-go licensing no no no yes (Azure Arc)

Common pitfalls

  • Installing Desktop Experience "for comfort" and then wanting to switch to Core: impossible without reinstalling.
  • Forgetting CALs: the core license allows the server to run, not users to connect to it.
  • Counting logical cores (hyper-threading): only physical cores count, with the minimums of 8 and 16.
  • Leaving a 2012 R2 running "because it works": no more fixes at all, and attacks often start from this kind of server.

Lab

You play the consultant who audits the servers of an SME in Casablanca, described in /root/parc/serveurs.csv:

  1. identify the servers to migrate first (2012 R2 and 2016);
  2. choose the edition for the Hyper-V host of a hotel in Marrakech;
  3. calculate the core licenses of three servers;
  4. take your first steps in PowerShell (pwsh) to filter the CSV file.

Quiz

  1. How many virtual machines does a Standard license (all cores licensed) allow?
  2. A server has 1 processor with 6 cores. How many core licenses are needed?
  3. Why does Microsoft recommend Server Core? And what is its main constraint?
  4. Which command installs the DNS role with its management tools?
  5. What is the end-of-support date of Windows Server 2016, and what should you do with a 2012 R2 server found at a customer site?
Answers
  1. Two virtual machines (plus the Hyper-V host if it is used only for virtualization). To get more, you license all cores again, or you move to Datacenter.
  2. 16: 6 cores → at least 8 per processor → at least 16 per server.
  3. Fewer components: fewer updates, fewer restarts, a reduced attack surface. Constraint: no local graphical interface, and you cannot add the desktop afterwards.
  4. Install-WindowsFeature -Name DNS -IncludeManagementTools.
  5. 12 January 2027. A 2012 R2 has been out of support since October 2023 and its ESU ended on 13 October 2026: you must migrate it without delay (new installation, or direct upgrade to 2025).

Reference sources: Microsoft Learn documentation on Windows Server (CC BY 4.0). Original MasterLinux text.

Practical exercises

To do on PowerShell 7 (Ubuntu)

The online terminal is coming soon. Meanwhile, do these tasks on your own Linux machine, a virtual machine or WSL.

  1. The file /root/parc/serveurs.csv describes the servers of an SME in Casablanca. Write to /root/parc/a-migrer.txt the names (one per line) of the servers still running 2012 R2 or 2016, because their support is ending or has already ended.
    Show a hintgrep -E ',(2012 R2|2016),' /root/parc/serveurs.csv | cut -d, -f1 > /root/parc/a-migrer.txt
    Show the solution
    grep -E '^[^,]+,(2012 R2|2016),' /root/parc/serveurs.csv | cut -d, -f1 > /root/parc/a-migrer.txt

    Check : test -f /root/parc/a-migrer.txt && [ "$(tr -d '\r ' < /root/parc/a-migrer.txt | grep -v '^$' | sort | paste -sd, -)" = "SRV-COMPTA,SRV-FICHIERS,SRV-WEB01" ]

  2. A hotel in Marrakech wants a single physical Hyper-V server that will run 16 Windows Server virtual machines. Write to /root/parc/hotel.txt the name of the edition to buy (a single word).
    Show a hintStandard covers 2 virtual machines per full license: 16 VMs would require 8 Standard licenses. Another edition covers an unlimited number of VMs.
    Show the solution
    echo Datacenter > /root/parc/hotel.txt

    Check : test -f /root/parc/hotel.txt && grep -qix '[[:space:]]*datacenter[[:space:]]*' /root/parc/hotel.txt

  3. Calculate the number of core licenses to buy for SRV-HV01, SRV-FICHIERS and SRV-DC01 (rule: all physical cores, at least 8 per processor and at least 16 per server). Write one line per server to /root/parc/coeurs.txt, in the format NAME=NUMBER (example: SRV-X=24).
    Show a hintSRV-HV01: 2 processors × 10 cores = 20. SRV-FICHIERS: 1 × 4, but at least 8 per processor and at least 16 per server.
    Show the solution
    printf '%s\n' 'SRV-HV01=20' 'SRV-FICHIERS=16' 'SRV-DC01=16' > /root/parc/coeurs.txt

    Check : f=/root/parc/coeurs.txt; test -f $f && grep -qx 'SRV-HV01=20' $f && grep -qx 'SRV-FICHIERS=16' $f && grep -qx 'SRV-DC01=16' $f

  4. First contact with PowerShell: start pwsh, then produce /root/parc/core.txt containing the names of the servers installed as Server Core, using Import-Csv, Where-Object and Select-Object -ExpandProperty.
    Show a hintImport-Csv /root/parc/serveurs.csv | Where-Object Installation -eq Core | Select-Object -ExpandProperty Nom > /root/parc/core.txt
    Show the solution
    pwsh -NoProfile -c "Import-Csv /root/parc/serveurs.csv | Where-Object Installation -eq Core | Select-Object -ExpandProperty Nom | Set-Content /root/parc/core.txt"

    Check : test -f /root/parc/core.txt && [ "$(tr -d '\r ' < /root/parc/core.txt | grep -v '^$' | sort | paste -sd, -)" = "SRV-DC01,SRV-HV01" ]

Official references consulted: Qu'est-ce que Windows Server ? — https://learn.microsoft.com/fr-fr/windows-server/get-started/overview ; Comparaison des éditions de Windows Server — https://learn.microsoft.com/fr-fr/windows-server/get-started/editions-comparison ; Canaux de maintenance Windows Server — https://learn.microsoft.com/fr-fr/windows-server/get-started/servicing-channels-comparison ; Server Core et Serveur avec Expérience de bureau — https://learn.microsoft.com/fr-fr/windows-server/get-started/install-options-server-core-desktop-experience ; Nouveautés de Windows Server 2025 — https://learn.microsoft.com/fr-fr/windows-server/get-started/whats-new-windows-server-2025. Original MasterLinux text.