A network-related or instance-specific error occurred while establishing a connection to SQL Server. The server was not found or was not accessible. Verify that the instance name is correct and that SQL Server is configured to allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)   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 Microsoft.SharePoint.Utilities.SqlSession.OpenConnection()
   at Microsoft.SharePoint.Utilities.SqlSession.ExecuteReader(SqlCommand command, CommandBehavior behavior)
   at Microsoft.SharePoint.Administration.SPConfigurationDatabase.LookupSite(SPWebApplication application, String path, SiteDatabaseMapping& result)
   at Microsoft.SharePoint.SPSite.LookupInDatabase(SPWebApplication application, String serverRelativeUrl, SiteDatabaseMapping& result)
   at Microsoft.SharePoint.SPSite.LookupInCacheAndDatabase(SPWebApplication application, String rootUrl, SPVolatileCache`2 cache, SiteDatabaseMapping& result)
   at Microsoft.SharePoint.SPSite.Lookup(Uri requestUrl, SPWebApplication application, SiteDatabaseMapping& result, String& rootUrl)
   at Microsoft.SharePoint.SPSite..ctor(SPFarm farm, Uri requestUri, Boolean contextSite, SPUserToken userToken)
   at Microsoft.SharePoint.SPSite..ctor(SPFarm farm, Uri requestUri, Boolean contextSite)
   at Microsoft.SharePoint.WebControls.SPControl.SPWebEnsureSPControl(HttpContext context)
   at Microsoft.SharePoint.WebControls.SPControl.GetContextWeb(HttpContext context)
   at Microsoft.SharePoint.ApplicationRuntime.BaseApplication.Application_PreRequestHandlerExecute(Object sender, EventArgs e)
   at Microsoft.SharePoint.ApplicationRuntime.SPRequestModule.PreRequestExecuteAppHandler(Object oSender, EventArgs ea)
   at System.Web.HttpApplication.SyncEventExecutionStep.System.Web.HttpApplication.IExecutionStep.Execute()
   at System.Web.HttpApplication.ExecuteStep(IExecutionStep step, Boolean& completedSynchronously)