locked
System.Data.SqlClient.SqlException RRS feed

  • Question

  • I use vs2008 + sql2005 express. When i test my asp.net application in VS it's work fine But when i deploy my application on server I get error when try use sql:

    15382

    16

    Yes

    Failed to generate a user instance of SQL Server due to failure in retrieving the user's local application data path. Please make sure the user has a local user profile on the computer. The connection will be closed.%.*ls

    Monday, June 28, 2010 9:41 AM

Answers

  • >>when i deploy my application on server I get error when try use sql:

    a) Post your connection string

    b) Is is IIS 7 or IIS 6?

    Meanwhile just to make sure

    On the web server you have user instance enabled

    exec sp_configure 'user instances enabled', 1 
    Go

    Reconfigure
    Go

    and

    If you are running IIS 7

    Make sure local user profile C:\Users\DefaultAppPool directory exists. If not, turn on LocalProfile=True, this will create the local profile. This is done in IIS Manager, In IIS under Windows 7, Select the application pool and then "advanced settings." Under "process model" find "Load User Profile" and set it to true

    Monday, June 28, 2010 2:21 PM

All replies

  • >>when i deploy my application on server I get error when try use sql:

    a) Post your connection string

    b) Is is IIS 7 or IIS 6?

    Meanwhile just to make sure

    On the web server you have user instance enabled

    exec sp_configure 'user instances enabled', 1 
    Go

    Reconfigure
    Go

    and

    If you are running IIS 7

    Make sure local user profile C:\Users\DefaultAppPool directory exists. If not, turn on LocalProfile=True, this will create the local profile. This is done in IIS Manager, In IIS under Windows 7, Select the application pool and then "advanced settings." Under "process model" find "Load User Profile" and set it to true

    Monday, June 28, 2010 2:21 PM
  • I use iis 7.

    "Make sure local user profile C:\Users\DefaultAppPool directory exists. If not, turn on LocalProfile=True, this will create the local profile. This is done in IIS Manager, In IIS under Windows 7, Select the application pool and then "advanced settings." Under "process model" find "Load User Profile" and set it to true"

    It's help me!

    Now when i deploy my project - all files are copy except files from app_data(but include files form app_data - check). Can i just manual copy that file from server dir? Must i something set up in sql server?

    I run VS from administrator.

    Tuesday, June 29, 2010 7:18 AM
  • >>all files are copy except files from app_data(but include files form app_data - check). Can i just manual copy that file from server dir? Must i something set up in sql server?

    I don't know why VS is not copying files from APP_DATA. Try publishing it manually.

    Tuesday, June 29, 2010 8:29 PM