[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

ASP.NET Session Timeout

Posted on 2012-03-29
17
Medium Priority
?
776 Views
Last Modified: 2012-04-23
I have an ASP.NET webiste I developed.  I have the following in my web.config file.

      <sessionState cookieless="true" timeout="20" />

However, it seems my session is timing out after 3 mins.  Any ideas how to resolve?
0
Comment
Question by:CipherIS
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 10
  • 3
  • 2
  • +2
17 Comments
 
LVL 41

Expert Comment

by:Kyle Abrahams
ID: 37784131
It could be in your IIS.  Ensure the worker process is not recycling.
0
 
LVL 7

Expert Comment

by:Lalit Chandra
ID: 37784160
Chances are the worker process is recycled meantime, Where do you store the sessions?
Making your sessions stored out of process may helps.

you can also know about another settings quickly from the nice article below

http://ramanisandeep.net/2011/03/19/tipstrick-session-timeout-problem-in-iis7/

Hope this will help.
0
 
LVL 1

Author Comment

by:CipherIS
ID: 37784271
Thanks but that did not solve the problem.

Application pool’s Idle Time-out = 20 Mins

Session State Mode Settigs Values
-  In PRocess

Cookie Settings
- Mode = Use URI
- Regenerate expired session ID = true

Use hosting identity for impersonation = true
0
Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

 
LVL 75

Expert Comment

by:käµfm³d 👽
ID: 37784304
Do you have any calls to Session.Abandon in your code? If you do, perhaps one is being triggered inadvertently, which forces a new session on the next request to your site by a given user.
0
 
LVL 1

Author Comment

by:CipherIS
ID: 37784315
No - i don't have Session.Abandon in my code
0
 
LVL 75

Expert Comment

by:käµfm³d 👽
ID: 37784318
What specific behavior are you witnessing?
0
 
LVL 1

Author Comment

by:CipherIS
ID: 37784341
i click on a button which redirects me to a page.  I wait 1 minute - click on another button which goes to another page - no problem

I repeat above but wait 3 mins before clicking on button for redirect and the session is expired.
0
 
LVL 21

Expert Comment

by:masterpass
ID: 37784436
Do you perhaps have an inactivity detector in Javascript?
0
 
LVL 1

Author Comment

by:CipherIS
ID: 37787133
no - i don't
0
 
LVL 1

Author Comment

by:CipherIS
ID: 37787694
There is an error msg on the server in the Logs which says:

Session state is not available in this context at System.Web.HttpApplicaitonFactory.EnsureAppStartCalledForIntegratedMode (HttpContext.context, HttpApplicaiont app) at System.Web.HttpApplicaiton.RegisterEventSubscriptionWithIIS(InPtrSystem.Web.HttpApplication.RegisteredEventSbscriptionWithIIS .....
0
 
LVL 1

Author Comment

by:CipherIS
ID: 37797027
Anyone have any ideas?
0
 
LVL 7

Expert Comment

by:Lalit Chandra
ID: 37797127
r u using Asp.net Session object in Global.asax.cs file ??
0
 
LVL 1

Author Comment

by:CipherIS
ID: 37801679
No.  I tried to add it but it gave me an error.
0
 
LVL 7

Expert Comment

by:Lalit Chandra
ID: 37802409
please provide the full information or post the code that you think is the root cause of this problem. Is this session timeout issue happen on every page or any specific page or any specific event ??
0
 
LVL 1

Author Comment

by:CipherIS
ID: 37838414
still troubleshooting.
0
 
LVL 1

Accepted Solution

by:
CipherIS earned 0 total points
ID: 37863160
It seems to be a problem with the VM.  I copied the code to prod and not having the issue.  Something has to be recycling to cause the problem.
0
 
LVL 1

Author Closing Comment

by:CipherIS
ID: 37880023
its an issue on Dev server where worker process is recycling
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Problem Hi all,    While many today have fast Internet connection, there are many still who do not, or are connecting through devices with a slower connect, so light web pages and fast load times are still popular.    If your ASP.NET page …
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …

650 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question