Just try it on an account-by-account basis if you want, using the username
in the command line rather than the variable

i.e. net user *username */domain /passwordchg:yes

On a single OU you could probably use dsquery to grab the account names
using something like

dsquery user ou=OUName,dc=*domainname*,dc=*domainsuffix* -o samid

but I am not too sure about that, someone else may want to chime in with a
good command line to grab the list of users from a specified OU



2009/3/4 John Hornbuckle <[email protected]>

>  If I were chicken and wanted to first try this on a small scale—say, just
> in one OU—how might I do that?
>
>
>
> I’d sure hate to screw up every account in one fell swoop…
>
>
>
>
>
>
>
> *From:* James Rankin [mailto:[email protected]]
> *Sent:* Wednesday, March 04, 2009 7:50 AM
> *To:* NT System Admin Issues
> *Subject:* Re: Changing Account Settings en Masse
>
>
>
> Try *for /f %%a in ('global "Domain Users" domainname^|find /v "$"') do
> net user %%a /domain /passwordchg:yes
> *
>
> You will need a copy of global.exe from the old ResKit for this
>
> There are probably much better ways to do it tho :-)
>
> 2009/3/3 John Hornbuckle <[email protected]>
>
> We’ve previously not allowed users to change their own passwords; we’ve
> handled that for them, and in Active Directory have their accounts
> configured to prevent them from doing it.
>
>
>
> We’re implementing some new policies now, and in the near future users will
> need to be able to change their own passwords.
>
>
>
> I feel sure there’s a way for me to enable this capability without having
> to launch ADUC and bring up each user’s account individually.
>
>
>
> Could one of you command line commandos give me a point in the right
> direction?
>
>
>
>
>
>
>
> John Hornbuckle
>
> MIS Department
>
> Taylor County School District
>
> www.taylor.k12.fl.us
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ <http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/>  ~

Reply via email to