This project has moved. For the latest updates, please go here.

Unexpected error in Augment

Jan 16 at 10:32 AM
Edited Jan 17 at 9:10 AM
The augmentation doesn't work all the time on our SharePoint 2013 farm.
  • When it doesn't work some users it works for others (random)
  • It's not frontend specific
Can you help us out?

01/16/2017 09:35:48.16 w3wp.exe (0x16BC) 0x1580 LDAPCP Augmentation 1337 Unexpected [LDAPCP] Unexpected error in Augment: System.Runtime.InteropServices.COMException: Creating an instance of the COM component with CLSID {080D0D78-F421-11D0-A36E-00C04FB950DC} from the IClassFactory failed due to the following error: 800401e4 Invalid syntax (Exception from HRESULT: 0x800401E4 (MK_E_SYNTAX))., Callstack: at System.DirectoryServices.ActiveDirectory.DirectoryEntryManager..ctor(DirectoryContext context) at System.DirectoryServices.ActiveDirectory.Domain.GetDomain(DirectoryContext context) at ldapcp.LDAPCP.GetLDAPServers(RequestInformation requestInfo) at ldapcp.LDAPCP.<>c__DisplayClass46_0.<Augment>b__0() 7d89cb9d-dda2-00a4-8c3b-ea323180c760
Coordinator
Jan 17 at 3:10 PM
Interesting, can you please give me more insight:
  • Does this error occur only during augmentation?
  • Can you confirm you use the default LDAP connection?
  • Do you have other custom LDAP connections?
  • Does it always fail for the same users?
  • If error occurs, will it continue to occur for everyone until you recycle the pool, or does it resolve on its own?
According to the callstack it fails at this instruction:
DirectoryEntry de = Domain.GetComputerDomain().GetDirectoryEntry();
Error itself is very unclear on what may cause it...
Jan 19 at 11:45 AM
Does this error occur only during augmentation?
Yes, did some searches on IClassFactory and syntax in the ULS logging, only shows up in augmentation.

Can you confirm you use the default LDAP connection
Yes
Current LDAP connections = Connect to SharePoint domain

Do you have other custom LDAP connections?
No

Does it always fail for the same users?
No quite random, but in the same small little pool of users (The SharePoint farm isn't officially live yet, but is ready except for the augmentation).

If error occurs, will it continue to occur for everyone until you recycle the pool, or does it resolve on its own?
I haven't seen it resolve by itself yet, it usually ends up with me disabling and enabling the recycling the AppPool.
Coordinator
Jan 19 at 12:36 PM
Hmm, it's interesting that it fails only with augmentation.
Augmentation happens only in the STS of SharePoint, which runs with the farm account, whereas all other requests made by LDAPCP run in the w3wp of the site.
So I wonder if there could be something special with your farm account that could cause this...
Can you confirm you use a different account for the application pool of the sites?
If so, could you maybe try to create a test web app that runs with the farm account, and see if you can repro during search in people picker?
Feb 14 at 10:51 AM
Our STS is running on the farm account, our webapplication is running on it's own serviceaccount.
We have an acceptatie farm that has the same behaviour.
What exactly do I have to do in the peoplepickler to have a chance at reproducing the error?
Coordinator
Feb 21 at 7:12 AM
It looks like it is somehow related to the farm account, because you repro only during augmentation (people picker calls the same method but as the application pool account).
Do you repro the issue if you run the same code in PowerShell as the farm account:
[System.DirectoryServices.ActiveDirectory.Domain]::GetComputerDomain().GetDirectoryEntry()