the authentication endpoit username was not found on the configured secure token service

转载:http://luoyong0201.blog.163.com/blog/static/11293052015101395013914/

使用Developer Toolkit在Visual Studio中使用CRM Explorer链接到CRM的时候回报如下错误:The authentication endpoint Username was not found on the configured Secure Token Service! 可能在代码中链接CRM也会报这个错误,还有就是在Outlook客户端中使用CRM也会报错。很多文章都认为是要启动AD FS的 URL 路径为 /adfs/services/trust/13/username 的 终结点,我尝试了,没有解决我的问题。



你可能会在AD FS的日志中看到类似如下的错误信息,该错误的事件ID是 102:
启用联合身份验证服务的终结点时出错。请使用 PowerShell cmdlet 纠正配置错误,然后重新启动联合身份验证服务。 
其他数据 
异常详细信息: 
System.ServiceModel.AddressAlreadyInUseException: 已有针对 IP 终结点 0.0.0.0:808 的侦听器。如果有其他应用程序已在侦听此终结点,或者,如果在服务主机中具有多个服务终结点,这些终结点具有相同的 IP 终结点但绑定配置不兼容,则可能会发生这种情况。 ---> System.Net.Sockets.SocketException: 通常每个套接字地址(协议/网络地址/端口)只允许使用一次。
   在 System.Net.Sockets.Socket.DoBind(EndPoint endPointSnapshot, SocketAddress socketAddress)
   在 System.Net.Sockets.Socket.Bind(EndPoint localEP)
   在 System.ServiceModel.Channels.SocketConnectionListener.Listen()
   --- 内部异常堆栈跟踪的结尾 ---
   在 System.ServiceModel.Channels.SocketConnectionListener.Listen()
   在 System.ServiceModel.Channels.ExclusiveTcpTransportManager.OnOpen()
   在 System.ServiceModel.Channels.TransportManager.Open(TransportChannelListener channelListener)
   在 System.ServiceModel.Channels.TransportManagerContainer.Open(SelectTransportManagersCallback selectTransportManagerCallback)
   在 System.ServiceModel.Channels.TransportChannelListener.OnOpen(TimeSpan timeout)
   在 System.ServiceModel.Channels.ConnectionOrientedTransportChannelListener.OnOpen(TimeSpan timeout)
   在 System.ServiceModel.Channels.TcpChannelListener`2.OnOpen(TimeSpan timeout)
   在 System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan timeout)
   在 System.ServiceModel.Dispatcher.ChannelDispatcher.OnOpen(TimeSpan timeout)
   在 System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan timeout)
   在 System.ServiceModel.ServiceHostBase.OnOpen(TimeSpan timeout)
   在 System.ServiceModel.Channels.CommunicationObject.Open(TimeSpan timeout)
   在 Microsoft.IdentityServer.ServiceHost.STSService.StartSTSService(ServiceHostManager serviceHostManager, ServiceState serviceState)

这个我的前一篇文章  Dynamics CRM 2013 IFD部署之五 已经提到过了,重要的事情要说三遍。在前面我提到的文档(Configuring Claims-based Authentication for Microsoft Dynamics CRM Server)的 AD FS port conflict 章节也有说。当然,如果你的AD FS服务器和CRM服务器不是同一台则没有这个问题,这个问题官方说的原因是CRM的 Microsoft Dynamics CRM 沙盒处理服务 (英文是Sandbox Processing Service)侦听808端口,CRM的另外两个服务Microsoft Dynamics CRM Asynchronous Service 和 Web Application Server services 会通过808端口和它交互,而AD FS服务默认也是占用808端口,所以导致了端口冲突 。
解决办法很简单,使用管理员身份打开PowerShell,执行如下命令:Set-ADFSProperties –nettcpport 809 

找到名称为 Active Directory Federation Services 的服务,右击选择 重新启动 。

就可以了


再次申明:博客内容是转载微软CRM的MVP罗勇的

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值