Thanks for Peter's inputs,
Hi Gary,
Have you ever installed the SQL Server Express edition on that server
machine? If not, this is the expected behavior because by default,
ASP.NET's formsauthentication(membership/role provider) is configured to
use SqlServer provider , and the default connectionstring(used by this
provider) is pointing to a local SQL Express database file( in App_Data
folder), this is preconifguerd in machine.config(as below):
==============
<connectionStrings>
<add name="LocalSqlServer" connectionString="data
source=.\SQLEXPRESS;Integrated
Security=SSPI;AttachDBFilename=|DataDirectory|aspnetdb.mdf;User
Instance=true" providerName="System.Data.SqlClient" />
</connectionStrings>
...................
<system.web>
<processModel autoConfig="true" />
<httpHandlers />
<membership>
<providers>
<add name="AspNetSqlMembershipProvider"
type="System.Web.Security.SqlMembershipProvider, System.Web,
Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
connectionStringName="LocalSqlServer" enablePasswordRetrieval="false"
enablePasswordReset="true" requiresQuestionAndAnswer="true"
applicationName="/" requiresUniqueEmail="false" passwordFormat="Hashed"
maxInvalidPasswordAttempts="5" minRequiredPasswordLength="7"
minRequiredNonalphanumericCharacters="1" passwordAttemptWindow="10"
passwordStrengthRegularExpression="" />
</providers>
</membership>
.................
=============================
Certainly we can override this in our ASP.NET web application's web.config
file. e.g
#membership Element (ASP.NET Settings Schema)
http://msdn2.microsoft.com/en-us/library/1b9hw62f.aspx
================
<system.web>
.......................
<membership>
<providers defaultProvider="MySqlMembershipProvider">
<add name="MySqlMembershipProvider"
type="System.Web.Security.SqlMembershipProvider, System.Web,
Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
connectionStringName="NewSQLConnStr" enablePasswordRetrieval="false"
enablePasswordReset="true" requiresQuestionAndAnswer="true"
applicationName="/" requiresUniqueEmail="false" passwordFormat="Hashed"
maxInvalidPasswordAttempts="5" minRequiredPasswordLength="7"
minRequiredNonalphanumericCharacters="1" passwordAttemptWindow="10"
passwordStrengthRegularExpression="" />
</providers>
</membership>
==========================
The above configuration setting add a new configured provider(still use the
SqlMembershipProvider class), but change to use a new connectionstring
(named "NewSQLConnStr"). You can then add a new connectionstring which
point to a certain database in the SQL Server engine(2000 or 2005).
Also, we can use the aspnet_regsql.exe tool to setup and initialize the sql
provider specific tables/functions in a specfic database:
#ASP.NET SQL Server Registration Tool (Aspnet_regsql.exe)
http://msdn2.microsoft.com/en-us/library/ms229862.aspx
In addition, here is another good web article which describes detailed on
configuring membership/role service in ASP.NET 2.0:
# Examining ASP.NET 2.0's Membership, Roles, and Profile - Part 1
http://aspnet.4guysfromrolla.com/articles/120705-1.aspx
Hope this helps. If there is anything unclear in the above items, please
feel free to post here.
Regards,
Steven Cheng
Microsoft Online Community Support
==================================================
When responding to posts, please "Reply to Group" via your newsreader so
that others may learn and benefit from your issue.
==================================================
This posting is provided "AS IS" with no warranties, and confers no rights.
Get Secure!
www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)