Glam Prestige Journal

Bright entertainment trends with youth appeal.

I'm looking for a method to automate activation Windows 7 machines through PowerShell. We get approximately 50 computers a month and it's slowly increasing, so manual activation is no longer possible with our deadlines. We're on a network where we can't run VAMT while connecting our server to the internet. We would prefer a script that could be written with a program and distributed via FTP. We already have the program framework, so we just need the script.

We're open to any other options as well, so long as they don't involve servers. We don't have the manpower to maintain another server on our local network.

We're using this right now:

slmgr.vbs /ipk XXXXX-XXXXX-XXXXX-XXXXX-XXXXX
slmgr.vbs /ato

This does not successfully activate the machines with the product keys we have.

Thanks in advance!

4

1 Answer

$computer = gc env:computername
$key = "XXXXX-XXXXX-XXXXX-XXXXX-XXXXX"
$service = get-wmiObject -query "select * from SoftwareLicensingService" -computername $computer
$service.InstallProductKey($key)
$service.RefreshLicenseStatus()

Taken from . This has just worked for me when activating machines a couple of days ago

1

Your Answer

Sign up or log in

Sign up using Google Sign up using Facebook Sign up using Email and Password

Post as a guest

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy