Summary: Learn how to avoid loading the default AD: drive when you load the Active Directory module for Windows PowerShell.
How can I avoid creating the default AD: drive when I import the Active Directory module for Windows PowerShell?
Use the ENV drive and set the ADPS_LoadDefaultDrive variable to 0. Add the following line to your Windows PowerShell profile to make the change “permanent.”
$Env:ADPS_LoadDefaultDrive = 0