简体   繁体   English

ASP.NET IIS服务器中的Localhost Vs服务器名称错误?

[英]Localhost Vs Server name error in asp.net IIS server?

I have webapplication which working on AD (database access too). 我有在AD(数据库访问也)上工作的web应用程序。 The site is working fine when I use http:// locahost:8081/clients.aspx, but if I use htt://servername.domain.com/clients.aspx is throwing exception for "Login failed for user 'NT AUTHORITY\\ANONYMOUS LOGON'" at 当我使用http:// locahost:8081 / clients.aspx时,该站点运行正常,但是如果我使用htt://servername.domain.com/clients.aspx,则会引发“用户'NT AUTHORITY \\登录失败匿名登录“”网址

Client = (From c In SAEntitties.Dim_Client
          Where C.Users.Any(Function(user) user.UserName = username)
          Select c).ToList()

How to handle this? 如何处理呢?

Update 更新资料

I disabled window authentication in IIS for Website. 我在用于网站的IIS中禁用了窗口身份验证。 Enabled Basic authentication. 启用Basic身份验证。 It is working fine. 一切正常。

Why Windows Authentication doesn't work? 为什么Windows身份验证不起作用?

I have not experience yet integration with AD, but just in case, I think that is a good shot. 我还没有与AD集成的经验,但以防万一,我认为这是一个不错的选择。

If you are using IIS 7.0 with Application Pools, you should try to change the original configuration of the pool you are using to NetworkService. 如果将IIS 7.0与应用程序池一起使用,则应尝试将要使用的池的原始配置更改为NetworkService。

To do so, choose Application Pools -> "YourPool" -> Advanced configurations Under Process Model, click Identity, and select NetworkServices within the dropdown. 为此,请选择“应用程序池”->“您的池”->“高级配置”。在“流程模型”下,单击“身份”,然后在下拉列表中选择NetworkServices。

Hope this helps. 希望这可以帮助。

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

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