Microsoft Azure - VM needs activation after upload

I recently ran into an issue after uploading a VM VHD to Microsoft Azure: The VM was not longer activated and prompted me for a license. How come? The VM cost in Azure includes license for the OS and I’ve migrated other servers to Azure without this happening.

Turns out there’s an easy solution to this:

  1. Find your OS version on this list: http://technet.microsoft.com/en-us/library/jj612867.aspx
  2. Enter the following commands on your server:
  3. slmgr /ipk <key> (for example, 2008 R2 Standard: slmgr /ipk YC6KT-GKW9T-YTKYR-T4X34-R7VHC)
  4. slmgr /skms kms.core.windows.net
  5. slmgr /ato

Now your OS should be activated.

Read more