473,466 Members | 1,360 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

App_data - ASPNETDB.MDF

I have visual studio 2008.
My site has a plesk on it.

I want to deploy my project, and save it on the host machine.

Looking for solution for folowings, please :

1st solution
=======
Should ASPNETDB.MDF is necessary,
and can I ignore it (How can I do that) ?

Since the host side trying to make this file automatically.

2nd solution
========

I tried to make the ASPNET.MDF on my machine,
but I got a message :
Cannot make SSPI context.

I persume this is via security, and I should run SSMS.exe
(I have SQL-Server 2005 on my machine).
But where is it ?

3rd solution
========
Can't just finding somewhere a good ASPNETDB.MDF, and is it the only file.
After downloading from
http://www.4shared.com/file/59591680...NETDB_TMP.html
(Which is 10M !!! - A problem too).
I got the message :

Failed to generate a user instance of SQL Server due tofailure in retrieving
the user's local application data path. Pleasemake sure the user has a local
user profile on the computer. Theconnection will be closed.
Description: Anunhandled exception occurred during the execution of the
current webrequest. Please review the stack trace for more information about
theerror and where it originated in the code.

Exception Details: System.Data.SqlClient.SqlException:Failed to generate a
user instance of SQL Server due to failure inretrieving the user's local
application data path. Please make sure theuser has a local user profile on
the computer. The connection will beclosed.

Source Error:

An unhandled exception was generated during the execution of
thecurrent web request. Information regarding the origin and location ofthe
exception can be identified using the exception stack trace below.


Thanks :)
Oct 19 '08 #1
6 9571
4th solution
========
Just finding a good ASPNETDB file somewhere on the internet,
and put it on my site (The site on 3th solution is not thinking to be good).

Thanks :)
Oct 20 '08 #2
I would review this:
http://weblogs.asp.net/scottgu/archi...25/423703.aspx
If your hosting provider doesn't support Sql Express version, then you'll
need to create a non express database somewhere.

The MembershipProvider is an ABSTRACT implementation, thus there are several
backend database choices.
Express aspnetdb.mdf is the DEFAULT "auto get created" version.

If you already have membership data in place, you can consider this blog
entry for transferring data.
http://sholliday.spaces.live.com/Blog/cns!A68482B9628A842A!160.entry


"Mr. X." <no_spam_please@nospam_please.comwrote in message
news:O2**************@TK2MSFTNGP05.phx.gbl...
>I have visual studio 2008.
My site has a plesk on it.

I want to deploy my project, and save it on the host machine.

Looking for solution for folowings, please :

1st solution
=======
Should ASPNETDB.MDF is necessary,
and can I ignore it (How can I do that) ?

Since the host side trying to make this file automatically.

2nd solution
========

I tried to make the ASPNET.MDF on my machine,
but I got a message :
Cannot make SSPI context.

I persume this is via security, and I should run SSMS.exe
(I have SQL-Server 2005 on my machine).
But where is it ?

3rd solution
========
Can't just finding somewhere a good ASPNETDB.MDF, and is it the only file.
After downloading from
http://www.4shared.com/file/59591680...NETDB_TMP.html
(Which is 10M !!! - A problem too).
I got the message :

Failed to generate a user instance of SQL Server due tofailure in
retrieving the user's local application data path. Pleasemake sure the
user has a local user profile on the computer. Theconnection will be
closed.
Description: Anunhandled exception occurred during the execution of the
current webrequest. Please review the stack trace for more information
about theerror and where it originated in the code.

Exception Details: System.Data.SqlClient.SqlException:Failed to generate a
user instance of SQL Server due to failure inretrieving the user's local
application data path. Please make sure theuser has a local user profile
on the computer. The connection will beclosed.

Source Error:

An unhandled exception was generated during the execution of
thecurrent web request. Information regarding the origin and location
ofthe exception can be identified using the exception stack trace below.


Thanks :)


