Windows Servers Power Shell Warning Event Id 300

I have a mix of windows server 2012 and server 2008 R2 environment. All the servers are giving me the below error when importing Active Directory Module.

PS C:\Users\administrator.AIRWORK> Import-Module ActiveDirectory
Import-Module : The server was unable to process the request due to an internal error.  For more information about the
error, either turn on IncludeExceptionDetailInFaults (either from ServiceBehaviorAttribute or from the <serviceDebug>
configuration behavior) on the server in order to send the exception information back to the client, or turn on
tracing as per the Microsoft .NET Framework 3.0 SDK documentation and inspect the server trace logs.
At line:1 char:1
+ Import-Module ActiveDirectory
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (AD:PSDriveInfo) [Import-Module], ADException
    + FullyQualifiedErrorId : ADProvider:NewDrive:InvalidRoot:ADError,Microsoft.PowerShell.Commands.ImportModuleCommand

Event Viewer has a event id 300 logged. 

Provider Health: The server was unable to process the request due to an internal error.  For more information about the error, either turn on IncludeExceptionDetailInFaults (either from ServiceBehaviorAttribute or from the <serviceDebug> configuration behavior) on the server in order to send the exception information back to the client, or turn on tracing as per the Microsoft .NET Framework 3.0 SDK documentation and inspect the server trace logs.. 

Details: 
ProviderName=ActiveDirectory
ExceptionClass=ProviderInvocationException
ErrorCategory=NotSpecified
ErrorId=ADProvider:NewDrive:InvalidRoot:ADError
ErrorMessage=The server was unable to process the request due to an internal error.  For more information about the error, either turn on IncludeExceptionDetailInFaults (either from ServiceBehaviorAttribute or from the <serviceDebug> configuration behavior) on the server in order to send the exception information back to the client, or turn on tracing as per the Microsoft .NET Framework 3.0 SDK documentation and inspect the server trace logs.

Severity=Warning

SequenceNumber=10

HostName=ConsoleHost
HostVersion=2.0
HostId=acd85fa7-3591-4cd9-9d80-64646ec6558d
EngineVersion=2.0
RunspaceId=20e83fda-3687-4d66-8932-d95d264c3bc0
PipelineId=15
CommandName=
CommandType=
ScriptName=
CommandPath=
CommandLine=

What do i need to do to get this working. 

This was working pre Christmas and now its stopped working. Nothing as per client information has changed on the server.

Cheers

Taufeeq

January 29th, 2015 6:15am

Hi Taufeeq,

First I want to check if you ran the script on DC (Domain Controller) with Domain Admin?

For the error caused by AD module, Please try to follow these steps to troubleshoot the Active Directory Web Services:

1.  Locate the file "C:\Windows\ADWS\Microsoft.ActiveDirectory.WebServices.exe.config"

2.  Add a couple of debug keys in the <AppSettings> section of the config file allowed me to log the ADMGS error on the server and diagnose the real source of the error.

<add key="DebugLevel" value="Info" />
<add key="DebugLogFile" value="C:\Windows\Debugadws.log" />

3.  After set up debugging and restarted the Active Directory Web Service, then review the log file "C:\Windows\Debugadws.log".

For more detailed information, please refer to this article:

Diagnose Active Directory Management Gateway Service (ADMGS) Errors

If there is anything else regarding this issue, please feel free to post back.

If you have any feedback on our support, please click here.

Best Regards,

Anna Wang

TechNet Community Support

Free Windows Admin Tool Kit Click here and download it now
January 30th, 2015 10:32am

I would start by restarting the gateway server..  It looks like the web service is hung.  This can happen and has happened to me on occasion.

I have also found that the DNS servers can cause this.  Clear the cache and restart all DNS servers.

January 30th, 2015 11:18am

Hi There,

Thanks for the Feedback. 

Yes i was running the script as a admin on the domain. Two servers i was working with were my DIRSYNC (2012 Server) and Active Directory servers (Server 2008 R2).

After I carried out your steps above on the Domain Controller the issue has been resolved. It doesn't error out and also doesn't generate a Debugadws.log file as it doesn't fail now.

Will keep monitoring though.

Cheers

Taufeeq

Free Windows Admin Tool Kit Click here and download it now
February 1st, 2015 5:42pm

My first guess is that you want a folder path for the log file that is notin teh WIndows systemm folders.

User something like "c:\adwslogs\adws.log"

Be sure the network, local service and system have full write permissons.

February 1st, 2015 5:55pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics