GPO StartUp Script for KMS Run as Admin and Stop User Prompts

Soren-IT 1 Reputation point
2020-08-25T19:04:31.927+00:00

We have 2 Data Centers which are connected to the same AD's Structure through a VPN tunnel. We have two KMS Servers due to using a VDI solution, if they is a fail-over we need to be able to License the newly created machines. KMS DNS setup only works when using a single KMS Server. The work around is to manually set a the KMS Server and the Windows 10 GVLK with a Batch File.

I have done this as a start up script through GPO. The GPO is working and applying however the script does not seem to be running. I am 100% sure the GPO is working and starting the script because the logs are returning a error code 0. I think the issue is a combination of admin permissions and user prompts when the script is run.

I could use some help with making sure the script is running as an admin and is not have permission errors.

I also need help modifying the script so it runs either with out User Notification Prompts or just ignores them completely.

The script is

@Echo OFF

slmgr /ipk W269N-WFGWX-YVC9B-4J6C9-T83GX

slmgr /skms "KMS Server FQDN":1688

slmgr /ato

After the slmgr /ipk and Slmgr /skms commands there is a popup letting you know that the command run and requires you to hit enter to continue.

Thanks

Windows
Windows
A family of Microsoft operating systems that run across personal computers, tablets, laptops, phones, internet of things devices, self-contained mixed reality headsets, large collaboration screens, and other devices.
4,798 questions
Windows Server
Windows Server
A family of Microsoft server operating systems that support enterprise-level management, data storage, applications, and communications.
12,205 questions
Active Directory
Active Directory
A set of directory-based technologies included in Windows Server.
5,932 questions
0 comments No comments
{count} votes

3 answers

Sort by: Most helpful
  1. Vicky Wang 2,646 Reputation points
    2020-08-26T08:17:39.287+00:00

    Hi,
    Thank you for posting in our forum.
    According to my judgment, this problem may be a scripting problem.
    I recommend you to post to the script forum, they can give you more professional help
    Hope this information can help you
    Best wishes
    Vicky

    0 comments No comments

  2. Vicky Wang 2,646 Reputation points
    2020-08-31T07:18:29.26+00:00

    Hi,
     
    Just want to confirm the current situations.
     
    Please feel free to let us know if you need further assistance.
     
    Best Regards,
    Vicky 

    0 comments No comments

  3. Vicky Wang 2,646 Reputation points
    2020-09-03T01:35:25.347+00:00

    Hi,
     
    Just want to confirm the current situations.
     
    Please feel free to let us know if you need further assistance.
     
    Best Regards,
    Vicky 

    0 comments No comments