How to Upgrade a Windows Server 2016 VM to Windows Server 2019 in Azure

Share on:

Upgrading a Windows Server from 2016 to 2019 is a necessary step for keeping up with the latest features, performance improvements, and security updates. In this blog post, I’ll walk through how I successfully upgraded a Windows Server 2016 virtual machine (VM) hosted on Azure to Windows Server 2019, using Microsoft’s Default KMS Key for activation.

Here’s the process I followed, and how you can do the same.


Why Upgrade to Windows Server 2019?

Windows Server 2019 brings various benefits over its 2016 predecessor, including:

  • Improved performance and scalability.
  • Enhanced security features, including Windows Defender ATP.
  • Better hybrid cloud integration with Azure services.
  • Enhanced container support for better application modernization.

With those features in mind, I decided it was time to upgrade one of my Azure VMs from Windows Server 2016 to Windows Server 2019. Below is how I did it.


Pre-Upgrade Checklist

Before upgrading any server, especially a production one, it's important to ensure everything is properly set up to avoid unnecessary downtime or loss of data. Here’s what I did:

  1. Backup Your VM (Create a Snapshot): First and foremost, I created a snapshot of my VM in Azure to back up the disk. This ensures that if anything goes wrong during the upgrade process, I could easily roll back to the previous working state. Here’s how to create a full disk snapshot:

    • Go to the Azure Portal and navigate to your VM.
    • Under the Settings section of the VM, click on Disks.
    • Select the disk that you want to back up (usually the OS disk) and click Create snapshot at the top of the page.
    • In the Create Snapshot blade, choose the following:
      • Name: Give your snapshot a descriptive name.
      • Snapshot type: Choose Full to back up the entire disk.
      • Storage type: Select the appropriate storage type based on your requirements.
    • Click Review + create, then Create to start the snapshot process.

    Once the snapshot is created, it acts as a backup that can be used to restore the VM to its previous state if the upgrade fails.

  2. Disable Non-Essential VM Extensions: I disabled any non-essential VM extensions that could potentially interfere with the upgrade. Things like backup agents, monitoring tools, or antivirus extensions could disrupt the upgrade process.

  3. Check Application Compatibility: I ensured that the critical applications running on the server were compatible with Windows Server 2019. This is an important step to avoid post-upgrade issues.


Step-by-Step Guide: Upgrading to Windows Server 2019

Once I was ready, I moved forward with the upgrade process itself.

1. Download the Windows Server 2019 ISO

To start, I logged into my Windows Server 2016 VM via Remote Desktop Protocol (RDP). Next, I downloaded the Windows Server 2019 ISO directly from the Microsoft Evaluation Center.

2. Mount the ISO

After the download completed, I right-clicked the ISO file and selected Mount to mount it as a virtual drive on the VM. This allowed me to access the installation files for Windows Server 2019.

3. Run the Setup

From the mounted ISO, I navigated to the setup.exe file and launched it. The installation wizard immediately started and presented several upgrade options.

  • I chose the Upgrade option and selected Keep personal files and apps to preserve my existing applications and data.
  • I opted for Windows Server 2019 (Desktop Experience) to keep the familiar GUI. For those running Server Core, there’s also an option to upgrade to the Core version.

4. Entering the Default KMS Key

During the setup process, I was prompted to enter a product key. Since my VM was hosted on Azure, it automatically used KMS (Key Management Service) for licensing. To proceed with the upgrade, I used the Default KMS Key for Windows Server 2019, provided by Microsoft:

  • Windows Server 2019 Datacenter: WMDGN-G9PQG-XVVXX-R3X43-63DFG
  • Windows Server 2019 Standard: N69G4-B89J2-4G8F4-WWYCC-J464C

I entered the appropriate key based on my current Windows Server edition, and the installation process continued smoothly from there.

5. Complete the Upgrade

The upgrade took some time, during which the VM restarted multiple times. After the final reboot, I logged in to find that my VM was successfully upgraded to Windows Server 2019!


Post-Upgrade Tasks

After the upgrade was completed, there were a few post-upgrade tasks I needed to perform:

  1. Verify Activation: I checked that Windows Server 2019 was properly activated. Since I used the Default KMS Key, the system automatically activated with Azure’s KMS service.

  2. Check VM Extensions: I re-enabled the VM extensions that were previously disabled, such as backup agents and monitoring tools.

  3. Windows Updates: I ran Windows Update to ensure all the latest security patches and feature updates were applied to the newly upgraded system.

  4. Test Applications: Lastly, I tested all the critical applications running on the server to ensure they were functioning as expected.


Final Thoughts

Upgrading an Azure VM from Windows Server 2016 to Windows Server 2019 was a straightforward process thanks to the easy availability of tools like ISO downloads and the use of Default KMS Keys for activation. As long as you take the necessary precautions—like backing up your VM and ensuring application compatibility—the upgrade can be completed with minimal disruption.

If you’re running an Azure VM on Windows Server 2016, I highly recommend making the switch to Windows Server 2019 to benefit from the enhanced features and performance. With the detailed steps outlined above, you’ll be able to upgrade with confidence.

This was my process for upgrading my Azure VM. If you have any questions or need further clarification, feel free to reach out!