Hello, thank you for posting in the Microsoft Q&A community.
The standard approach if you are running an Evaluation version is to convert it to a full retail version before applying your product key. Please note that this process will require a reboot. Replace the XXXXX placeholder with your actual 25-character product key:
DISM /online /Set-Edition:ServerStandard /ProductKey:XXXXX-XXXXX-XXXXX-XXXXX-XXXXX /AcceptEula
If your server is utilizing Volume Licensing and you suspect network or KMS host issues, an alternative workaround is to force the installation of the Generic Volume License Key (GVLK) for Windows Server 2019 Standard, and then manually point the server to your KMS host. Ensure your KMS host is reachable over port 1688, then run these commands:
slmgr.vbs /ipk N69G4-B89J2-4G8F4-WWYCC-J464C
slmgr.vbs /skms <Your-KMS-Server-IP-or-FQDN>:1688
slmgr.vbs /ato
For further reference on Microsoft best practices, you can review the official documentation here: Upgrade and conversion options for Windows Server: https://learn.microsoft.com/en-us/windows-server/get-started/upgrade-conversion-options KMS Client Setup Keys: https://learn.microsoft.com/en-us/windows-server/get-started/kms-client-activation-keys