-
PowerShell Tip – How to install Windows Server roles and features and see parent / child relations as results?
It is very simple… Install-WindowsFeature -Name AD-Domain-Services, DNS -IncludeManagementTools -OutVariable result -Verbose Get-WindowsFeature -Name $result.FeatureResult.Name Note: GUIs are not recommended for the server. Install only AD-Domain-Services, DNS and RSAT-AD-PowerShell on your Windows Server Core and RSAT on your management server. Display Name Name Install State ———— —- ————- [X] Active Directory Domain Services AD-Domain-Services Installed [X]…
-
PowerShell Tip – How to remove AD OU and all child objects (another OUs, users, groups, computers)?
How to remove Active Directory Organizational Unit with all child objects (another OUs, users, groups, computers)? It is simple. The trick is to use Remove-ADObject -Recursive. Get-ADOrganizationalUnit -Identity ‘OU=ToDelete,DC=ad,DC=fabrikam,DC=com’ | Set-ADOrganizationalUnit -ProtectedFromAccidentalDeletion:$false -PassThru | Remove-ADObject -Recursive -Confirm:$false
-
How to manage and configure BitLocker Drive Encryption – Group Policy and backup and restore to and from Active Directory
It is very simple to configure automatic backup of a recovery password in pure server environment. If you have clients then you will probably want to configure self-service portal to get recovery passwords (or at least delegation for Service Desk) but in server environment it is usually enough to use default configuration that only Domain…
-
If you create new Conditional Forwarder then you will need to restart Domain Controller or DNS service on PDC
My friends found interesting issue. If you create a conditional forwarder (and you do it on PDC) then conditional forwarder will work on all other DNS servers (Domain Controllers) except PDC. This behavior was tested on Windows Server 2008 R2 and Windows Server 2012 R2. The solution is to restart DNS service or whole PDC.
-
PowerShell advanced function (cmdlet) to get all Active Directory Sites and Subnets
I wrote a simple function to get all AD sites and subnets. Using this function it is possible to easily report all sites and for example find sites without subnets. If there is more then on subnet in a site then the output is multiple objects with the same site and different subnet. Every object…