Server Error in '/' Application.- error - But install works fine on localhost on my computer via Visual Studio Express 2005

Last post 08-23-2009 1:23 PM by lindatwinz. 2 replies.

Sort Posts:

  • Server Error in '/' Application.- error - But install works fine on localhost on my computer via Visual Studio Express 2005

    08-23-2009, 1:14 AM
    • Member
      point Member
    • lindatwinz
    • Member since 08-23-2009, 1:09 AM
    • Posts 2

    I installed the personal website on my localhost server and it works fine. But after installing on Doman.com hosting I got the following error message (below): Please help: 

     

    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: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)

    Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

    Exception Details: System.Data.SqlClient.SqlException: 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: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)

    Source Error:

    Line 194:			Using command As New SqlCommand("GetNonEmptyAlbums", connection)
    Line 195:				command.CommandType = CommandType.StoredProcedure
    Line 196:				connection.Open()
    Line 197:				Dim list As New Generic.List(Of Album)()
    Line 198:				Using reader As SqlDataReader = command.ExecuteReader

    Source File: D:\CustomerData\webspaces\webspace_00168320\wwwroot\lindamcgraw.com\App_Code\PhotoManager.vb    Line: 196

    Stack Trace:

    [SqlException (0x80131904): 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: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)]
       System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection) +4846887
       System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj) +194
       System.Data.SqlClient.TdsParser.Connect(ServerInfo serverInfo, SqlInternalConnectionTds connHandler, Boolean ignoreSniOpenTimeout, Int64 timerExpire, Boolean encrypt, Boolean trustServerCert, Boolean integratedSecurity, SqlConnection owningObject) +4860189
       System.Data.SqlClient.SqlInternalConnectionTds.AttemptOneLogin(ServerInfo serverInfo, String newPassword, Boolean ignoreSniOpenTimeout, Int64 timerExpire, SqlConnection owningObject) +90
       System.Data.SqlClient.SqlInternalConnectionTds.LoginNoFailover(String host, String newPassword, Boolean redirectedUserInstance, SqlConnection owningObject, SqlConnectionString connectionOptions, Int64 timerStart) +376
       System.Data.SqlClient.SqlInternalConnectionTds.OpenLoginEnlist(SqlConnection owningObject, SqlConnectionString connectionOptions, String newPassword, Boolean redirectedUserInstance) +221
       System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity identity, SqlConnectionString connectionOptions, Object providerInfo, String newPassword, SqlConnection owningObject, Boolean redirectedUserInstance) +189
       System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection owningConnection) +4861315
       System.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnection owningConnection, DbConnectionPool pool, DbConnectionOptions options) +31
       System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection owningObject) +433
       System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection owningObject) +66
       System.Data.ProviderBase.DbConnectionPool.GetConnection(DbConnection owningObject) +499
       System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection owningConnection) +65
       System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection outerConnection, DbConnectionFactory connectionFactory) +117
       System.Data.SqlClient.SqlConnection.Open() +122
       PhotoManager.GetRandomAlbumID() in D:\CustomerData\webspaces\webspace_00168320\wwwroot\lindamcgraw.com\App_Code\PhotoManager.vb:196
       PhotoManager.GetPhotos() in D:\CustomerData\webspaces\webspace_00168320\wwwroot\lindamcgraw.com\App_Code\PhotoManager.vb:93
    
    [TargetInvocationException: Exception has been thrown by the target of an invocation.]
       System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner) +0
       System.RuntimeMethodHandle.InvokeMethodFast(Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner) +71
       System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks) +350
       System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) +29
       System.Web.UI.WebControls.ObjectDataSourceView.InvokeMethod(ObjectDataSourceMethod method, Boolean disposeInstance, Object& instance) +488
       System.Web.UI.WebControls.ObjectDataSourceView.ExecuteSelect(DataSourceSelectArguments arguments) +1247
       System.Web.UI.DataSourceView.Select(DataSourceSelectArguments arguments, DataSourceViewSelectCallback callback) +19
       System.Web.UI.WebControls.DataBoundControl.PerformSelect() +142
       System.Web.UI.WebControls.BaseDataBoundControl.DataBind() +73
       System.Web.UI.WebControls.FormView.DataBind() +4
       System.Web.UI.WebControls.BaseDataBoundControl.EnsureDataBound() +82
       System.Web.UI.WebControls.FormView.EnsureDataBound() +166
       System.Web.UI.WebControls.CompositeDataBoundControl.CreateChildControls() +72
       System.Web.UI.Control.EnsureChildControls() +87
       System.Web.UI.Control.PreRenderRecursiveInternal() +44
       System.Web.UI.Control.PreRenderRecursiveInternal() +171
       System.Web.UI.Control.PreRenderRecursiveInternal() +171
       System.Web.UI.Control.PreRenderRecursiveInternal() +171
       System.Web.UI.Control.PreRenderRecursiveInternal() +171
       System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +842
    


  • Re: Server Error in '/' Application.- error - But install works fine on localhost on my computer via Visual Studio Express 2005

    08-23-2009, 4:55 AM
    • Participant
      1,040 point Participant
    • junaid_arif
    • Member since 05-22-2008, 5:18 AM
    • Islamabad
    • Posts 193

    Have you adjusted the connection string for the new environment ? This is important please check

    Regards,

    Junaid Arif
    Software Engineer
    Specializing In Microsoft Solutions
  • Re: Server Error in '/' Application.- error - But install works fine on localhost on my computer via Visual Studio Express 2005

    08-23-2009, 1:23 PM
    • Member
      point Member
    • lindatwinz
    • Member since 08-23-2009, 1:09 AM
    • Posts 2

    I am not sure how to do that for my host Domain.com.

    Domain.com allows MS SQL 2000 and asp.net

    I was trying to configure it to use the personal.mdf which I copied to the app_data folder within the domain's folder.

    This is how the script configured the web.conf file on my local host using Visual Studio 2005:

    <configuration>connectionStrings>add name="Personal" connectionString="Data Source=.\SQLExpress;Integrated Security=True;User Instance=True;AttachDBFilename=|DataDirectory|Personal.mdf" providerName="System.Data.SqlClient" />remove name="LocalSqlServer"/>add name="LocalSqlServer" connectionString="Data Source=.\SQLExpress;Integrated Security=True;User Instance=True;AttachDBFilename=|DataDirectory|aspnetdb.mdf" />connectionStrings>

    How do I convert to Domain.com enviroment?

    Please advise.  

     

Page 1 of 1 (3 items)