AD drive does not exist errors usually show up at the worst moment: a permissions audit script that worked on your admin workstation fails on a jump server, in a scheduled task or in PowerShell 7 with “Cannot find drive. A drive with the name ‘AD’ does not exist.” The command is almost always Get-Acl or Set-Acl against an AD:\ path. The cause is rarely Active Directory itself. In most cases the ActiveDirectory module was never loaded, or it loaded without creating its drive. This guide walks through every cause, the exact PowerShell to confirm it, and the fix.
What the AD Drive Does Not Exist Error Means
The AD: drive is not a real disk. It is a PowerShell drive created by the ActiveDirectory provider, which ships inside the ActiveDirectory module (part of RSAT). When the module is imported and can find a domain controller, it mounts a default drive named AD rooted at //RootDSE/. Cmdlets that work with paths, such as Get-Acl, Set-Acl, Get-Item and Set-Location, can then read directory objects through that drive.
When the drive is missing, PowerShell treats AD: like any unknown drive letter and throws a DriveNotFoundException. The full error looks like this:
Get-Acl : Cannot find drive. A drive with the name 'AD' does not exist.
+ CategoryInfo : ObjectNotFound: (AD:String) [Get-Acl], DriveNotFoundException
+ FullyQualifiedErrorId : DriveNotFound,Microsoft.PowerShell.Commands.GetAclCommandCode language: JavaScript (javascript)So the message “a drive with the name ‘AD’ does not exist” tells you one thing: in the current session there is no drive called AD. Your job is to find out why the provider did not create it.

Why the AD Drive Does Not Exist: Five Causes
- The module is installed but not imported. Module autoloading only fires when you run a command from the module.
Get-Aclbelongs to the core security module, so calling it with anAD:\path does not load ActiveDirectory. Microsoft’s about_Modules page states that commands which use PowerShell providers do not automatically import a module. - RSAT is not installed. On a workstation or member server without the Active Directory module for Windows PowerShell, there is no provider to create the drive, so the AD drive does not exist.
- No domain controller was found. The provider locates a DC when the module loads. On a machine that is not domain joined, or when Active Directory Web Services (ADWS, TCP 9389) on the DCs is unreachable, the module still imports but only shows a warning, and the drive is not created.
- ADPS_LoadDefaultDrive is set to 0. This environment variable tells the module to skip the default drive. Some scripts set it to speed up imports and never set it back.
- A new session or runspace. Jobs,
Invoke-Command,ForEach-Object -Paralleland scheduled tasks start clean sessions. An import in your console does not carry over, so the AD drive does not exist there.
Step 1: Check That the ActiveDirectory Module Is Installed
Start with the simplest question. Run this in the same PowerShell host that fails:
Get-Module -Name ActiveDirectory -ListAvailable | Select-Object Name, Version, PathCode language: JavaScript (javascript)No output means the module is missing, which is exactly why the AD drive does not exist. Install it from an elevated prompt. On Windows 10 and Windows 11, RSAT is a Feature on Demand:
Add-WindowsCapability -Online -Name Rsat.ActiveDirectory.DS-LDS.Tools~~~~0.0.1.0Code language: CSS (css)On Windows Server, list the RSAT features and install the Active Directory module:
Get-WindowsFeature -Name RSAT-AD*
Install-WindowsFeature -Name RSAT-AD-PowerShellMicrosoft documents both methods on the Install Remote Server Administration Tools page. Our step-by-step guide to installing RSAT on Windows 11 covers offline installs and WSUS-managed clients that cannot reach Windows Update.
Step 2: Import-Module ActiveDirectory Before Using AD: Paths
This is the fix for most cases where the AD drive does not exist. Load the module explicitly before the first Get-Acl AD: path:
Import-Module ActiveDirectory -ErrorAction Stop
$dn = 'CN=Users,DC=contoso,DC=com'
$acl = Get-Acl -Path "AD:\$dn"
$acl.Access | Select-Object IdentityReference, ActiveDirectoryRights, AccessControlTypeCode language: PHP (php)Put Import-Module ActiveDirectory at the top of every script that touches AD:, even if it “works on my machine”. In your own console, an earlier Get-ADUser may have autoloaded the module. In a scheduled task or a fresh session it has not. Alternatively, add #Requires -Modules ActiveDirectory as the first line, which makes PowerShell load the module before the script runs.
If $PSModuleAutoLoadingPreference is set to None in a profile, nothing loads automatically, so the explicit import matters even more.
Step 3: Confirm the AD Drive Was Actually Created
A successful import does not guarantee a drive. Check both the provider and the drive:
Get-PSProvider -PSProvider ActiveDirectory
Get-PSDrive -Name AD -ErrorAction SilentlyContinueIf the provider exists but Get-PSDrive returns nothing, the AD drive does not exist because the module skipped it or could not find a DC. Look back at the import for a yellow warning about initializing the default drive. Then check the environment variable that controls it:
$Env:ADPS_LoadDefaultDrive
[Environment]::GetEnvironmentVariable('ADPS_LoadDefaultDrive', 'Machine')
[Environment]::GetEnvironmentVariable('ADPS_LoadDefaultDrive', 'User')Code language: PHP (php)A value of 0 disables the default drive, as described in the archived AD PowerShell team blog. Clear it for the session and re-import the module:
Remove-Module ActiveDirectory -ErrorAction SilentlyContinue
Remove-Item Env:\ADPS_LoadDefaultDrive -ErrorAction SilentlyContinue
Import-Module ActiveDirectory
Get-PSDrive -Name ADIf the value was set at machine level (for example with SETX ADPS_LoadDefaultDrive 0 /M), remove it in System Properties > Environment Variables, otherwise every new session will start without the drive again.

