Monday, January 23, 2012

WSS 3.0 Unable to Connect to Configuration Database

We have an SBS 2003 server with a WSS 3.0 SharePoint site configured on it. As part of preparation for a migration to SBS 2011, a whole bunch of updates have been applied to it. Unfortunately, one of these updates killed SharePoint.

It appears that the SharePoint databases were orginally part of  a server\SharePoint SQL instance but were migrated to MSSQL$Microsoft##SSEE. So, at some time the databases were migrated from the old SQL 2000-based windows Internal DB to SQL 2005 Express Edition. My best guess is that this was done by some of the updates.

There was an error:

SQL Database 'STS_Config' on SQL Server instance 'np:\\.\pipe\MSSQL$Microsoft##SSEE\sql\query' not found. Additional error information from SQL Server is included below.
Looking in the SQL error log at C:\WINDOWS\SYSMSI\SSEE\MSSQL.2005\MSSQL\LOG\Errorlog has further info:
Error: 17207, Severity: 16, State: 1.
FCB::Open: Operating system error 5(Access is denied.) occurred while creating or opening file 'C:\Program Files\Microsoft SQL Server\MSSQL$SHAREPOINT\Data\STS_Config.mdf
In SQL Server Management Studio Express for SQL 2005, I connected to the MSSQL$Microsoft##SSEE instance to see what was up. The SharePoint config database was not mounted and I couldn't view the properties of it. To connect to the MSSQL$Microsoft##SSEE instance, I had to enter the Server name in Management Studio as \\.\pipe\mssql$microsoft##ssee\sql\query.

After looking, I saw that the MSSQL$Microsoft##SSEE instance was configured to start as NETWORK SERVICE. The older instance of SHAREPOINT was configured to start as LOCAL SYSTEM. The error log was indicating that new instance didn't have the correct permissions. After changing MSSQL$Microsoft##SSEE to run a LOCAL SYSTEM, the permissions issue was resolved and the databases mounted.                                                                                                                                                   
Unfortunately when I tried to connect to SharePoint, I was still getting the error "Unable to connect to the configuration database. Looking at the SQL error log, we now see:
Error: 33002, Severity: 16, State: 1.
Access to module dbo.proc_getObjectsByClass is blocked because the signature is not valid.
It turns out this is caused by upgrades not completing properly. You need to manually force the upgrade to complete by using this command-line from C:\Program Files\Microsoft Shared\web server extensions\12\bin:
psconfig -cmd upgrade -inplace b2b -wait -force
For additional troubleshooting info:

1 comment: