Change license key of Windows Server
Needed to install two Windows Server 2012 R2 instances today, but didn't have a valid production license key yet and didn't seem like there was a way to skip the key in the setup. Found you can remove a license key using a command, so worked around it using a temporary dev key from MSDN for the installation and then removed that key afterwards. For future self-reference, here's how...
- Open an elevated command prompt
- To remove key run
- To add new one run
slmgr -ipk NEW-KEYor use regular activation process