I have set up an app with Asp.net 2.0 Membership. I want to have it so when the user logs in, he stays logged in for a complete day. I have set this in my web.config <authentication mode="forms"> <forms timeout ="480"> </authentication> 480, being minutes, what is 8*60 for a full work day. But my clients are still having to log in after in-activity
We host each website in its unique application pool / process. To conserve memory, we recycle the application if any of the following condition is met 1) More than 20 minutes of idle time (no http request in 20 minutes) 2) The application uses more than 100 MB memory 3) The application uses more than 75% of CPU time You may want to think about storing your session on the SQL server. Try looking at this kb article. http://support.Winhost.com/KB/a626/how-to-enable-aspnet-sql-server-session-on-your-web.aspx
Ok, tried that .... with my first test I waited 1 hours, and booted. On my second, waited 20 mins, and worked. Any other settings I should be concerned with?
So as long as I use the SQL Session, even when your worker process is recycled, my client should not lose his session?
The session yes. But bear in mind that some .Net applications are setup to also use the viewstate along with the session. The viewstate is not stored on the SQL server. If your .Net applications uses viewstate, you may need to disable it or define the machine key rather then having the application auto generate it.
Still having some issues here. And I have to start here because, I have the exact setup on my machine, and I get no log outs. As soon as it is published to the server and ran off the server I start to get logouts. I shouldn't call it timeouts but that is how the client understands it. Basicaly I am losing my session, esp when the app reports are being ran. I had super issues until I upgraded to the max account, and so I am thinking there is some sort of memory issue. Ideas? Even some direction to how to troubleshoot. But today, I had to log in each time I ran a report.
Have you checked the session timeout setting in your application? If you are using viewstate you should configure it to not automatically generate a machine key but rather use a predefined machine key that you input.