Manage your administration with ADAC and PowerShell

 Jun 24, 2014

You may find that during your day to day administration, you will be creating, renaming, and moving objects from one Organisational Unit (OU) to another. Now, this can be made easier if you have scripts setup for these kinds of jobs. You may even have some existing VBScripts for this purpose. What you’d like to do is migrate them to PowerShell scripts, because, well, why wouldn’t you?! The problem is, your PowerShell scripting isn’t the greatest, so where do you begin? Good news! I’d like to introduce you to the Active Directory Administrative Center (ADAC). The aim of ADAC is to provide data-driven and task-driven object management for Active Directory. You can use it to manage users, groups, computers, OUs, etc. You may be thinking "Steve, isn’t that what AD Users and Computers [dsa.msc] is for?" and you’d be right, it is also for that. However, our end goal is to try to eliminate the manual labour and script it in PowerShell. How does ADAC help me? I’m glad you asked this question! Let’s say I wanted to create a user called Ayrton Senna, place them into an OU called ‘Blah’ and make a bunch of other standard changes. From within ADAC, I can create a user and when done so, I'll see something similar to the following dialog box: Manage your administration with ADAC and PowerShellNow anything highlighted with an asterisk (*) is a required value, and I can either scroll down the page to access fields, or I can click the sections on the left. Once completed, I click 'OK' and can see my user: Manage your administration with ADAC and PowerShell So how will this help me? Well, unlike AD Users and Computers, ADAC performs all GUI actions by running PowerShell cmdlets. This is why there is a ‘Windows PowerShell History’ bar running along the bottom of the screen, which can be clicked to toggle display. If I click it, it shows all the command executed to perform my tasks. Manage your administration with ADAC and PowerShellI can then select a single item, multiple items or all items, and start to flesh out my scripts, replacing discrete values with variables where applicable. So, next time you need a new user, OU, machine or you just need to make some changes, use ADAC, examine the history and start to script your way out of tedium!

How do your Excel skills stack up?   

Test Now  

About the Author:

Steve Wiggins  

Steve is a highly experienced technical trainer with over 10 years of specialisation in Software Application Development, Project Management, VBA Solutions and Desktop Applications training. His practical experience in .NET programming, advanced solution development and project management enables him to train clients at all levels of seniority and experience. Steve also currently manages the IT infrastructure for New Horizons of Brisbane, providing him with daily hands-on experience with SCCM, Windows Server 2012 and Windows 8.

Read full bio
Back to top