I need to update one attribute (LOCATION)  of users in active directory

but there are 1000 users and I want to do 200 in a batch

is there any script I can use so that 200 users get their attribute updated in a batch
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Abhilash PappiyilTechnical Lead - Network SupportCommented:

If you are happy to use it to run as a logon script, you can create a gpo then add the script as a logon script. You can create a security group and add the first batch of 200 users in the security group, then add that security group in the security filtering of the gpo, so that it will be applied to those users only.

Shaun VermaakTechnical SpecialistCommented:
Jeremy WeisingerSenior Network Consultant / EngineerCommented:
Why do you want to do it in batches of 200? Since this is just updating an attribute in AD, it should be able to be done with minimal load and in less than a minute.

Can you tell us the criteria around this change? e.g. only 1000 out of 20,000 are being changed? Will every user be changed to the same location? etc...
Shaun VermaakTechnical SpecialistCommented:
You can also do this via the tool in this article. It adds a set number of random users to a group. You can then use Powershell against only members of this group.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Active Directory

From novice to tech pro — start learning today.