Skip to content

Deploy Active Directory Domain Using PowerShell

Deploy Active Directory  Domain using PowerShell

Let’s start by Setting the PowerShell Execution Policy to Unrestricted

Next we will rename the server and install Prereq features.

After the script has run successfully the sever will restart , once restarted launch the #PowerShell Console again and run the second script. This will install all the needed features to install Active Directory

After the feature installation has completed we can move on to Configure new Forest and Domain.

When the Script is running you will be prompted for the “Recovery Mode Password” , Enter the Password and Confirm.

Once you have Entered and Confirmed the “Recovery Password” Press Enter.
You will received a Notification Message asking to confirm the next steps. The Server will be promoted to a domain controller and will be restarted . Enter “Y” to access and Press Enter.

Installation and Configuration in progress and will restart server once done.

Server starting up after restart

On the Logon Screen we can now see we have the Option to Login to the “Domain”

Domain Controller Configuration by running a quick #OneLiner

This #OneLiner lets us View all Features related to Active Directory.

Let’s view the Domain Functional and Forest Functional Level using the “GUI”

Open “Active Directory Domains and Trusts” , Right click on the Domain name and select “Properties”. On the General Page you can view “Domain and Forest Functional Levels”

To make sure our newly Domain Controller has been created correctly lets run another #PowerShell #OneLiner to Test the Domain and Forest.
Let’s start by testing the Domain Controller Installation

As then we can do the same for the “Forest Installation”

New Forest and Domain Controller Build Complete .


Sharing is caring!

Published inActive DirectoryGroup PolicyPowerShellWindowsWindows Server 2012

Be First to Comment

Leave a Reply

Your email address will not be published.