Friday, August 1, 2008

Cannot connect to Config db

Error:
Cannot connect to the configuration database
or
Unable to connect to database. Check database connection information and make sure the database server is running

This is something everyone have seen in V2 and V3 days. And as the message itself says cannot connect .. means it all connectivity issue.

Reasons can be:

  • You recently applied Hotfix or Service Pack to your SQL Server and have not restarted the SQL Server.
  • The SQL database may not be running.
  • The account that is used by application pool does not have the required permissions to the SQL Server database.
  • Network connectivity has been lost between the SharePoint Server and the Microsoft SQL Server server.
Troubleshooting steps :

Verify that the SQL database is running
1. Click Start --> Run --> Type services.msc
2. In the list of services, locate the MSSQLSERVER service. This service may also be listed as MSSQL$SHAREPOINT.
3. Check the status of the service


Make sure that the account that is used by the application pool is the account that has the required permissions to the SQL Server database
First, you must first determine the application pool identity. To do this, follow these steps:
1. Click Start --> Run--> Type inetmgr
2. Double-click the Web Sites folder.
3. Right-click the virtual server that is running WSS and then click Properties.
4. Click Home Directory.
5. Note the information that is in the Application name box (this is the application pool name), and then click Cancel.
6. In the left pane, right-click Application Pools, and then click Properties.
7. Click the Identity tab.
8. Note the information that is in the Application pool identitypane, and then click Cancel.

Next, you must verify that this account has the required permission the SQL Server database.
1. Click Start, point to Programs, point to Microsoft SQL Server, and click Enterprise Manager.
2. In the left pane, double-click Microsoft SQL Servers, and then double-click your SQL server group.
3. Double-click your server.
4. Double-click Security.
5. In the left pane, click Logins.
6. In the right pane, double-click the user who you noted step 8 of the previous procedure.
7. In the SQL Server Login Properties dialog box, click Server Roles.
8. Click to select both the Security Administrators and the Database Creators check boxes, and then click Database Access.
9. Under the Permit column, click to select the Windows SharePoint Services database.
10. Click OK.

Make sure that you have network connectivity and correct name resolution between the servers
1. Verify that the Windows SharePoint Services server is using the correct IP address for the SQL server. To do this, run the ping command on the Windows SharePoint Services server.
2. Verify that the Windows SharePoint Services server is obtaining the correct IP address for the SQL server from DNS. To do this, run the nslookup command from the Windows SharePoint Services server.
3. Make sure that there are no incorrect entries for the SQL server. To do this, examine the Hosts file on the Windows SharePoint Services server. This file is in the following location:
%systemroot%\system32\drivers\etc\Hosts
4. On the Windows SharePoint Services server, look for SQL client aliases. To do this, follow these steps:
a. Click Start, click Run, and then type cliconfg in the Open box.
b. Click the Alias tab. By default, there are no SQL client aliases. If you have any aliases for the SQL server, verify that they are correct, or remove them.

0 comments: