Book Image

Active Directory with PowerShell

By : Pamarthi Venkata Sitaram, YELLAPRAGADA U PADMAVATHI
5 (1)
Book Image

Active Directory with PowerShell

5 (1)
By: Pamarthi Venkata Sitaram, YELLAPRAGADA U PADMAVATHI

Overview of this book

If you are looking to automate repetitive tasks in Active Directory management using the PowerShell module, then this book is for you. Any experience in PowerShell would be an added advantage.
Table of Contents (11 chapters)
10
Index

Bulk creation of user accounts


In Chapter 2, Managing User and Computer Objects, we discussed the procedure to create user accounts in bulk. The code discussed here gives you a high-level overview of what is needed to read details from a CSV file and create user accounts using those details. The script in the following code is a much enhanced version and gives all the required code to create user accounts in bulk. One thing to note here is, as part of the account creation process, we are only setting up a few properties. But the real-time requirements might be different. So, you can use the code here as a sample reference and add more properties as you need so that you can adopt it in your environment. The input BulkUserCreation.csv file, which is used by this script, is also available along with the code samples. You can download it along with the script and make modifications accordingly.

Another thing to note here is that this script sets a default password for all the accounts created...