How to Configure Active Directory on Windows Server 2012
In Server Manager, go to Manage, and click Add Roles and Features. It opens the Add Roles and Features Wizard. Click Next.
Note: If you have previously selected to skip this page by default, you will be going to the next page directly
In Select Installation Type, select Role-based or feature-based installation and click Next.
Select “Select a server from the server pool”. In Server Pool, ensure that the local computer is selected and click Next.
Select Active Directory Domain Services from Roles.
You will be prompted to add required features. Click Add Features and then click Next.
In Features, select Next.
Read the information in Active Directory Domain Services page and click Next.
In the Confirmation page, click Install to install the roles, role services, or features on the server.
The installation process will start. You may close the wizard.
When the installation is completed, click on Notifications in Server Manager, and click on the link Promote this server to a domain controller.
When the Active Directory Domain Services Configuration Wizard opens, select Add a new forest and enter Root domain name. Then click Next.
(Note: The provided instructions in this article are for installing a new forest. If you are installing an additional domain controller in an existing domain or installing a new child domain or installing a new domain tree, refer to Windows Server Docs available here for more information.)
In Domain Controller Options, leave Forest functional level and Domain functional level as default. Leave Domain Name System (DNS) server checked. Provide a password for Directory Services Restore Mode and click Next.
(Note: DSRM password is required when booting the domain controller into recovery mode)
Ignore the warning given in DNS Options page. Click Next.
Verify NetBIOS domain name. Click Next.
Specify locations for AD DS Database folder, Log Files folder, and SYSVOL folder.
(Note: It is recommended to leave these as defaults). Click Next.
Review your selections and click Next.
The wizard will validate the prerequisites before installing AD DS. When all checks are passed successfully, click Install.
The installation will be started.
When the installation is completed, click Close to finish the wizard.
Active Directory Domain Services have been successfully installed. Your machine will be rebooted automatically.
Now you have set up Active Directory on your Windows Server 2012 R2 successfully. You can use Active Directory Users and Computers tool to access your newly created active directory.