繁体   English   中英

使用C#.net应用程序访问活动目录中的不同域在本地计算机上工作,但在IIS服务器中托管时不能

[英]Access to different domain in active directory using C# .net application works in local machine but not when hosted in IIS server

我正在使用C#Web应用程序在active directroy中搜索不同域中的用户。 在实际情况中,我们有来自两个不同领域的员工,例如:印度,美国。

当应用程序托管在IIS服务器中时,我无法从美国域中检索用户。 尝试连接到美国域时,出现以下错误:

> System.Runtime.InteropServices.COMException (0x8007203A): The server
> is not operational. at
> System.DirectoryServices.DirectoryEntry.Bind(Boolean throwIfFail) at
> System.DirectoryServices.DirectoryEntry.Bind() at
> System.DirectoryServices.DirectoryEntry.get_AdsObject() at
> System.DirectoryServices.DirectorySearcher.FindAll(Boolean
> findMoreThanOne) at
> System.DirectoryServices.DirectorySearcher.FindAll() at
> NovellADTest.AD.btnSyncTest_OnClick(Object sender, EventArgs e)

但是,如果我在本地计算机上运行该应用程序,它就会运行并从美国域中获取用户,但这在托管在服务器中时不起作用。

请帮我解决这个问题。

由于不同的情况可能会有问题。 尝试一下以下。

  1. 检查目录服务的权限是否不足。
  2. 它可能是证书错误。

以下链接有一个解决方案,但不确定..如果它适用于你..

http://forums.asp.net/t/1096070.aspx/1

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM