English 中文(简体)
主动名录业务例外——业务错误(0x80072020)
原标题:Active Directory COM Exception - An operations error occurred (0x80072020)

我正在获得一个间歇性特约“。 在我使用<

我的守则是:

PrincipalContext ctx = new PrincipalContext(ContextType.Domain, Environment.UserDomainName);
GroupPrincipal groupPrincipal = GroupPrincipal.FindByIdentity(ctx, IdentityType.Name, "Group to find");

我是例外:

Inner Exception: System.Runtime.InteropServices.COMException (0x80072020): An operations error occurred.
  at System.DirectoryServices.DirectoryEntry.Bind(Boolean throwIfFail)
  at System.DirectoryServices.DirectoryEntry.Bind()
  at System.DirectoryServices.DirectoryEntry.get_AdsObject()
  at System.DirectoryServices.PropertyValueCollection.PopulateList()
  at System.DirectoryServices.PropertyValueCollection..ctor(DirectoryEntry entry, String propertyName)
  at System.DirectoryServices.PropertyCollection.get_Item(String propertyName)
  at System.DirectoryServices.AccountManagement.PrincipalContext.DoLDAPDirectoryInitNoContainer()
  at System.DirectoryServices.AccountManagement.PrincipalContext.DoDomainInit()
  at System.DirectoryServices.AccountManagement.PrincipalContext.Initialize()
  at System.DirectoryServices.AccountManagement.PrincipalContext.get_QueryCtx()
  at System.DirectoryServices.AccountManagement.Principal.FindByIdentityWithTypeHelper(PrincipalContext context, Type principalType, Nullable`1 identityType, String identityValue, DateTime refDate)
  at System.DirectoryServices.AccountManagement.Principal.FindByIdentityWithType(PrincipalContext context, Type principalType, IdentityType identityType, String identityValue)
  at System.DirectoryServices.AccountManagement.GroupPrincipal.FindByIdentity(PrincipalContext context, IdentityType identityType, String identityValue)

守则从开始。 视窗服务,,2003 SP2服务器

I have found another Stack Overflow question, Active Directory, enumerating user s groups, COM exception, suggesting that enabling Kerberos as an option in the PrincipalContext constructor will fix this problem but I am receiving a different hex code than in this question.

www.un.org/Depts/DGACM/index_spanish.htm 我的问题是:

  1. Is this particular COM Exception definitely an authentication issue? I need to be sure that this will 100% fix the problem before releasing the software.
  2. Is there a resource somewhere which lists all the possible COM exception hex codes so that I can help myself a bit better in the future?
最佳回答

现在,我找到另一个答案:https://stackoverflow.com/questions/1504487/unable-to-add-user-with-crmservice-api-in-dynamics-crm>。 无法在CRM中增加使用Crmservice AP的用户,该数据表明0-x80072020确实是一个许可问题。 我改变了服务,把我的工作放在一个领域账户,而不是地方系统账户,这似乎解决了我的问题。

问题回答

我在协会中就发生了这种情况。 NET(Windows 2008 R2 /IIS7),我用网络对这个错误进行敲响。 其根本原因是,应用程序库作为DefaultAppPool运行,一旦我改名为网络服务,它就开始再次工作。 我不理解为什么会发生改变,但这样做。

I had the same problem. I got success after changing the application pool as below: Process model load user profile = true

在我的案件中,网络后备库是“DefaultAppPool”,无法与公司积极名录连接。 因此,我只字不提一个我手法中可以诉诸反倾销的账户,所有东西都做了罚款。

对我来说,我也遇到了同样的问题,即试图向一名域名控制员登记,我有2名域名控制员,其中1名正在工作,而另一人正在工作,我认为,这与用户形象有关,仍在调查......。





相关问题
Anyone feel like passing it forward?

I m the only developer in my company, and am getting along well as an autodidact, but I know I m missing out on the education one gets from working with and having code reviewed by more senior devs. ...

NSArray s, Primitive types and Boxing Oh My!

I m pretty new to the Objective-C world and I have a long history with .net/C# so naturally I m inclined to use my C# wits. Now here s the question: I feel really inclined to create some type of ...

C# Marshal / Pinvoke CBitmap?

I cannot figure out how to marshal a C++ CBitmap to a C# Bitmap or Image class. My import looks like this: [DllImport(@"test.dll", CharSet = CharSet.Unicode)] public static extern IntPtr ...

How to Use Ghostscript DLL to convert PDF to PDF/A

How to user GhostScript DLL to convert PDF to PDF/A. I know I kind of have to call the exported function of gsdll32.dll whose name is gsapi_init_with_args, but how do i pass the right arguments? BTW, ...

Linqy no matchy

Maybe it s something I m doing wrong. I m just learning Linq because I m bored. And so far so good. I made a little program and it basically just outputs all matches (foreach) into a label control. ...