[2.0] Cannot create membership database on webhost provider

N

~~~ .NET Ed ~~~

Hi,
I am having problems creating the necessary membership stuff on my
webhost. Here is the information.

My webhost provider (shared hosting) has Microsoft .NET v2.0 and both MSSQL
databases. Obviously one as customer has no access to the master tables
where the membership scripts deploy themselves.

On my shared hosting I created a SQL Server 2005 database, say I called it
MyMembers to which I had to assign a user and password credentials at the
time of creation. Unfortunately I have gotten stuck there.

Approach #1: ASPNET_REGSQL
--------------
I used aspnet_regsql .exe, entered the Server name (the SQL server address
of my webhost provider), selected SQL Server Authentication and entered the
user/password assigned when I created the database. Also entered the name of
the database exactly as I created it (i.e. MyMembers) because it can't do
the browsing.

I then clicked Next and was presented with the server name and DB name.
Clicked Next again and after a few moments I got the following error:

Setup failed.

Exception:
Unable to connect to SQL Server database.

----------------------------------------
Details of failure
----------------------------------------

System.Web.HttpException: Unable to connect to SQL Server database. --->
System.Data.SqlClient.SqlException: 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: Named Pipes Provider, error:
40 - Could not open a connection to SQL Server)
at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException
exception, Boolean breakConnection)
at
System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject
stateObj)
at System.Data.SqlClient.TdsParser.Connect(Boolean& useFailoverPartner,
Boolean& failoverDemandDone, String host, String failoverPartner, String
protocol, SqlInternalConnectionTds connHandler, Int64 timerExpire, Boolean
encrypt, Boolean trustServerCert, Boolean integratedSecurity, SqlConnection
owningObject, Boolean aliasLookup)
at
System.Data.SqlClient.SqlInternalConnectionTds.OpenLoginEnlist(SqlConnection
owningObject, SqlConnectionString connectionOptions, String newPassword,
Boolean redirectedUserInstance)
at
System.Data.SqlClient.SqlInternalConnectionTds..ctor(DbConnectionPoolIdentity
identity, SqlConnectionString connectionOptions, Object providerInfo, String
newPassword, SqlConnection owningObject, Boolean redirectedUserInstance)
at
System.Data.SqlClient.SqlConnectionFactory.CreateConnection(DbConnectionOptions
options, Object poolGroupProviderInfo, DbConnectionPool pool, DbConnection
owningConnection)
at
System.Data.ProviderBase.DbConnectionFactory.CreatePooledConnection(DbConnection
owningConnection, DbConnectionPool pool, DbConnectionOptions options)
at System.Data.ProviderBase.DbConnectionPool.CreateObject(DbConnection
owningObject)
at
System.Data.ProviderBase.DbConnectionPool.UserCreateRequest(DbConnection
owningObject)
at System.Data.ProviderBase.DbConnectionPool.GetConnection(DbConnection
owningObject)
at
System.Data.ProviderBase.DbConnectionFactory.GetConnection(DbConnection
owningConnection)
at
System.Data.ProviderBase.DbConnectionClosed.OpenConnection(DbConnection
outerConnection, DbConnectionFactory connectionFactory)
at System.Data.SqlClient.SqlConnection.Open()
at System.Web.Management.SqlServices.GetSqlConnection(String server,
String user, String password, Boolean trusted, String connectionString)
--- End of inner exception stack trace ---
at System.Web.Management.SqlServices.GetSqlConnection(String server,
String user, String password, Boolean trusted, String connectionString)
at System.Web.Management.SqlServices.SetupApplicationServices(String
server, String user, String password, Boolean trusted, String
connectionString, String database, String dbFileName, SqlFeatures features,
Boolean install)
at System.Web.Management.SqlServices.Install(String database, SqlFeatures
features, String connectionString)
at System.Web.Management.ConfirmPanel.Execute()

Approach #2: MANAGEMENT STUDIO EXPRESS
-------------------------------------------------------
Given that option #1 did not work I used the Microsoft SQL Server Management
Studio Express to setup a connection to the DB server on the webhost
provider. The connection succeeded and I was presented with a tree
containing the server name and the databases.

I can see there the database I created on the webhost (MyMembers). Obviously
given that it is shared hosting I only have rights to that database and not
any other.

I read somewhere that if ASPNET_REGSQL did not work one could run
InstallCommon.sql and then InstallMembership.sql so I tried to do that using
the Management studio but got stomped with:

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

Starting execution of InstallCommon.SQL

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

Creating the aspnetdb database...

Msg 262, Level 14, State 1, Line 1

CREATE DATABASE permission denied in database 'master'.

Msg 916, Level 14, State 1, Line 2

The server principal "cptyuser" is not able to access the database
"ASPNETDB" under the current security context.

(120 row(s) affected)

Creating the aspnet_Applications table...

Creating the aspnet_Users table...

Creating the aspnet_SchemaVersions table...

Cannot grant, deny, or revoke permissions to sa, dbo, information_schema,
sys, or yourself.

Cannot grant, deny, or revoke permissions to sa, dbo, information_schema,
sys, or yourself.

(0 row(s) affected)

(1 row(s) affected)

Cannot grant, deny, or revoke permissions to sa, dbo, information_schema,
sys, or yourself.

Creating the vw_aspnet_Applications view...

Creating the vw_aspnet_Users view...

Cannot grant, deny, or revoke permissions to sa, dbo, information_schema,
sys, or yourself.

Cannot grant, deny, or revoke permissions to sa, dbo, information_schema,
sys, or yourself.

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

Completed execution of InstallCommon.SQL

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



So, what can I do? can somebody tell me how I can accomplish this? What I
need to do is work on my development PC and then deploy things to the
production site on the ISP provider.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,482
Members
44,901
Latest member
Noble71S45

Latest Threads

Top