Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeGetting StartedGetting StartedInstalling DNN ...Installing DNN ...Windows Authentication and SQL Server 2005 ExpressWindows Authentication and SQL Server 2005 Express
Previous
 
Next
New Post
7/2/2008 10:08 PM
 

Hello,

Windows Server 2003

SQL Server Express 2005

Integrated Authentication with NETWORK SERVICE   defined as a dbo_owner user for the  database.

Connection String

<add name="SiteSqlServer" connectionString="Data Source=.\SQLExpress;Integrated Security=True;User Instance=True;AttachDBFilename=|DataDirectory|myDatabaseName.mdf;" providerName="System.Data.SqlClient" />

Medium Trust CAS is configured, which should not present any problems according to the DNN doc.

 

Go to start the installation get this off the bat....

The current identity (NT AUTHORITY\NETWORK SERVICE) does not have write access to 'c:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\Temporary ASP.NET Files'

Dunno why i need to be setting permissions in my Windows directory, but added full control for the network service.

 

I get to the connection page in the install wizard and get the following when i click test. Database is configured to accept remote named pipes and tcp/ip connections. I originally had it locked down to not accept remote connections, WHICH SHOULD WORK - THE ONLY CONNECTION IS LOCAL FROM ASP>NET

Connection Error(s):
Index #: 0
Source: .Net SqlClient Data Provider
Class: 20
Number: 233
Message: A connection was successfully established with the server, but then an error occurred during the login process. (provider: Named Pipes Provider, error: 0 - No process is on the other end of the pipe.)

 

I click on test connection again....

Connection Error(s):
Index #: 0
Source: .Net SqlClient Data Provider
Class: 16
Number: 5120
Message: Unable to open the physical file "C:\Inetpub\wwwroot\gravidSoft\website\App_Data\gravidSoftDNN.mdf". Operating system error 5: "5(Access is denied.)".

Index #: 1
Source: .Net SqlClient Data Provider
Class: 14
Number: 15350
Message: An attempt to attach an auto-named database for file C:\Inetpub\wwwroot\gravidSoft\website\App_Data\gravidSoftDNN.mdf failed. A database with the same name exists, or specified file cannot be opened, or it is located on UNC share.

 

I am assuming this is because a connection has already been established, the database file mounted, and the code is trying to repeat this and getting an access violation.


Any help would be appreciated. I have been a developer for 15 years so dont be afraid to speak at that level.

 

Thanks,

Matthew

 

 
New Post
7/3/2008 1:05 AM
 

Permissions are needed on the .NET Temporary files spaces because that's where your website gets compiled to when it's launched. You'll have to talk to Microsoft about why this is.

I've never tried creating the database from the .mdf file but I'm going to assume it's similar to manually creating it. Does NETWORK SERVICE have permissions to create a database, etc on your SQL Server? That's the account that's trying to connect and do things on the SQL server.

 
New Post
7/3/2008 5:18 AM
 

Hi Mike,

Thanks for the response. I went in an granted the Network Service Login all possible Server Roles and still get the following when testing the connection in the installation wizard. I had set the default database to the database i created in App_Data, but changed this back to master.

Connection Error(s):
Index #: 0
Source: .Net SqlClient Data Provider
Class: 20
Number: 233
Message: A connection was successfully established with the server, but then an error occurred during the login process. (provider: Named Pipes Provider, error: 0 - No process is on the other end of the pipe.)

 

I then user mapped the Network Service login to each database on the server [the system databases Master etc] with a db_owner role. Confirmed the user existed on each database with db_owner privileges. Got the same thing when testing the connection.

I am a little confused by your language, "I've never tried creating the database from the .mdf file but I'm going to assume it's similar to manually creating it. ", in that I have already created an empty database and corresponding mdf and log file in App_Data using SQL Server Management Studio Express. Was I not supposed to do this? I deleted the original Database.mdf file which came in the Install distribution.

 

Thanks,

Matthew

 
New Post
7/3/2008 6:13 AM
 

Well just for fun I switched to SQL authentication, turned off Medium Trust CAS and the installation went fine. Wish I had not turned off the CAS, as now I'm not sure if that was a problem in trying to install previously.

Bottom line, my requirement is get the thing installed with Windows Authentication. The security docs on hardening installations highly recommends it, yet i can't find any discussion in google on how it is done. Has anyone on this forum ever performed an installation with a hardened SQL Server 2005 Express (no remote connections and windows authentication only) on Win 2k3 server?

 

Thanks,

Matthew

 
New Post
7/3/2008 6:44 AM
 

I set up non-business sites this way frequently as vanilla type installs but I don't modify or delete the original mdf file in the app data folder nor do I create an empty db in Studio Management Express.  I simply give network service the appropriate permissions on the root install folder and run the install wizard.  My SQL Express uses windows Authentication and I am logged onto my machine as an administrator.  The wizard runs without any issues.

If you're just trying to get an installation to work, maybe try to simplify it as much as possible and go back and tweak later.

Paul

 
Previous
 
Next
HomeHomeGetting StartedGetting StartedInstalling DNN ...Installing DNN ...Windows Authentication and SQL Server 2005 ExpressWindows Authentication and SQL Server 2005 Express


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out