473,385 Members | 1,867 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Intermittent SQL Server login problem

pvl
Hi

We have the following scenario:
1. SQL server 2000 on Windows 2003 Server
2. Web server 1, running web service 1 on Windows 2003 Server
3. Web server 2, running web service 2 on Windows 2000 Server
4. Client application.

1, 2 & 3 are all on the same Windows 2003 domain.

Client application connects to web service 2 from the internet.
Web service 2 uses impersonation in web.config to impersonate a domain
account. It then connects to web service 1, which in turns connects to
SQL server using a trusted connection.

Web service 1 only allows windows authentication.
All servers are trusted for delegation.

Now for the problem: The first call after an idle period of 20 - 30
minutes always fails with SQL server reporting that the login failed
for user null.

Web service 1 impersonates the HttpContext.User.Identity before every
call to SQL server.

This works every time after the first failure, but leave it for 20
minutes and it fails again.

I can see that the impersonation from web service 2 works correctly,
because I trace HttpContext.Identity.Name as well as the currect thread
identity. These are always correct.

Any help will be appreciated
Thanks
Pierre-Andre

Nov 19 '05 #1
2 2054
Sounds like Session Timeout to me. Are you using Session or Application
State in either Web Service?

--
HTH,

Kevin Spencer
Microsoft MVP
..Net Developer
What You Seek Is What You Get.

"pvl" <pv*@gendac.co.za> wrote in message
news:11**********************@f14g2000cwb.googlegr oups.com...
Hi

We have the following scenario:
1. SQL server 2000 on Windows 2003 Server
2. Web server 1, running web service 1 on Windows 2003 Server
3. Web server 2, running web service 2 on Windows 2000 Server
4. Client application.

1, 2 & 3 are all on the same Windows 2003 domain.

Client application connects to web service 2 from the internet.
Web service 2 uses impersonation in web.config to impersonate a domain
account. It then connects to web service 1, which in turns connects to
SQL server using a trusted connection.

Web service 1 only allows windows authentication.
All servers are trusted for delegation.

Now for the problem: The first call after an idle period of 20 - 30
minutes always fails with SQL server reporting that the login failed
for user null.

Web service 1 impersonates the HttpContext.User.Identity before every
call to SQL server.

This works every time after the first failure, but leave it for 20
minutes and it fails again.

I can see that the impersonation from web service 2 works correctly,
because I trace HttpContext.Identity.Name as well as the currect thread
identity. These are always correct.

Any help will be appreciated
Thanks
Pierre-Andre

Nov 19 '05 #2
We're not using any session state in the web services.
I've also been playing round with the settings on the application pools to
see if it has anything to do with that, but it doesn't seem so.

"Kevin Spencer" <ke***@DIESPAMMERSDIEtakempis.com> wrote in message
news:ek**************@TK2MSFTNGP10.phx.gbl...
Sounds like Session Timeout to me. Are you using Session or Application
State in either Web Service?

--
HTH,

Kevin Spencer
Microsoft MVP
.Net Developer
What You Seek Is What You Get.

"pvl" <pv*@gendac.co.za> wrote in message
news:11**********************@f14g2000cwb.googlegr oups.com...
Hi

We have the following scenario:
1. SQL server 2000 on Windows 2003 Server
2. Web server 1, running web service 1 on Windows 2003 Server
3. Web server 2, running web service 2 on Windows 2000 Server
4. Client application.

1, 2 & 3 are all on the same Windows 2003 domain.

Client application connects to web service 2 from the internet.
Web service 2 uses impersonation in web.config to impersonate a domain
account. It then connects to web service 1, which in turns connects to
SQL server using a trusted connection.

Web service 1 only allows windows authentication.
All servers are trusted for delegation.

Now for the problem: The first call after an idle period of 20 - 30
minutes always fails with SQL server reporting that the login failed
for user null.

Web service 1 impersonates the HttpContext.User.Identity before every
call to SQL server.

This works every time after the first failure, but leave it for 20
minutes and it fails again.

I can see that the impersonation from web service 2 works correctly,
because I trace HttpContext.Identity.Name as well as the currect thread
identity. These are always correct.

Any help will be appreciated
Thanks
Pierre-Andre


Nov 19 '05 #3

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

Similar topics

1
by: Anthony | last post by:
I have a php app that is in the final stages of testing and has been tested by over 30 separate users. One of the testers is having an intermittent problem which seems to be caused by a session...
10
by: Dan | last post by:
We have a fairly large set of ASP.NET applications running on Windows 2003 SP1 server. The entire suite of software was originally written in ASP and ran on a Win 2k server. For about the last...
0
by: deevoy | last post by:
Hi- I'm developing a asp.net web application and everything has proven fine on the dev and acceptance environment. We've moved the code up to our windows server 2003 prod environment and get the...
8
by: trinitypete | last post by:
Hi all I have a strange problem with IIS windows pass through authentication. Heres the setup IIS running with Windows Authentication for our intranet site. ACL has been set to everyone for all...
2
by: Mike Krajewski | last post by:
We are having an intermittent problem using an ExecuteScalar command on a asp.NET page accessing SQL Server. 2 characters of the sql statement get intermittently altered. The code looks as...
3
by: Lee Chapman | last post by:
Hi, I have a problem where my ASP.NET application occasionally generates a MissingFieldException exception. This unexpectedly happened on my development box, and so I was able to extract some...
1
by: deevoy | last post by:
Hi- I'm developing a asp.net web application and everything has proven fine on the dev and acceptance environment. We've moved the code up to our windows server 2003 prod environment and get...
0
by: Shane C | last post by:
Intermittent Error: Server was unable to process request  Object reference not set to an instance of an object I have windows application that references a XML web service on our web server. ...
3
by: Velvet | last post by:
I'm having an intermittent problem with IE 6.0.2900.2180.xpsp_sp2_gdr.050301-1519 installed on Windows XP. The images, style sheets and JavaScript files are not loading to the browser. ...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
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
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,...
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...

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.