Step 4: Map the AD Drive Manually With New-PSDrive
When the module loads but the AD drive does not exist because it cannot find a DC on its own, create the drive yourself and point it at a specific domain controller. First, test that ADWS answers:
Test-NetConnection -ComputerName dc01.contoso.com -Port 9389Code language: CSS (css)If TcpTestSucceeded is True, map the drive. Add -Credential when you run from a non-domain machine or need a different account:
New-PSDrive -Name AD -PSProvider ActiveDirectory -Root '//RootDSE/' -Server 'dc01.contoso.com'
# From a workgroup machine or with another account:
New-PSDrive -Name AD -PSProvider ActiveDirectory -Root '//RootDSE/' -Server 'dc01.contoso.com' -Credential (Get-Credential)Code language: PHP (php)A failed port test points to a firewall rule, a stopped Active Directory Web Services service on the DC, or name resolution. Fix that first. No drive mapping will work without ADWS, because the ActiveDirectory module talks to the DC through it.
PowerShell 7, Jobs and Remoting: Where the AD Drive Disappears
Microsoft lists the ActiveDirectory module as natively compatible with PowerShell 7 on Windows Server 1809 or later and Windows 10 1809 or later. On those systems the module loads in-process and the AD drive works as it does in Windows PowerShell 5.1.
On older systems, PowerShell 7 loads the module through the Windows PowerShell compatibility feature: the real module runs in a hidden Windows PowerShell 5.1 session named WinPSCompatSession, and your session only gets proxy functions. The provider and its drive live in that background session, so in your PowerShell 7 window the AD drive does not exist. Check how the module was loaded:
Get-Module ActiveDirectory | Select-Object Name, ModuleType, Path
Get-PSSession -Name WinPSCompatSession -ErrorAction SilentlyContinueCode language: JavaScript (javascript)If the path points into your temp folder or a WinPSCompatSession exists, run the ACL part of the script in powershell.exe (5.1) or on a newer management server.
The same rule applies to every new runspace. Import the module inside the script block:
Invoke-Command -ComputerName mgmt01 -ScriptBlock {
Import-Module ActiveDirectory
(Get-Acl 'AD:\OU=Servers,DC=contoso,DC=com').Access
}
$ous | ForEach-Object -Parallel {
Import-Module ActiveDirectory
Get-Acl -Path "AD:\$_"
} -ThrottleLimit 4Code language: PHP (php)Fallback: Read AD Permissions Without the AD: Drive
If you cannot install RSAT on the machine where the script runs and the AD drive does not exist there, you can still read an object’s security descriptor through ADSI. This needs only .NET and a domain-joined host:
$entry = [ADSI]'LDAP://CN=Users,DC=contoso,DC=com'
$entry.psbase.ObjectSecurity.Access |
Select-Object IdentityReference, ActiveDirectoryRights, AccessControlTypeCode language: PHP (php)On a domain controller, or any machine that already has the AD DS tools, the command-line tool dsacls gives a quick look as well: dsacls "CN=Users,DC=contoso,DC=com". Both show the same access control entries that Get-Acl AD:\... shows.
Verify the AD Drive Does Not Exist Error Is Fixed
Run these three checks in the exact host where the error appeared (same user, same PowerShell version, same task or job):
Get-PSDrive -Name AD
Test-Path -Path 'AD:\'
(Get-Acl -Path "AD:\$((Get-ADDomain).DistinguishedName)").Access |
Select-Object -First 5 IdentityReference, ActiveDirectoryRightsGet-PSDrive should list a drive named AD with the ActiveDirectory provider, Test-Path should return True, and Get-Acl should return entries instead of the DriveNotFound error.

