Create Lab AD – part 3

We have:

  1. Real names
  2. User Names (samAccountNames) with employee numbers

In this part we will do stuff for the Lab OUs and we will also pick Country
for the users.

We will not create anything until we have what we need in information.

$labOUs = "Finance","IT","Marketing","Operations","Service","Customer Support"

$mylabOUs = $labOUs | Get-Random

The output will be one of the OUs in the $labOUs.

Finance

IT

Marketing

Need more OU names, just add yours.

Now It’s time to do the same way to make some countries for the users.

$userCountry = "Sweden", "Norway", "Denmark", "Finland"
$myUserCountry = $userCountry | Get-Random

No related posts.

This entry was posted in PowerShell Blogs and tagged , , , . Bookmark the permalink.

3 Responses to Create Lab AD – part 3

  1. Fredrik Wall says:

    Create Lab AD, OUs and Countries, http://bit.ly/8sZBN4 #PowerShell #How-To

  2. Fredrik Wall says:

    Create Lab AD, OUs and Countries, http://bit.ly/8sZBN4 #PowerShell #How-To

  3. Pingback: Create Lab AD – Updated version | Dalle & DXter

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>