# Get-ADDomainController 

**URL:** <https://forums.powershell.org/t/get-addomaincontroller/3544>\
**Category:** PowerShell Help\
**Created:** [December 17, 2014, 8:28pm UTC](https://forums.powershell.org/t/get-addomaincontroller/3544 "2014-12-17T20:28:38Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![malik-amaduddin](https://avatars.discourse-cdn.com/v4/letter/m/f05b48/32.png) [@malik-amaduddin](https://forums.powershell.org/u/malik-amaduddin)\
**Post date:** [December 17, 2014, 8:28pm UTC](https://forums.powershell.org/t/get-addomaincontroller/3544/1 "2014-12-17T20:28:38Z")

</div>

I am running a simple command

Dunk\> Get-ADDomainController -Filter \*

But getting the error

Get-ADDomainController : Directory object not found  
At line:1 char:1

- Get-ADDomainController -Filter \*
- 

```auto
  + CategoryInfo : ObjectNotFound: (:) [Get-ADDomainController], ADIdentityNotFoundException
  + FullyQualifiedErrorId : ActiveDirectoryCmdlet:Microsoft.ActiveDirectory.Management.ADIdentityNotFoundException,Microsoft.A
 ctiveDirectory.Management.Commands.GetADDomainController

```

What can be the problem. I saw the same command being used in different KBs and Forums, without anyissues.

---

<div class="post-metadata">

**Author:** ![richard-siddaway](https://avatars.discourse-cdn.com/v4/letter/r/d78d45/32.png) [@richard-siddaway](https://forums.powershell.org/u/richard-siddaway)\
**Post date:** [December 17, 2014, 8:36pm UTC](https://forums.powershell.org/t/get-addomaincontroller/3544/2 "2014-12-17T20:36:39Z")

</div>

You have the AD cmdlets loaded obviously. What rights do you have in the domain and are you running PowerShell with elevated privileges? is the connection from your machine to the domain controller corrupted - use Test-ComputerSecureChannel on the machine you are using

---

<div class="post-metadata">

**Author:** ![malik-amaduddin](https://avatars.discourse-cdn.com/v4/letter/m/f05b48/32.png) [@malik-amaduddin](https://forums.powershell.org/u/malik-amaduddin)\
**Post date:** [December 21, 2014, 3:33pm UTC](https://forums.powershell.org/t/get-addomaincontroller/3544/3 "2014-12-21T15:33:00Z")

</div>

Sorry for the late reply.

1. If I use the Get-ADDomainController with the ‘-Server’ parameter. i am able to get the information of all the domain controllers. I believe that this would mean that I have the necessary permissions.

2. Test-ComputerSecureChannel returns the value True. And also if I run this computer with the name of the different Domain Controllers it is returning True.

It is very puzzling.

---

<div class="post-metadata">

**Author:** ![dotnVo](https://avatars.discourse-cdn.com/v4/letter/d/4af34b/32.png) [@dotnVo](https://forums.powershell.org/u/dotnVo)\
**Post date:** [May 16, 2024, 8:46pm UTC](https://forums.powershell.org/t/get-addomaincontroller/3544/4 "2024-05-16T20:46:37Z")

</div>