How to Stop the AD Drive Does Not Exist Error Coming Back
- Start every AD script with
#Requires -Modules ActiveDirectoryor an explicitImport-Module ActiveDirectory -ErrorAction Stop. - Add a guard before the first AD path so the script fails with a clear message:
if (-not (Get-PSDrive -Name AD -ErrorAction SilentlyContinue)) { throw 'AD: drive missing' }. - Do not set
ADPS_LoadDefaultDriveat machine level. If a script needs a faster import, set it in$Env:for that session only. - Run scheduled tasks under a domain account on a domain-joined server, so the provider can find a DC.
- Standardize admin and automation hosts on Windows Server 2019 or later so PowerShell 7 loads the module natively.
Read more: Install-Module Not Working? Fix NuGet and TLS 1.2 Errors Fast
Read more: Remove old BitLocker Recovery Passwords from Active Directory
Read more: Trust Relationship Failed Between Workstation and Domain: 5 Proven Fixes
Why does Get-Acl say a drive with the name ‘AD’ does not exist?
The AD drive does not exist because the ActiveDirectory module is not loaded in that session, or it loaded without creating its drive. Get-Acl does not trigger module autoloading, so run Import-Module ActiveDirectory before using AD: paths.
How do I create the AD: drive manually?
Import the ActiveDirectory module, then run New-PSDrive -Name AD -PSProvider ActiveDirectory -Root ‘//RootDSE/’ -Server followed by a domain controller name. Add -Credential when you run from a non-domain machine.
What does ADPS_LoadDefaultDrive do?
It is an environment variable read by the ActiveDirectory module. When it is set to 0, the module imports without creating the default AD drive. Remove it and re-import the module to get the drive back.
Does the AD drive work in PowerShell 7?
Yes, on Windows Server 2019 and Windows 10 1809 or later, where the ActiveDirectory module loads natively. On older systems PowerShell 7 loads it through a Windows PowerShell compatibility session, and the AD drive does not exist in your PowerShell 7 session.
Can I read Active Directory permissions without RSAT?
Yes. On a domain-joined machine use ADSI, for example [ADSI] with an LDAP path and psbase.ObjectSecurity.Access. On domain controllers the dsacls command-line tool also works.
References
Microsoft Learn: about_Modules (module autoloading and providers)
Microsoft Learn: Install Remote Server Administration Tools
Microsoft Learn: PowerShell 7 module compatibility for Windows modules
Microsoft Learn: about_Windows_PowerShell_Compatibility
Microsoft Learn: ActiveDirectory module reference
Microsoft archive: Disable loading the default drive AD: during Import-Module
Scripting Blog: Playing with the AD: Drive for Fun and Profit





