Activating Windows 10 Pro after deployment
@george1421 I ran this command, substituting the NPPR9 key with the key provided with the machine, and it successfully activated. On the reddit thread linked to in the OP, someone provided a way I can automate using an Excel database and an slmgr script, but if I can avoid an extra step and just enter the key into FOG, that’d probably be easiest/best.
@Sebastian-Roth I followed your instructions, and after restarting the service, the FOG log says:
Checking Product Key Activation: #1234567890123456789012345#
No extra spaces anywhere, and also no dashes. (Obviously the 123…345 above is just 25 characters of filler.) For reference, when I performed machine inventory at the first PXE boot, I assigned the Product Key, but did not type in dashes. When viewing the key in the GUI, it has dashes, though they disappear if I click in the field. If I try typing dashes, they appear and disappear.
Perhaps the best/easiest way to manage this is to allow the user to input with or without dashes, and then store the key stripped of dashes, so that when it’s run against the length checker, it matches 25. Let me know what you think, and if you have any additional tests you’d like me to perform.
@ckasdf Let’s see if we can shed a light on this by adding a bit more output to the code. I just recompiled the Modules.dll (including the HostnameChanger code) to actually output the key to see if it’s empty (response from the FOG server wrong) or if there is some kind of extra character in the key that is causing it to be of a different length.
Download Modules.zip (19.4 KB), extract the Modules.dll, stop FOGService (Windows Services management console), rename C:\Program Files (x86)\FOG\Modules.dll and put the new Modules.dll in place. Then start the FOGService again and watch the log for
Checking Product Key Activation: #NPPR9-...#(the hash tags are intended so we even notice if there is a trailing space or whatever).
I hope you have fog-client version 0.11.16 installed as it would terribly fail otherwise - service won’t properly start and you wouldn’t see anything in the log.
I don’t use FOG to specifically activate since we use KMS server. But, when we were using mak keys we had something like this in our setupcomplete.cmd batch file.
Note the key was gleaned from some random page on the internet. I don't know if its real or borrowed from some place else. The key is only intended for use as an illustration.
cscript /nologo slmgr.vbs /ipk NPPR9-FWDCX-D2C8J-H872K-2YT43
So to help try to debug this issue with FOG and the key management (note the fog client is needed to activate the target computer. There is a different option if we can’t get fog to do what is needed).
What I want you to do is to open an elevated command prompt on one of these unactivated computer. Then key in the cscript command using one of your keys. See if the system activates using this method. You will note the dashes are in the example I provided which would get you to 29 characters. These computers will probably need direct or indirect (proxy’d) internet access to activate correctly.