AD management with PowerShell – preparation
A PowerShell module includes assemblies, scripts, and functionalities. In order to use the functionalities, we need to import the module. After that, we can call for the contents of the module to manage relevant server roles, services, or features.
Before we start Active Directory management with PowerShell, first we need to import the ActiveDirectory
module.
There are a few ways to do this. These include installing the AD DS server role or by installing Remote Server Administration Tools (RSAT):
- AD DS server role:
- If we install the AD DS server role using Server Manager, the Active Directory module for Windows PowerShell is installed as a feature:
Figure 17.1: Active Directory module for Windows PowerShell feature
- If the AD DS role is installed using PowerShell, we need to include the management tools by using
-IncludeManagementTools
. Otherwise, by default, it will not...
- If we install the AD DS server role using Server Manager, the Active Directory module for Windows PowerShell is installed as a feature: