Jump to content

net group command


Nova
 Share

Recommended Posts

I found this on microsoft.com and im having a bit of trouble getting it to work

To add the existing user Nova to the Administrators group on the local computer, type:

So I typed this into cmd

net group Administrators Nova /add

I dont understand why this wont work, the user Nova is in the group Users shouldnt this command move Nova to the group Administrators ?

I get this msg after typing the above "More help is available by typing NET HELPMSG 3515"

OS:WINXP

Any ideas ?

Link to comment
Share on other sites

I get this msg after typing the above "More help is available by typing NET HELPMSG 3515"

Maybe you should read the whole error message or try to enter "net helpmsg 3515" as it tells you to do.

The error message is

This command can be used only on a Windows Domain Controller.

Everything clear?
Link to comment
Share on other sites

I use this

$KEY = "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon"

RunWait(@Comspec & " /c " & 'net user Michael /add', "", @SW_HIDE)
RunWait(@Comspec & " /c " & 'net localgroup Administrators Michael /add', "", @SW_HIDE)
RunWait(@Comspec & " /c " & 'net accounts /maxpwage:unlimited', "", @SW_HIDE)

RegWrite($KEY, "DefaultUsername", "Reg_SZ", "Michael")
RegWrite($KEY, "DefaultPassword", "Reg_SZ", "")
RegWrite($KEY, "AutoAdminLogon", "Reg_SZ", "1")

Oops, you may not need the AutoAdminLogon RegWrite line.

Edited by MHz
Link to comment
Share on other sites

Perfect MHz just what I woz looking for net localgroup Administrators Nova /add

Sugi:

This command can be used only on a Windows Domain Controller.

Ive no idea how i missed that msg ! I must have just overlooked it ! Tnx

Link to comment
Share on other sites

Perfect MHz just what I woz looking for net localgroup Administrators Nova /add

Sugi:

Ive no idea how i missed that msg ! I must have just overlooked it ! Tnx

<{POST_SNAPBACK}>

I've used this on workstations without any issues:

RunWait(@ComSpec & ' /c net localgroup Administrators /add ' & $NETWORKDOMAINGRP, @SystemDir, @SW_HIDE)

edit: just re-read above, sorry for reposting what had been said, didn't catch the first post's diff... (group instead of localgroup :ph34r: )

Edited by emmanuel

"I'm not even supposed to be here today!" -Dante (Hicks)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...