Results 1 to 7 of 7
  1. #1

    Question Session Timeout too short

    Hi Guys

    I'm having an issue with my session timeout, which is 6 minutes, even though it's correctly set to 20 minutes in web.config. I spent some hours with online support last night, but we couldn't figure it out.

    For testing, I created a page casualx.ch/sessions.aspx, where you can see your session id plus the last 20 sessions. Refresh it after 7 minutes, and you will see you have a new Session Id.

    I have built a work-around with some javscript calling a dummy page every minute, which is far from what i call sexy

    Any help will be appreciated!
    Thanks
    Martin

  2. #2
    Join Date
    Sep 2011
    Posts
    139

    Default

    Hello Martin,

    I've had a senior admin to look into your issue and according to him, the issue seems to be with the site and not with the configuration, we cannot do anything else other than applying the standard IIS settings.

    In the web.config file we can see that it has been set to 20 and all the other settings seems to be fine as well.

    Please refer to the session id 481 (Casual X) where it got timed out in approximately 13 mins. There aren't any special settings which we can configure that would last the session to specific 20 mins.

    We request you to kindly look at the application that you are running. If you want us to do some specific configuration changes for your site then please let us know so we'll configure it for you.
    Web Hosting UK | Cloud Servers | SSL Certificate
    Best Paying Affiliate Programs offered by Eukhost Ltd.

  3. #3
    Join Date
    Sep 2011
    Posts
    139

    Default

    Hello Martin,

    I request you to kindly take a look at the session id : 488, there you can see that the time-out was approx. 34 minutes. This can be considered as strong pointer towards the chance that it doesn't depend completely on the configuration but on the application as well.

    Regards,
    Stan
    Web Hosting UK | Cloud Servers | SSL Certificate
    Best Paying Affiliate Programs offered by Eukhost Ltd.

  4. #4

    Default

    Hello Stan

    Thank you very much for your research and your kind support so far! Yesterday I added a logging to the application_start event in global.asax. The event fired as follows:

    Application started at 00:29
    Application started at 03:52
    Application started at 04:49
    Application started at 05:35
    Application started at 05:41
    Application started at 06:29
    Application started at 11:51
    Application started at 11:52
    Application started at 12:06
    Application started at 12:21
    Application started at 12:30
    Application started at 12:39
    Application started at 12:47
    Application started at 12:57
    Application started at 14:39
    Application started at 14:55

    this matches quite well the sessions. So it looks like the sessions get killed because the application ends. This also explains why session 488 is that long: Session 487, which was on the real page, kept the application from ending, because i have a javascript loop on the pages which calls the site every minute, to avoid session expiration (my workaround...).

    Do you have any idea why the application could be ending? I can't imagine how my code can cause this. I also dont have the effect on my test system. The only thing I could imagine is an application pool issue. Do you have any logging that could be helpful?

    Thank you very much!
    Martin

  5. #5
    Join Date
    Sep 2011
    Posts
    139

    Default

    Hello Martin,

    Thats quite obvious, the application stops if there isn't any request to the site, as soon as it gets a request , the application restarts.

    We can configure the idle time-out settings for an application pool so that it doesn't get timed out and stop if there is no request for the site. The idle time out was set to a default value of 5 mins, we've now set it to 30 mins.

    Kindly check and let us know if things are working as per your expectations.

    Thank you.

    Regards,
    Stan
    Web Hosting UK | Cloud Servers | SSL Certificate
    Best Paying Affiliate Programs offered by Eukhost Ltd.

  6. #6

    Default

    Hello Stan

    Thank you for fixing it, that did the job. In my opinion it's good practice to set the app pool idle timeout to a value not less than the default session timeout. As I had mentioned this point with live support already, i assumed the timeout was set to 20 minutes. Anyway, I'm glad it's all working now.

    Thank you very much!
    Kind regards
    Martin

  7. #7
    Join Date
    Sep 2011
    Posts
    139

    Default

    Hello Martin,

    You are Welcome and thanks for the update. Pleased to know that its working according to your expectations.

    Do let us know if you need anymore help on this, we'd be glad to offer assistance.

    Kind Regards,
    Stan
    Web Hosting UK | Cloud Servers | SSL Certificate
    Best Paying Affiliate Programs offered by Eukhost Ltd.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •