Skip to content

Setup a 2008 R2 Domain Controller with PowerShell Install-TAFirst2008R2DomainController

 

I’m a bit behind on publishing various PowerShell scripts I use. This is the script I use to quickly setup a lab 2008 R2 domain controller. It adds the appropriate Windows Features, then based on parameter input builds a dcpromo.exe unattended input file.

Download the script here: https://github.com/tomarbuthnot/Install-TAFirst2008R2DomainController

Use at your own risk. Feedback Welcome

It takes the following parameters

Domain name in the form domain.int
[string[]]$Domain,

        NetBios Domain name e.g. domain
[string[]]$NetBiosDomainName

First AD Site Name
[string[]]$ADSite = ‘lab-site1’,

This entry specifies the domain functional level.
[string[]]$Domainlevel = ‘4’,

ForestLevel
[string[]]$ForestLevel = ‘4’,

Directory Services Safe Mode Password
[string[]]$DSSafeModePassword = ‘Pa$$w0rd’,

Typical use would be:

Install-TAFirst2008R2DomainController –domain lab3.com –netbiosdomainname lab3

image

image

image

Published inMicrosoft

3 Comments

  1. tripps tripps

    The link the link to the script is dead. Can you correct it? It seems really useful.

  2. Rob Rob

    Hi Tom,

    Indeed your script looks very useful. Would you be so kind as to check the link to the script?

    Smashing :-)

    Greetings
    Rob

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.