Active Directory Configuration on VM in Hyper-V Windows Server 2019
Table of Contents
Introduction
This tutorial will guide you through the process of configuring Active Directory on a Windows Server 2019 virtual machine (VM) in Hyper-V. You will learn how to connect multiple machines using a virtual switch, create a domain with Active Directory, and join a Windows 10 client to the domain. This setup is essential for managing user access and resources in a network environment.
Step 1: Setup Hyper-V and Create Virtual Machines
Before configuring Active Directory, ensure you have Hyper-V set up with the necessary virtual machines.
-
Install Hyper-V:
- Open the Server Manager on Windows Server 2019.
- Navigate to "Add roles and features."
- Select "Hyper-V" and follow the prompts to install it.
-
Create Virtual Machines:
- Open Hyper-V Manager.
- Click on "New" and select "Virtual Machine."
- Follow the wizard to create the Windows Server 2019 VM and a Windows 10 client VM.
-
Configure Network:
- In Hyper-V Manager, create a virtual switch
- Go to "Virtual Switch Manager."
- Select "New virtual network switch," choose "External," and connect it to your physical network adapter.
- Assign the virtual switch to each VM.
Step 2: Install Active Directory Domain Services
With your virtual machines set up and connected, you can now install Active Directory.
-
Open Server Manager on the Windows Server 2019 VM.
-
Add Roles and Features:
- Click on "Add roles and features."
- Select "Active Directory Domain Services" and proceed with the installation.
-
Promote the Server to Domain Controller:
- Once the installation is complete, click on the notification flag in Server Manager.
- Select "Promote this server to a domain controller."
- Choose "Add a new forest" and enter your desired root domain name (e.g.,
example.local
). - Set the Directory Services Restore Mode (DSRM) password.
-
Complete the Promotion:
- Follow the prompts and restart the server to complete the domain controller setup.
Step 3: Configure DNS
Active Directory requires DNS for domain functionality.
-
Access DNS Manager:
- Open Server Manager and navigate to "Tools" > "DNS."
-
Check Forward Lookup Zones:
- Ensure that your new domain appears in the Forward Lookup Zones.
-
Configure DNS Settings on Windows 10 Client:
- Go to the network settings of the Windows 10 client.
- Set the DNS server to the IP address of the Windows Server 2019 VM.
Step 4: Join Windows 10 Client to the Domain
Now that Active Directory is set up, you can join the Windows 10 client to the domain.
-
Open System Properties on the Windows 10 client:
- Right-click on "This PC," select "Properties."
- Click on "Change settings" next to the computer name.
-
Change Computer Name/Domain:
- In the System Properties window, click on "Change."
- Select "Domain" and enter your domain name (e.g.,
example.local
).
-
Enter Domain Credentials:
- When prompted, enter the credentials of a user with permission to join the domain (usually an Administrator).
-
Restart the Client:
- After successfully joining the domain, restart the Windows 10 client.
Step 5: Log into the Domain
After the restart, you can log into the domain.
-
On the Windows 10 login screen:
- Click on "Other user."
- Enter your domain credentials (e.g.,
DOMAIN\username
).
-
Verify Access:
- Ensure you can log into the system and access resources as expected.
Conclusion
You have now successfully configured Active Directory on a Windows Server 2019 VM and joined a Windows 10 client to the domain. This setup is critical for managing a networked environment effectively. Next steps could include exploring user management, group policies, and additional Active Directory features to enhance your network's security and efficiency.