Oct 20 '08 #3
The hosting provider supports Sql Express version,
But I don't have any reference to sql (yet),
so I don't understand why when deploying a dot-net application
(from VS 2008 - VB), I should have ASPNETDB.MDF on the hosting site,
whether I want it or not (as I sent a post on 3rd solution - it's 10M,
and I don't know if this is the only file).

(I see that the site is trying using this file, and create it
automatically).

Thanks :)
Oct 20 '08 #4
Google this:
<remove name="LocalSqlServer"/>

That might remove the "auto create" mechanism, I'm not sure.

Basically, when you make a new website, the "auto create" stuff is built in.
You have to take steps to remove it if you don't want to use the
MembershipProvider stuff.

..........

Can you clarify what you want as the end result?

A.. I don't want a aspnetdb.mdf (at all) on the host server.
B. I want my own version of aspnetdb.mdf on the host server.
(B2) I want the host server to use Express version as well.
I'm not sure if you want or don't want to use the MembershipProvider in your
(final) solution or not.


"Mr. X." <no_spam_please@nospam_please.comwrote in message
news:O5**************@TK2MSFTNGP02.phx.gbl...
The hosting provider supports Sql Express version,
But I don't have any reference to sql (yet),
so I don't understand why when deploying a dot-net application
(from VS 2008 - VB), I should have ASPNETDB.MDF on the hosting site,
whether I want it or not (as I sent a post on 3rd solution - it's 10M,
and I don't know if this is the only file).

(I see that the site is trying using this file, and create it
automatically).

Thanks :)

Oct 20 '08 #5
The SSPI failure has to do with the ASPNET user account not having rights to
the database. This is common on ISP servers. If you want to get around this
on the ISP, change your connection string or have the ISP allow ASPNET user
(which could be a security issue) or use another account and impersonate
(you will need the ISP's help on this, as well).

Are you doing Membership?
If so, use the admin tool and create the database locally.

To deploy, consider this:
http://gregorybeamer.spaces.live.com/blog/cns!B036196EAF9B34A8!630.entry

--
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA

Subscribe to my blog
http://feeds.feedburner.com/GregoryBeamer#

or just read it:
http://feeds.feedburner.com/GregoryBeamer

********************************************
| Think outside the box! |
********************************************
"Mr. X." <no_spam_please@nospam_please.comwrote in message
news:O2**************@TK2MSFTNGP05.phx.gbl...
>I have visual studio 2008.
My site has a plesk on it.

I want to deploy my project, and save it on the host machine.

Looking for solution for folowings, please :

1st solution
=======
Should ASPNETDB.MDF is necessary,
and can I ignore it (How can I do that) ?

Since the host side trying to make this file automatically.

2nd solution
========

I tried to make the ASPNET.MDF on my machine,
but I got a message :
Cannot make SSPI context.

I persume this is via security, and I should run SSMS.exe
(I have SQL-Server 2005 on my machine).
But where is it ?

3rd solution
========
Can't just finding somewhere a good ASPNETDB.MDF, and is it the only file.
After downloading from
http://www.4shared.com/file/59591680...NETDB_TMP.html
(Which is 10M !!! - A problem too).
I got the message :

Failed to generate a user instance of SQL Server due tofailure in
retrieving the user's local application data path. Pleasemake sure the
user has a local user profile on the computer. Theconnection will be
closed.
Description: Anunhandled exception occurred during the execution of the
current webrequest. Please review the stack trace for more information
about theerror and where it originated in the code.

Exception Details: System.Data.SqlClient.SqlException:Failed to generate a
user instance of SQL Server due to failure inretrieving the user's local
application data path. Please make sure theuser has a local user profile
on the computer. The connection will beclosed.

Source Error:

An unhandled exception was generated during the execution of
thecurrent web request. Information regarding the origin and location
ofthe exception can be identified using the exception stack trace below.


Thanks :)


Oct 20 '08 #6
The reason I want to use MemberShipProvider,
is only because I want my site work, without exception.

