locked
Problem Deploying to SQL Server 2000 Setup RRS feed

  • Question

  • User-1909038188 posted

    I have an SQL Server 2000 account with an ISP which allows me only one DB - I cannot create new DBs. I copied all the Club tables and SPs as well as all the "aspnet_.." tables to that DB and I modified the web.config to have a single connection string pointing to that DB but when I deploy my modified Club files to my web site I get the error shown below when I try to run the app?

    I also modified the membership provider to use my DB as shown here and I made sure that the App_Data directory is empty but it still seems to be looking for a local instance of SQL Server Express?

    ======= Membership Prover Code ===========

    <membership defaultProvider="GoodSamSiteMembershipProvider">

    <providers>

    <clear/>

    <add connectionStringName="GoodSamSiteDB"

    enablePasswordRetrieval="true"

    enablePasswordReset="true"

    requiresQuestionAndAnswer="true"

    requiresUniqueEmail="false"

    passwordFormat="Encrypted"

    applicationName="GoodSamSite"

    maxInvalidPasswordAttempts="5"

    minRequiredPasswordLength="7"

    minRequiredNonalphanumericCharacters="0"

    passwordAttemptWindow="10"

    passwordStrengthRegularExpression=""

    name="GoodSamSiteMembershipProvider"

    type="System.Web.Security.SqlMembershipProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/>

    </providers>

    </membership>

    Any ideas on what I missed here?

    ============= Error Message ================

    An error has occurred while establishing a connection to the server.  When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: SQL Network Interfaces, error: 26 - Error Locating Server/Instance Specified)

    SQLExpress database file auto-creation error:

    The connection string specifies a local Sql Server Express instance using a database location within the applications App_Data directory. The provider attempted to automatically create the application services database because the provider determined that the database does not exist. The following configuration requirements are necessary to successfully check for existence of the application services database and automatically create the application services database:

    Friday, January 27, 2006 10:19 AM

All replies

  • User1052258516 posted

    What does your connection string look like?

    - Will

    Friday, January 27, 2006 10:45 AM
  • User-1909038188 posted

    What does your connection string look like?

    - Will

    Thanks for the response. My connection string is:

    <add name="GoodSamSiteDB" connectionString="Data Source=mssql08.discountasp.net;Initial Catalog=DB_xxxxx;User ID=myID; Password=myPW" providerName="System.Data.SqlClient"/>

    I know the string works as I can access all the table in that DB with no problem

    Friday, January 27, 2006 11:30 AM
  • User838325616 posted
    I have a similar issue.  I changed four things:

    DataSet.xsd - Search for .mdf and removed reference to .mdf file.
    Changed ClubSiteDB to my connection string
    Changed reference for  membership defaultProvider in Web.config to connection string above
    Changed reference for roleManager in Web.config to connection string above

    and I still get the message that you are getting.  The strange thing is that I don't always get it.
    (No suggestions)
    Edit...
    Ignore all
    Add to dictionary
    MD
    Md
    MDT
    Md's
    Edit...
    Ignore all
    Add to dictionary
    MD
    Md
    MDT
    Md's
    Edit...
    Ignore all
    Add to dictionary
    (No suggestions)
    Edit...
    Ignore all
    Add to dictionary
    default Provider
    default-Provider
    Edit...
    Ignore all
    Add to dictionary
    (No suggestions)
    Edit...
    Ignore all
    Add to dictionary
    Changed
    Changes
    Change
    Hanged
    Charged
    Edit...
    Revert to "Chnaged"
    role Manager
    role-Manager
    rumormonger
    rumourmonger
    almanac
    Edit...
    Ignore all
    Add to dictionary
    (No suggestions)
    Edit...
    Ignore all
    Add to dictionary
    Friday, January 27, 2006 1:06 PM
  • User-1909038188 posted

    Daniel;

    Thanks for letting me know that it is not just me. Like you, one in a while, it works just fine? I sure hope someone has a solution.

    Friday, January 27, 2006 1:26 PM
  • User838325616 posted
    Hmmmmm....seams like the foumns does not like Google's spell check in Firefox.  That is what all that extra text is at the bottom of my last post.
    Friday, January 27, 2006 1:37 PM
  • User1052258516 posted

    You could try and put <clear/> as the first element in your <ConnectionStrings> element to clear out all the loaded connection strings.

    Other than that I don't really see anything wrong, unless your hosting provider does not let you override certain parts of the web.config like the membership providers.

    - Will

    Friday, January 27, 2006 5:17 PM
  • User-1909038188 posted

    You could try and put <clear/> as the first element in your <ConnectionStrings> element to clear out all the loaded connection strings.

    Other than that I don't really see anything wrong, unless your hosting provider does not let you override certain parts of the web.config like the membership providers.

    - Will

    Interesting suggestion. I did that and now I get the error below?I'm confused as to why my machine.config is coming into play here? What if a user doesn't even have Framework 2.0 installed. I thought a web app used the framework resources on the server?

    =================== Error ===================

    Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

    Parser Error Message: The connection name 'LocalSqlServer' was not found in the applications configuration or the connection string is empty.

    Source Error:

    Line 164:            <providers>
    Line 165:                <add name="AspNetSqlRoleProvider" connectionStringName="LocalSqlServer" applicationName="/"
    Line 166:                    type="System.Web.Security.SqlRoleProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
    Line 167:                <add name="AspNetWindowsTokenRoleProvider" applicationName="/"
    Line 168:                    type="System.Web.Security.WindowsTokenRoleProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />

    Source File: C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Config\machine.config    Line: 166

    Friday, January 27, 2006 5:55 PM
  • User-1909038188 posted

    A bit more information. I looked at my local machine.config file and it doesn't even have 166 lines. Does this mean that it is the machine.config on the server box? If so, then I am really confused. It seems to imply that there must be a "Local SQL Server". NOT!

    Help!

    Friday, January 27, 2006 6:02 PM
  • User838325616 posted

    You could try and put <clear/> as the first element in your <ConnectionStrings> element to clear out all the loaded connection strings.

    Other than that I don't really see anything wrong, unless your hosting provider does not let you override certain parts of the web.config like the membership providers.

    - Will



    Adding <clear/> worked (for now :)

    Thanks

    Dan
    Saturday, January 28, 2006 9:03 AM
  • User-1909038188 posted

    Think I found the answer. My Web Host (DiscountASP.Net) suggests you add the following to your web.config connectionStings section:

    ========================

    <remove name="LocalSqlServer" />

    <add name="LocalSqlServer" connectionString="Data Source=mssql08.discountasp.net;Integrated Security=false;Initial Catalog=DB_xxxx1;User ID=myID;Password=myPW" providerName="System.Data.SqlClient" />

    =================================

    Which seems to have resolved the problem.

    Saturday, January 28, 2006 1:18 PM
  • User1052258516 posted

    That is kind of weird, well the thing you could try is to use the MS default "LocalSqlServer" name for your connection string and point the provider to that name.  You would have to change all references to the connection string name and such but it might be interesting to see if that works.

    Either that or you will have to make an overriding section for the Role and Profile providers (like your membership provider) in your web.config to tell them to use your connection string name.<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /><o:p></o:p>

    - Will

    Saturday, January 28, 2006 3:19 PM