From LedHed's Wiki
If you get the following error when trying to activate Windows 2008 R2 against a Key Management Server (KMS) try the following:
Error: 0x8007000D
http://support.microsoft.com/kb/2230957
If that doesn't work try running these commands:
slmgr.vbs /rilc slmgr.vbs /rearm
Restart
slmgr.vbs /ato