среда, 12 января 2011 г.

При открытии вновь созданного приложения возникает “Ошибка доступа к БД конфигурации”

Конфигурация. Учетная запись spsfrm используется службами ферми. Учетная запись spsdeploy используется для выполнения работ по развертыванию. Учетная запись spssrv используется для запуска пула приложений рабочего веб-приложения. После создания данного приложения и попытки его открыть выводится ошибка “Ошибка доступа к БД конфигурации”.

В журнале SharePoint ошибка описана так:

01/12/2011 11:22:56.51     w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Database                          880i    High        System.Data.SqlClient.SqlException: Login failed for user 'domain\spssrv'.     в System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)     в System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj)     в System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)     в System.Data.SqlClient.SqlInternalConnectionTds.CompleteLogin(Boolean enlistOK)     в System.Data.SqlClient.SqlInternalConnectionTds.AttemptOneLogin(ServerInfo serverInfo, String newPassword, Boolean ignoreSniOpenTimeout, Int64 timerExpire, SqlConnection owningObject)     в System.Data.SqlClient.SqlInternalConnectionTds.LoginNoFail...    
01/12/2011 11:22:56.51*    w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Database                          880i    High        ...over(String host, String newPassword, Boolean redirectedUserInstance, SqlConnection owningObject, SqlConnectionString connectionOptions, Int64 timerStart)     в System.Data.SqlClient.SqlInternalConnectionTds.OpenLoginEnlist(SqlConnection owningObject, SqlConnectionString connectionOptions, String newPassword, Boolean redirectedUserInstance)     в System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, Object providerInfo, String newPassword, SqlConnection owningObject, Boolean redirectedUserInstance)     в System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection)     в System.Data.ProviderBase.DbConnectionF...    
01/12/2011 11:22:56.51*    w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Database                          880i    High        ...actory.CreatePooledConnection(DbConnection owningConnection, DbConnectionPool pool, DbConnectionOptions options)     в System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject)     в System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject)     в System.Data.ProviderBase.DbConnectionPool.GetConnection(DbConnection owningObject)     в System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection)     в System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory)     в System.Data.SqlClient.SqlConnection.Open()     в Microsoft.SharePoint.Utilities.SqlSession.OpenConnection()    
01/12/2011 11:22:56.51     w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Database                          880k    High           в Microsoft.SharePoint.Utilities.SqlSession.ExecuteReader(SqlCommand command, CommandBehavior behavior, SqlQueryData monitoringData, Boolean retryForDeadLock)     в Microsoft.SharePoint.Utilities.SqlSession.ExecuteReader(SqlCommand command, Boolean retryForDeadLock)     в Microsoft.SharePoint.Utilities.SqlSession.ExecuteReader(SqlCommand command)     в Microsoft.SharePoint.Upgrade.SPDatabaseSequence.GetVersion(SPDatabase database, Guid id, Version defaultVersion, SqlSession session, SPDatabaseSequence sequence)     в Microsoft.SharePoint.Upgrade.SPDatabaseWssSequence.get_BuildVersion()     в Microsoft.SharePoint.Upgrade.SPSequence.get_CanUpgrade()     в Microsoft.SharePoint.Upgrade.SPUpgradeSession.CanUpgrade(Object o)     в Microsoft.SharePoint.Administration.SPPersistedUpgradableObjec...    
01/12/2011 11:22:56.51*    w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Database                          880k    High        ...t.get_CanUpgrade()     в Microsoft.SharePoint.Upgrade.SPUpgradeSession.ReflexiveCanUpgrade(Object o)     в Microsoft.SharePoint.Upgrade.SPUpgradeSession.NeedsUpgrade(Object o, Boolean bRecurse)     в Microsoft.SharePoint.Administration.SPPersistedUpgradableObject.get_NeedsUpgrade()     в Microsoft.SharePoint.Administration.SPPersistedUpgradableObject.ValidateBackwardsCompatibility()     в Microsoft.SharePoint.Administration.SPConfigurationDatabase.Initialize(SqlConnectionStringBuilder connectionString, Boolean enableCaching, Boolean checkCompatibility, Boolean bindRequestGuid)     в Microsoft.SharePoint.Administration.SPConfigurationDatabase.Initialize(SqlConnectionStringBuilder connectionString, Boolean enableCaching, Boolean checkCompatibility)     в Microsoft.SharePoint.Administration.S...    
01/12/2011 11:22:56.51*    w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Database                          880k    High        ...PConfigurationDatabase.get_Local()     в Microsoft.SharePoint.Administration.SPFarm.FindLocal(SPFarm& farm, Boolean& isJoined)     в Microsoft.SharePoint.ApplicationRuntime.SPRequestModule.EnsureInitialize(HttpRequest request)     в Microsoft.SharePoint.ApplicationRuntime.SPRequestModule.BeginRequestHandler(Object oSender, EventArgs ea)     в System.Web.HttpApplication.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()     в System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)     в System.Web.HttpApplication.PipelineStepManager.ResumeSteps(Exception error)     в System.Web.HttpApplication.BeginProcessRequestNotification(HttpContext context, AsyncCallback cb)     в System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7W...    
01/12/2011 11:22:56.51*    w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Database                          880k    High        ...orkerRequest wr, HttpContext context)     в System.Web.Hosting.PipelineRuntime.ProcessRequestNotificationHelper(IntPtr managedHttpContext, IntPtr nativeRequestContext, IntPtr moduleData, Int32 flags)     в System.Web.Hosting.PipelineRuntime.ProcessRequestNotification(IntPtr managedHttpContext, IntPtr nativeRequestContext, IntPtr moduleData, Int32 flags)      
01/12/2011 11:22:56.51     w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Database                          880j    High        SqlError: 'Login failed for user 'domain\spssrv'.'    Source: '.Net SqlClient Data Provider' Number: 18456 State: 1 Class: 14 Procedure: '' LineNumber: 65536 Server: '192.168.10.15'    
01/12/2011 11:22:56.51     w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Database                          3351    Critical    SQL database login for 'SharePoint_Config' on instance '192.168.10.15' failed. Additional error information from SQL Server is included below.  Login failed for user 'domain\spssrv'.    
01/12/2011 11:22:56.51     w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Database                          tzku    High        ConnectionString: 'Data Source=192.168.10.15;Initial Catalog=SharePoint_Config;Integrated Security=True;Enlist=False;Asynchronous Processing=False;Connect Timeout=15'    ConnectionState: Closed ConnectionTimeout: 15    
01/12/2011 11:22:56.51     w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Upgrade                           fbv7    Unexpected    [w3wp] [SPUpgradeSession] [ERROR] [12.01.2011 11:22:56]: CanUpgrade [SPConfigurationDatabase] failed.    
01/12/2011 11:22:56.51     w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Upgrade                           fbv7    Unexpected    [w3wp] [SPUpgradeSession] [ERROR] [12.01.2011 11:22:56]: Exception: Login failed for user 'domain\spssrv'.    
01/12/2011 11:22:56.51     w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Upgrade                           fbv7    Unexpected    [w3wp] [SPUpgradeSession] [ERROR] [12.01.2011 11:22:56]:    в System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)     в System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj)     в System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)     в System.Data.SqlClient.SqlInternalConnectionTds.CompleteLogin(Boolean enlistOK)     в System.Data.SqlClient.SqlInternalConnectionTds.AttemptOneLogin(ServerInfo serverInfo, String newPassword, Boolean ignoreSniOpenTimeout, Int64 timerExpire, SqlConnection owningObject)     в System.Data.SqlClient.SqlInternalConnectionTds.LoginNoFailover(String host,...    
01/12/2011 11:22:56.51*    w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Upgrade                           fbv7    Unexpected    ... String newPassword, Boolean redirectedUserInstance, SqlConnection owningObject, SqlConnectionString connectionOptions, Int64 timerStart)     в System.Data.SqlClient.SqlInternalConnectionTds.OpenLoginEnlist(SqlConnection owningObject, SqlConnectionString connectionOptions, String newPassword, Boolean redirectedUserInstance)     в System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, Object providerInfo, String newPassword, SqlConnection owningObject, Boolean redirectedUserInstance)     в System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection)     в System.Data.ProviderBase.DbConnectionFactory.CreatePool...    
01/12/2011 11:22:56.51*    w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Upgrade                           fbv7    Unexpected    ...edConnection(DbConnection owningConnection, DbConnectionPool pool, DbConnectionOptions options)     в System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject)     в System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject)     в System.Data.ProviderBase.DbConnectionPool.GetConnection(DbConnection owningObject)     в System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection)     в System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory)     в System.Data.SqlClient.SqlConnection.Open()     в Microsoft.SharePoint.Utilities.SqlSession.OpenConnection()     в Microsoft.SharePoint.Utilities.SqlSession.ExecuteReader(SqlCommand command, CommandB...    
01/12/2011 11:22:56.51*    w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Upgrade                           fbv7    Unexpected    ...ehavior behavior, SqlQueryData monitoringData, Boolean retryForDeadLock)     в Microsoft.SharePoint.Utilities.SqlSession.ExecuteReader(SqlCommand command, Boolean retryForDeadLock)     в Microsoft.SharePoint.Utilities.SqlSession.ExecuteReader(SqlCommand command)     в Microsoft.SharePoint.Upgrade.SPDatabaseSequence.GetVersion(SPDatabase database, Guid id, Version defaultVersion, SqlSession session, SPDatabaseSequence sequence)     в Microsoft.SharePoint.Upgrade.SPDatabaseWssSequence.get_BuildVersion()     в Microsoft.SharePoint.Upgrade.SPSequence.get_CanUpgrade()     в Microsoft.SharePoint.Upgrade.SPUpgradeSession.CanUpgrade(Object o)    
01/12/2011 11:22:56.51     w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Upgrade                           fbv7    Medium      [w3wp] [SPUpgradeSession] [DEBUG] [12.01.2011 11:22:56]: Cannot upgrade [SPConfigurationDatabase].    
01/12/2011 11:22:56.51     w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Upgrade                           fbv7    Medium      [w3wp] [SPUpgradeSession] [DEBUG] [12.01.2011 11:22:56]: Skip [SPConfigurationDatabase] NeedsUpgrade.    
01/12/2011 11:22:56.51     w3wp.exe (0x1D64)                           0x1D90    SharePoint Foundation             Database                          tzku    High        ConnectionString: 'Data Source=192.168.10.15;Initial Catalog=SharePoint_Config;Integrated Security=True;Enlist=False;Asynchronous Processing=False;Connect Timeout=15'    ConnectionState: Closed ConnectionTimeout: 15    

Как и указано в technet, Учетная запись spssrv имеет права на базу данных конфигурации в роли WSS_Content_Application_Pools:

image

а на базу данных содержимого в роли dbowner:

image

Оказывается, в дополнение к требуемым полномочиям учетной записи, описанным в technet, необходимо еще предоставить учетной записи роль сервера public:

image

После этого приложение сразу начинает работать.

Комментариев нет:

Отправить комментарий