我尝试发现服务端点.../XRMServices/2011/Organization.svc
,我发现了这个错误:
发生错误。
再次尝试此操作。如果问题仍然存在,请检查Microsoft Dynamics CRM社区以获取解决方案,或与您组织的Microsoft Dynamics CRM管理员联系。最后,您可以联系Microsoft支持。System.NullReferenceException:未将对象引用设置为对象的实例。在Microsoft.Crm.MainApplication.Application_Error(Object sender,EventArgs eventArguments)
Error Description:
Generic SQL error.
Error Details:
Generic SQL error.
Full Stack:
[SqlException: Cannot open database "ASPState" requested by the login. The login failed.
Login failed for user 'NT AUTHORITY\NETWORK SERVICE'.]
at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)
at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning()
at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)
at System.Data.SqlClient.SqlInternalConnectionTds.CompleteLogin(Boolean enlistOK)
at System.Data.SqlClient.SqlInternalConnectionTds.LoginNoFailover(ServerInfo serverInfo, String newPassword, Boolean redirectedUserInstance, SqlConnection owningObject, SqlConnectionString connectionOptions, TimeoutTimer timeout)
at System.Data.SqlClient.SqlInternalConnectionTds.OpenLoginEnlist(SqlConnection owningObject, TimeoutTimer timeout, SqlConnectionString connectionOptions, String newPassword, Boolean redirectedUserInstance)
at System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, Object providerInfo, String newPassword, SqlConnection owningObject, Boolean redirectedUserInstance)
at System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection)
at System.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnection owningConnection, DbConnectionPool pool, DbConnectionOptions options)
at System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject)
at System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject)
at System.Data.ProviderBase.DbConnectionPool.GetConnection(DbConnection owningObject)
at System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection)
at System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory)
at System.Data.SqlClient.SqlConnection.Open()
at System.Web.SessionState.SqlSessionStateStore.SqlStateConnection..ctor(SqlPartitionInfo sqlPartitionInfo, TimeSpan retryInterval)
[HttpException: Unable to connect to SQL Server session database.]
at System.Web.SessionState.SqlSessionStateStore.ThrowSqlConnectionException(SqlConnection conn, Exception e)
at System.Web.SessionState.SqlSessionStateStore.SqlStateConnection..ctor(SqlPartitionInfo sqlPartitionInfo, TimeSpan retryInterval)
at System.Web.SessionState.SqlSessionStateStore.GetConnection(String id, Boolean& usePooling)
at System.Web.SessionState.SqlSessionStateStore.DoGet(HttpContext context, String id, Boolean getExclusive, Boolean& locked, TimeSpan& lockAge, Object& lockId, SessionStateActions& actionFlags)
at System.Web.SessionState.SqlSessionStateStore.GetItemExclusive(HttpContext context, String id, Boolean& locked, TimeSpan& lockAge, Object& lockId, SessionStateActions& actionFlags)
at System.Web.SessionState.SessionStateModule.GetSessionStateItem()
at System.Web.SessionState.SessionStateModule.BeginAcquireState(Object source, EventArgs e, AsyncCallback cb, Object extraData)
at System.Web.HttpApplication.AsyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)
可能导致问题的是什么,CRM有什么问题?
答案 0 :(得分:2)
由于您使用的是NETWORK SERVICE,因此需要确保将Web服务器的计算机帐户添加到Active Directory中的SQLAccessGroup。通常,这是在CRM设置期间为您完成的,但如果您想稍后更改帐户,则必须记住手动将新帐户添加到该组。以下链接描述了CRM使用的不同组:
http://ayazahmad.wordpress.com/2007/01/26/active-directory-security-groups-for-mscrm/
答案 1 :(得分:0)
当用户没有分配角色时,我看到了类似的消息,但是在测试环境中发生了这种消息,仍然值得检查。
答案 2 :(得分:0)
我完全重新安装了开发堆栈,同样的事情再次发生,我重新安装了我的虚拟机并且它运行起来,似乎是一些未知的问题。现在,我将尝试在虚拟机的新实例上重现相同的错误。
感谢所有人)
答案 3 :(得分:0)
我在CRM服务器上也看到了这条消息。我所做的就是在IIS上启用和禁用匿名身份验证,这对我有用。此外,我已经使用了web.config,服务设置,但后来我在第一次安装CRM时得到了那个部分。
在我的观点中,IIS没有告诉WCF如何进行身份验证,以及几次冷重启,以及启用和禁用匿名身份验证。唤醒WCF。
答案 4 :(得分:0)
您的AppPool必须是可以访问数据库的用户。
关于WCF服务, 检查您的IIS网站身份验证设置,以获取所需的WCF服务
用于在AD环境中运行的内部部署安装。 我们也遇到了这个问题,并在重新启动IIS后解决了问题。