Session Expiry - the session expired after a number of hours of inactivity, although Session Expiry

F

fijsolam1981

Hi,
I had created a web application where Session expiry was set to 2,000
minutes in IIS. in web config i had given like this
<sessionState timeout="2,000" mode="InProc"></sessionState> but MY web
application was left logged in at 18:00 15th Oct, but on the following
day 08:30 16th Oct, the session expired as soon as MY web application
was used. It was also noted that during the day, MY web application
occasionally got session expiry when it was constantly being used.Does
the session expiry need to be set up anywhere else? There are no
Error logs created.
Will you please help me to resolve this issue. i expect your reply
soon .

With Thanks
Fijo Francis T
 
A

Alberto Poblacion

I had created a web application where Session expiry was set to 2,000
minutes in IIS. in web config i had given like this
<sessionState timeout="2,000" mode="InProc"></sessionState>
[...] MY web application
occasionally got session expiry when it was constantly being used.Does
the session expiry need to be set up anywhere else? There are no
Error logs created.


Have you tried writing timeout="2000" instead of timeout="2,000"? I think
that the parser may be getting confused by the comma and setting a timeout
of 2 minutes instead of 2000 minutes as you intended. You can check if this
is the case by examining the Session.Timeout property somewhere in your
code.
 
G

Guest

The IIS setting (at least in 6.0) applies only to Classic ASP, not ASP.NET.
When IIS recycles your app (which can occur many times during the day
depending on memory pressure and ISS settings for same), your InProc sessions
will go away.
Normally there is no need to set such a long Session Timeout as it has a
sliding expiration that "renews" the timeout whenever there is a request for
a page. In addition, it can pose a real security risk. The best thing to do
is not rely on Session at all, depending on what your needs are.
Finally, this is the C# language group - your post really belongs at the
ASP.NET group - it is not language specific but more about which framework.
-- Peter
Recursion: see Recursion
site: http://www.eggheadcafe.com
unBlog: http://petesbloggerama.blogspot.com
BlogMetaFinder: http://www.blogmetafinder.com
 

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

Top