A long time ago I posted a VBSCRIPT and CSV file which when executed created over 300 user accounts in Active Directory which was designed to give you a number of test accounts which could be used within a LAB environment to test Exchange Server.
As mentioned the original script was based around VBSCRIPT and Exchange 2003 and also required a little bit of manual intervention in order for it to work within your specific environment.
Therefore given the above (and that I have been rebuilding my test lab) I am pleased to present to you with an updated CSV file and script (where the script is now Powershell based) – which supports the following scenarios:
- Can be executed via Powershell versions 1.0 and 2.0
- Can be run on the following Operating Systems: Windows 2008 and Windows 2008 R2 (will also support Windows 2003 with Powershell installed)
- The accounts created can be configured with mailboxes for Exchange 2007 and Exchange 2010
Create-Users.exe [ 142KB ]
The above file is a self extracting ZIP which when executed with extract two files to you Exchange Server / Windows 2008 Domain Controller.
When you have downloaded and extracted the scripts to your server – open a Powershell Console and navigate to the location where they are located – when there type in:
.\CreateUsersFromCSV.ps1 and then press
When the script executes you will be presented with a Windows “Open” dialog box – navigate to the location where you extracted the files and then choose the sample CSV – see below;
The script will then execute creating each user in your Active Directory Lab environment – the Default password is “Password1” – see below;
When the script has completed – open Active Directory Users and Computers – you will see a new OU called “ExchangeUsers” – within this OU are the new accounts that you can play with – see below;
I hope that you find the above useful.