473,778 Members | 7,750 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Database Login Fail - Weird Problem

I keep getting the exception, "Cannot open database requested in login
'dbblah'. Login fails. Login failed for 'domain\user'".

I have ASPNET setup as the user in IIS, identity impersonate is true in the
web.config file. The IUSR and ASPNET identities have read and execute
permissions for the virtual directory's folder path.

Here's the weird part, if I hit F5 (refresh) it prompts to retry posting
back the form. I accept and it works fine. Every screen that connects the
database fails, when I refresh it works. CONFUSING!

The ASPNET account has access to the database. No other user accounts do
have access. This is the way we want it. Under the iis application for the
virtual directory we have set, the Anonymous user is set to domain\aspnet
(domain being our domain). If I uncheck the "Integrated Windows
authentication" checkbox, I don't get the error anymore and it works just
fine.

OS is Windows 2000 Server
..Net Framework v1.1

User set in machine.config is our aspnet account with the correct password
set. The anonymous user set in iis also has the correct password set.

Any help is appreciated :)

Mythran
Nov 19 '05 #1
1 1278
if you want the asp.net pages to run under the asp.net account, don't set
identity impersonate to true.

-- bruce (sqlwork.com)

"Mythran" <ki********@hot mail.comREMOVET RAIL> wrote in message
news:uz******** ******@tk2msftn gp13.phx.gbl...
| I keep getting the exception, "Cannot open database requested in login
| 'dbblah'. Login fails. Login failed for 'domain\user'".
|
| I have ASPNET setup as the user in IIS, identity impersonate is true in
the
| web.config file. The IUSR and ASPNET identities have read and execute
| permissions for the virtual directory's folder path.
|
| Here's the weird part, if I hit F5 (refresh) it prompts to retry posting
| back the form. I accept and it works fine. Every screen that connects
the
| database fails, when I refresh it works. CONFUSING!
|
| The ASPNET account has access to the database. No other user accounts do
| have access. This is the way we want it. Under the iis application for
the
| virtual directory we have set, the Anonymous user is set to domain\aspnet
| (domain being our domain). If I uncheck the "Integrated Windows
| authentication" checkbox, I don't get the error anymore and it works just
| fine.
|
| OS is Windows 2000 Server
| .Net Framework v1.1
|
| User set in machine.config is our aspnet account with the correct password
| set. The anonymous user set in iis also has the correct password set.
|
| Any help is appreciated :)
|
| Mythran
|
|
Nov 19 '05 #2

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

Similar topics

0
6271
by: mdh | last post by:
I am trying to learn the basics of MVC applications using a Tomcat infrastructure. I'm starting by building a simple application with: * a login.jsp page for a basic login form with a action pointing to "loginValidate.jsp" * a loginValidate.jsp page that references logic to validate requests * a loginBean class used to pass info between the JSP and validation logic * a usersDAO class used to perform lookups in a USERS
4
9903
by: Phil | last post by:
Hi all, I need some help to access an SQL db on another machine. I am using VB.NET and remoting to make a client/server connection...although I don't think this is relevant to the question. I have been asked to help with a small db project that will reside on our office server and have approx. 5 users. I have installed a copy of MSDE on my development machine and plan on doing
14
7144
by: L Mehl | last post by:
I tested a FE/BE application developed in A2000 on a A2002 machine and got this message when exiting the app. Clicking the only available button "OK", exits the application, as intended. The FE is just the mdb, not an mde. FE and BE are in different directories on the same machine. Are there settings, preferably via code, that I can add to stop this error? Thank you for any help.
1
2296
by: ad | last post by:
I want to backup and restore a database in asp.net. The backup process is successful and fail when restore with message: User does not have permission to RESTORE database 'Health'. RESTORE DATABASE is terminating abnormally the restore SQL is : restore database Health from disk = 'D:\Data\ASPNET\Health8\Backup\myback.bck' and the backup SQL is:
0
1698
by: clintonG | last post by:
I applied aspnet_regsql to SQL2K which was working fine throughout Beta 2 development. After installing Visual Studio and SQL Express RTM my application has blown up. Logging in to the application became realllllllllllly slow. Content in LoginView Role Groups was not displaying even after a user in a role had logged in. It was taking about 15 seconds or so for the login control to display when the login link was selected on the homepage....
11
1730
by: Sheldon Glickler | last post by:
I have code that does not delete from a database. The same code (cut an paste in the same file, but different function and having a different query) works. So, of course, I tested the query interactively. I echoed the query and did a cut and paste when interactively connect to the database. That one worked so it isn't the query since interactively it is seeing exactly the same thing as the code produces. Here is the code: function...
2
1312
by: esqueletoh | last post by:
Hi, i'm having a very weird problem. I have an application Asp .Net (Framework 1.1) that uses form authentication. To deny access to non-authenticated users i use <authorization> <deny users="?" /> </authorization> in the web.config file. It works ok when the app is deployed on any machine using IIS v5.1, but
7
3361
by: Deccypher | last post by:
Hi Im trying to do something a little more complex with my login script at the moment it works fine, checks the username and password with the database if its wrong it echo's a error and if its right redirects the user to the main page with the session variable logged_in = true but what i have done now is added more feileds into the user table name company email ect. what i want to do is on successful login pull the users information and...
5
3199
by: mcfly1204 | last post by:
I am attempting to use WebRequest to access a page that requires a login/password to access. My last WebRequest continues to timeout. Any help or thoughts would be appreciated. namespace FormsAuthTest { class Program { static void Main(string args) { HttpWebRequest request = null;
0
9629
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10298
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10127
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10069
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9923
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 protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8957
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
6723
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
4033
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 we have to send another system
2
3627
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.