If MemberShipProvider is neccessary to have things work,
so I will try to learn using it on the hard way.

I need to put a control system manager,
that someone should (with user+password) change some text on the site.

I can have a simple aspx (without using Visual Studio 2008) - I mean by
notepad,
and do the all thing by hand (but I insist using the Visual Studio 2008, for
it's abilties).

I have found in
http://www.4shared.com/file/59591680...NETDB_TMP.html

(The simpliest approach is just obtain an empty database, and putting it on
the hosting site - but where ?)

the ASPNETDB.MDF and ASPNETDB_LOG.LDF,
but I don't know : whether version are right,
whether I should change the name.

Where can I obtain good files ?

When I put ASPNETDB.MDF I get another exception
(so the file is indeed referenced by the hosting site, based on PLESK !!!).

Before putting the file (ASPNETDB.MDF ):
==============================
Server Error in '/' Application.
--------------------------------------------------------------------------------

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.
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.

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:
a.. If the applications App_Data directory does not already exist, the web
server account must have read and write access to the applications
directory. This is necessary because the web server account will
automatically create the App_Data directory if it does not already exist.
b.. If the applications App_Data directory already exists, the web server
account only requires read and write access to the applications App_Data
directory. This is necessary because the web server account will attempt to
verify that the Sql Server Express database already exists within the
applications App_Data directory. Revoking read access on the App_Data
directory from the web server account will prevent the provider from
correctly determining if the Sql Server Express database already exists.
This will cause an error when the provider attempts to create a duplicate of
an already existing database. Write access is required because the web
server accounts credentials are used when creating the new database.
c.. Sql Server Express must be installed on the machine.
d.. The process identity for the web server account must have a local user
profile. See the readme document for details on how to create a local user
profile for both machine and domain accounts.
Source Error:

An unhandled exception was generated during the execution of the
current web request. Information regarding the origin and location of the
exception can be identified using the exception stack trace below.

Stack Trace:

[SqlException (0x80131904): 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.]
System.Data.SqlClient.SqlInternalConnection.OnErro r(SqlException
exception, Boolean breakConnection) +800131
System.Data.SqlClient.TdsParser.ThrowExceptionAndW arning(TdsParserStateObject
stateObj) +186
System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand
cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet
bulkCopyHandler, TdsParserStateObject stateObj) +1932
System.Data.SqlClient.SqlInternalConnectionTds.Com pleteLogin(Boolean
enlistOK) +33
System.Data.SqlClient.SqlInternalConnectionTds.Att emptOneLogin(ServerInfo
serverInfo, String newPassword, Boolean ignoreSniOpenTimeout, Int64
timerExpire, SqlConnection owningObject) +172
System.Data.SqlClient.SqlInternalConnectionTds.Log inNoFailover(String
host, String newPassword, Boolean redirectedUserInstance, SqlConnection
owningObject, SqlConnectionString connectionOptions, Int64 timerStart) +381
System.Data.SqlClient.SqlInternalConnectionTds.Ope nLoginEnlist(SqlConnection
owningObject, SqlConnectionString connectionOptions, String newPassword,
Boolean redirectedUserInstance) +181
System.Data.SqlClient.SqlInternalConnectionTds..ct or(DbConnectionPoolIdentity
identity, SqlConnectionString connectionOptions, Object providerInfo, String
newPassword, SqlConnection owningObject, Boolean redirectedUserInstance)
+173
System.Data.SqlClient.SqlConnectionFactory.CreateC onnection(DbConnectionOptions
options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection
owningConnection) +133
System.Data.ProviderBase.DbConnectionFactory.Creat eNonPooledConnection(DbConnection
owningConnection, DbConnectionPoolGroup poolGroup) +27
System.Data.ProviderBase.DbConnectionFactory.GetCo nnection(DbConnection
owningConnection) +47
System.Data.ProviderBase.DbConnectionClosed.OpenCo nnection(DbConnection
outerConnection, DbConnectionFactory connectionFactory) +105
System.Data.SqlClient.SqlConnection.Open() +111
System.Web.Management.SqlServices.GetSqlConnection (String server, String
user, String password, Boolean trusted, String connectionString) +68

