0

Does anyone know of a way (other than psexec) to add a user to the local administrators group of a remote machine?

I'm having trouble figuring out the syntax for wmic.

MDMarra
  • 100,183
  • 32
  • 195
  • 326
makerofthings7
  • 8,821
  • 28
  • 115
  • 196

1 Answers1

1

If you're in an Active Directory Domain you can use Restricted Groups or Group Policy Preferences Groups. The latter is newer, more flexible, and recommended if possible.

There is a PowerShell solution here if you don't have an AD Domain.

Doing it through Group Policy is the right way to do it, though. It'll allow you to change it later very easily if you need to.

MDMarra
  • 100,183
  • 32
  • 195
  • 326