[HttpException (0x80004005): Unable to connect to SQL Server database.]
System.Web.Management.SqlServices.GetSqlConnection (String server, String
user, String password, Boolean trusted, String connectionString) +124
System.Web.Management.SqlServices.SetupApplication Services(String server,
String user, String password, Boolean trusted, String connectionString,
String database, String dbFileName, SqlFeatures features, Boolean install)
+86
System.Web.Management.SqlServices.Install(String database, String
dbFileName, String connectionString) +25
System.Web.DataAccess.SqlConnectionHelper.CreateMd fFile(String
fullFileName, String dataDir, String connectionString) +397

--------------------------------------------------------------------------------
Version Information: Microsoft .NET Framework Version:2.0.50727.1433;
ASP.NET Version:2.0.50727.1433

After putting the file (ASPNETDB.MDF) :
=============================
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.
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: 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.

Source Error:
An unhandled exception was generated during the execution of the
current web request. Information regarding the origin and location of the
exception can be identified using the exception stack trace below.
Stack Trace:
[SqlException (0x80131904): 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.]
System.Data.SqlClient.SqlInternalConnection.OnErro r(SqlException
exception, Boolean breakConnection) +800131
System.Data.SqlClient.TdsParser.ThrowExceptionAndW arning(TdsParserStateObject
stateObj) +186
System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand
cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet
bulkCopyHandler, TdsParserStateObject stateObj) +1932
System.Data.SqlClient.SqlInternalConnectionTds.Com pleteLogin(Boolean
enlistOK) +33
System.Data.SqlClient.SqlInternalConnectionTds.Att emptOneLogin(ServerInfo
serverInfo, String newPassword, Boolean ignoreSniOpenTimeout, Int64
timerExpire, SqlConnection owningObject) +172
System.Data.SqlClient.SqlInternalConnectionTds.Log inNoFailover(String
host, String newPassword, Boolean redirectedUserInstance, SqlConnection
owningObject, SqlConnectionString connectionOptions, Int64 timerStart) +381
System.Data.SqlClient.SqlInternalConnectionTds.Ope nLoginEnlist(SqlConnection
owningObject, SqlConnectionString connectionOptions, String newPassword,
Boolean redirectedUserInstance) +181
System.Data.SqlClient.SqlInternalConnectionTds..ct or(DbConnectionPoolIdentity
identity, SqlConnectionString connectionOptions, Object providerInfo, String
newPassword, SqlConnection owningObject, Boolean redirectedUserInstance)
+173
System.Data.SqlClient.SqlConnectionFactory.CreateC onnection(DbConnectionOptions
options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection
owningConnection) +133
System.Data.ProviderBase.DbConnectionFactory.Creat ePooledConnection(DbConnection
owningConnection, DbConnectionPool pool, DbConnectionOptions options) +30
System.Data.ProviderBase.DbConnectionPool.CreateOb ject(DbConnection
owningObject) +424
System.Data.ProviderBase.DbConnectionPool.UserCrea teRequest(DbConnection
owningObject) +66
System.Data.ProviderBase.DbConnectionPool.GetConne ction(DbConnection
owningObject) +494
System.Data.ProviderBase.DbConnectionFactory.GetCo nnection(DbConnection
owningConnection) +82
System.Data.ProviderBase.DbConnectionClosed.OpenCo nnection(DbConnection
outerConnection, DbConnectionFactory connectionFactory) +105
System.Data.SqlClient.SqlConnection.Open() +111
System.Web.DataAccess.SqlConnectionHolder.Open(Htt pContext context,
Boolean revertImpersonate) +84
System.Web.DataAccess.SqlConnectionHelper.GetConne ction(String
connectionString, Boolean revertImpersonation) +197
System.Web.Security.SqlMembershipProvider.GetPassw ordWithFormat(String
username, Boolean updateLastLoginActivityDate, Int32& status, String&
password, Int32& passwordFormat, String& passwordSalt, Int32&
failedPasswordAttemptCount, Int32& failedPasswordAnswerAttemptCount,
Boolean& isApproved, DateTime& lastLoginDate, DateTime& lastActivityDate)
+1121
System.Web.Security.SqlMembershipProvider.CheckPas sword(String username,
String password, Boolean updateLastLoginActivityDate, Boolean
failIfNotApproved, String& salt, Int32& passwordFormat) +105
System.Web.Security.SqlMembershipProvider.CheckPas sword(String username,
String password, Boolean updateLastLoginActivityDate, Boolean
failIfNotApproved) +42
System.Web.Security.SqlMembershipProvider.Validate User(String username,
String password) +83
System.Web.UI.WebControls.Login.OnAuthenticate(Aut henticateEventArgs e)
+160
System.Web.UI.WebControls.Login.AttemptLogin() +105
System.Web.UI.WebControls.Login.OnBubbleEvent(Obje ct source, EventArgs e)
+99
System.Web.UI.Control.RaiseBubbleEvent(Object source, EventArgs args) +35
System.Web.UI.WebControls.Button.OnCommand(Command EventArgs e) +115
System.Web.UI.WebControls.Button.RaisePostBackEven t(String eventArgument)
+163
System.Web.UI.WebControls.Button.System.Web.UI.IPo stBackEventHandler.RaisePostBackEvent(String
eventArgument) +7
System.Web.UI.Page.RaisePostBackEvent(IPostBackEve ntHandler
sourceControl, String eventArgument) +11
System.Web.UI.Page.RaisePostBackEvent(NameValueCol lection postData) +33
System.Web.UI.Page.ProcessRequestMain(Boolean
includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1746

--------------------------------------------------------------------------------

Version Information: Microsoft .NET Framework Version:2.0.50727.1433;
ASP.NET Version:2.0.50727.1433

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

ASPNETDB_LOG.LDF make no difference about the exceptions.

Thanks :)
Oct 21 '08 #7

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Bendik Engebretsen | last post by:
I have made an ASP.NET 2.0 WebSite using the 'Personal WEB site' starter kit. It runs fine on my XP machine where I have the VStudio.NET 2005 Beta installed. But if I try to run it from our Win...
5
by: VB Programmer | last post by:
My web hoster says that I have to rename my ASPNETDB.MDF SqlExpress db for my 2.0 site to work. Is this accurate? If so, how can I rename it without breaking anything on my site? FYI: This is...
2
by: te goody | last post by:
Problem summary: Web Site Admin Tool is not generating the application services database (aspnetdb.mdf); i.e. The DB is not found under the app_data directory. The Question: What configuration...
0
by: te goody | last post by:
Problem summary: Web Site Admin Tool is not generating the application services database (aspnetdb.mdf) in a SS 2005 only environment; i.e. The DB is not found under the app_data directory. The...
3
by: Shimon Sim | last post by:
I am trying to work with web part framework. Yesterday I build try-it site and it work just fine. Today I tried to do the same and I keep getting this message attempt to attach an auto-named...
2
by: R.A.M. | last post by:
Hello, I am learning .NET 2.0. I have a question concerning ASPNETDB SQL database which contains information about users. I have created ASP.NET application but I don't see...
3
by: Freddie | last post by:
hi, i try to get the asp.net 2.0 security controls to work with SQL Server 2005 Dev RTM, this is my connetion string in mashine.config <connectionStrings> <add name="LocalSqlServer"...
1
by: CFTK | last post by:
This is the error I get when I try to login in my application from another machine: An attempt to attach an auto-named database for file C:\Documents and Settings\....\App_Data\aspnetdb.mdf...
6
by: greg.hart | last post by:
Hello all, Just wanted to get some clarification on something. I was setting out to create a login page for people to login and then be able to access certain aspects of the website. Instead...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.