473,289 Members | 2,089 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,289 software developers and data experts.

Override Session Timeout

I am deploying to a web environment that uses load balancing and to insure
that sessions persist across servers, the environment uses SQL to manage
sessions. The machine.config file determines how all applications will use
sessions and to insure that all application use this method, the session
properties cannot be overriden.

Within the sessionstate tags, the webadmin (upon my request)r emoved the
property for timeout, hoping that individual applications could override the
default of 20 minutes. I have a web application that I'm trying to deploy to
this environment and no matter what I do, I cannot increase the session
timeout for the application (or a particular page). Due to a large form the
users must fillout, I must have a session that persists longer than 20
minutes. Is there any way to override this. I've tried using several
methods including setting the session.timeout property in the session_start
event in global.aspx.db. I also have tried setting it in the page load event
of the page where I need the session to persist > 20 minutes. In order to
just get the application to work, I've had to comment out the sessionstate
tags altogether in the web.config file (probably because machine.config is
set to not override for sessionstate). Mode is required property of this tag
anyways and that is something I don't want to override. Any help would be
greatly appreciated.
--
Will
Nov 19 '05 #1
8 5451
Hey,

First of all i am not sure if i understood your problem but here goes anyways

According to you

1) The machine.config always overrides the settigns in web.config
2) You have removed the timeout in machine.config
3) inspite of you changing the session timeout at your side everytime 20
mins it timedout.

well according to my understanding of your problem from above :-

a) The default timeout for session is 20 mins ,hence as far as my
understanding goes even by removing the timeout attribute in machine.config
it will still take the dafult 20 mins timeout.
b) Inspite of you making changes to timeout at your end its taking the 20
mins timeout and as per your point 1) above i guess the attribute has a <
allowOverride=”false” > which isnt allowing the application config to
override the machine.config. Hence you are not being able to override the
machine.config settings.
Check this link for help :-

http://support.microsoft.com/kb/815174

Let me know what happens

"bdeviled" wrote:
I am deploying to a web environment that uses load balancing and to insure
that sessions persist across servers, the environment uses SQL to manage
sessions. The machine.config file determines how all applications will use
sessions and to insure that all application use this method, the session
properties cannot be overriden.

Within the sessionstate tags, the webadmin (upon my request)r emoved the
property for timeout, hoping that individual applications could override the
default of 20 minutes. I have a web application that I'm trying to deploy to
this environment and no matter what I do, I cannot increase the session
timeout for the application (or a particular page). Due to a large form the
users must fillout, I must have a session that persists longer than 20
minutes. Is there any way to override this. I've tried using several
methods including setting the session.timeout property in the session_start
event in global.aspx.db. I also have tried setting it in the page load event
of the page where I need the session to persist > 20 minutes. In order to
just get the application to work, I've had to comment out the sessionstate
tags altogether in the web.config file (probably because machine.config is
set to not override for sessionstate). Mode is required property of this tag
anyways and that is something I don't want to override. Any help would be
greatly appreciated.
--
Will

Nov 19 '05 #2
In addition to what Shaun wrote... Did you adjust the time out value in the
web.config file?

<sessionState
mode="InProc"
stateConnectionString="tcpip=127.0.0.1:42424"
sqlConnectionString="data source=127.0.0.1;Trusted_Connection=yes"
cookieless="false"
timeout="20"
/>

Kind regards,
Nikander & Margriet Bruggeman

"Shaun" wrote:
Hey,

First of all i am not sure if i understood your problem but here goes anyways

According to you

1) The machine.config always overrides the settigns in web.config
2) You have removed the timeout in machine.config
3) inspite of you changing the session timeout at your side everytime 20
mins it timedout.

well according to my understanding of your problem from above :-

a) The default timeout for session is 20 mins ,hence as far as my
understanding goes even by removing the timeout attribute in machine.config
it will still take the dafult 20 mins timeout.
b) Inspite of you making changes to timeout at your end its taking the 20
mins timeout and as per your point 1) above i guess the attribute has a <
allowOverride=”false” > which isnt allowing the application config to
override the machine.config. Hence you are not being able to override the
machine.config settings.
Check this link for help :-

http://support.microsoft.com/kb/815174

Let me know what happens

"bdeviled" wrote:
I am deploying to a web environment that uses load balancing and to insure
that sessions persist across servers, the environment uses SQL to manage
sessions. The machine.config file determines how all applications will use
sessions and to insure that all application use this method, the session
properties cannot be overriden.

Within the sessionstate tags, the webadmin (upon my request)r emoved the
property for timeout, hoping that individual applications could override the
default of 20 minutes. I have a web application that I'm trying to deploy to
this environment and no matter what I do, I cannot increase the session
timeout for the application (or a particular page). Due to a large form the
users must fillout, I must have a session that persists longer than 20
minutes. Is there any way to override this. I've tried using several
methods including setting the session.timeout property in the session_start
event in global.aspx.db. I also have tried setting it in the page load event
of the page where I need the session to persist > 20 minutes. In order to
just get the application to work, I've had to comment out the sessionstate
tags altogether in the web.config file (probably because machine.config is
set to not override for sessionstate). Mode is required property of this tag
anyways and that is something I don't want to override. Any help would be
greatly appreciated.
--
Will

Nov 19 '05 #3
Hi Shaun. I believe you have the problem exactly right. From looking at
the link you provided me, I'm guessing that there is no way for me to
override this setting. Our web admin will not remove the
allowoverride=false from the machine.config file for the machine sessionstate
and for good reason (we have a web farm and we can't risk having applications
deployed that don't use SQL for session state). However, it is extremely
frustrating that I cannot override the timeout property for one page because
the web admin has no problem with me overriding that particular property of
the sessionstate. If I misunderstood the link you sent me, please let me
know. Thank you for your assistance.

"Shaun" wrote:
Hey,

First of all i am not sure if i understood your problem but here goes anyways

According to you

1) The machine.config always overrides the settigns in web.config
2) You have removed the timeout in machine.config
3) inspite of you changing the session timeout at your side everytime 20
mins it timedout.

well according to my understanding of your problem from above :-

a) The default timeout for session is 20 mins ,hence as far as my
understanding goes even by removing the timeout attribute in machine.config
it will still take the dafult 20 mins timeout.
b) Inspite of you making changes to timeout at your end its taking the 20
mins timeout and as per your point 1) above i guess the attribute has a <
allowOverride=”false” > which isnt allowing the application config to
override the machine.config. Hence you are not being able to override the
machine.config settings.
Check this link for help :-

http://support.microsoft.com/kb/815174

Let me know what happens

"bdeviled" wrote:
I am deploying to a web environment that uses load balancing and to insure
that sessions persist across servers, the environment uses SQL to manage
sessions. The machine.config file determines how all applications will use
sessions and to insure that all application use this method, the session
properties cannot be overriden.

Within the sessionstate tags, the webadmin (upon my request)r emoved the
property for timeout, hoping that individual applications could override the
default of 20 minutes. I have a web application that I'm trying to deploy to
this environment and no matter what I do, I cannot increase the session
timeout for the application (or a particular page). Due to a large form the
users must fillout, I must have a session that persists longer than 20
minutes. Is there any way to override this. I've tried using several
methods including setting the session.timeout property in the session_start
event in global.aspx.db. I also have tried setting it in the page load event
of the page where I need the session to persist > 20 minutes. In order to
just get the application to work, I've had to comment out the sessionstate
tags altogether in the web.config file (probably because machine.config is
set to not override for sessionstate). Mode is required property of this tag
anyways and that is something I don't want to override. Any help would be
greatly appreciated.
--
Will

Nov 19 '05 #4
I cannot put the sessionstate tag, at all, in my web.config file because the
machine.config does not allow overrides for this particular setting (see
Shaun response). The app will not even run if I have anything for
sessionstate. I'm really looking for the ability to override the session
timout property in code for one page. For example, session.timeout=60 on
page load event.

"Nikander & Margriet Bruggeman" wrote:
In addition to what Shaun wrote... Did you adjust the time out value in the
web.config file?

<sessionState
mode="InProc"
stateConnectionString="tcpip=127.0.0.1:42424"
sqlConnectionString="data source=127.0.0.1;Trusted_Connection=yes"
cookieless="false"
timeout="20"
/>

Kind regards,
Nikander & Margriet Bruggeman

"Shaun" wrote:
Hey,

First of all i am not sure if i understood your problem but here goes anyways

According to you

1) The machine.config always overrides the settigns in web.config
2) You have removed the timeout in machine.config
3) inspite of you changing the session timeout at your side everytime 20
mins it timedout.

well according to my understanding of your problem from above :-

a) The default timeout for session is 20 mins ,hence as far as my
understanding goes even by removing the timeout attribute in machine.config
it will still take the dafult 20 mins timeout.
b) Inspite of you making changes to timeout at your end its taking the 20
mins timeout and as per your point 1) above i guess the attribute has a <
allowOverride=”false” > which isnt allowing the application config to
override the machine.config. Hence you are not being able to override the
machine.config settings.
Check this link for help :-

http://support.microsoft.com/kb/815174

Let me know what happens

"bdeviled" wrote:
I am deploying to a web environment that uses load balancing and to insure
that sessions persist across servers, the environment uses SQL to manage
sessions. The machine.config file determines how all applications will use
sessions and to insure that all application use this method, the session
properties cannot be overriden.

Within the sessionstate tags, the webadmin (upon my request)r emoved the
property for timeout, hoping that individual applications could override the
default of 20 minutes. I have a web application that I'm trying to deploy to
this environment and no matter what I do, I cannot increase the session
timeout for the application (or a particular page). Due to a large form the
users must fillout, I must have a session that persists longer than 20
minutes. Is there any way to override this. I've tried using several
methods including setting the session.timeout property in the session_start
event in global.aspx.db. I also have tried setting it in the page load event
of the page where I need the session to persist > 20 minutes. In order to
just get the application to work, I've had to comment out the sessionstate
tags altogether in the web.config file (probably because machine.config is
set to not override for sessionstate). Mode is required property of this tag
anyways and that is something I don't want to override. Any help would be
greatly appreciated.
--
Will

Nov 19 '05 #5
Hi bdeviled,
As far as i am aware of, till the time your Admin gets rid of the <
allowOverride=”false > tag from the machine.config file you wont be able to
override the Session time out.
Will try and find out if thats possible by having some workaround and get
abck to you,but i dont think it might be possible.

The best option is for you to convince your Admin or get the server changed :)

***************************
Shaun, M.C.P (70-315)
http://blogs.wwwcoder.com/shaunakp
***************************
"bdeviled" wrote:
Hi Shaun. I believe you have the problem exactly right. From looking at
the link you provided me, I'm guessing that there is no way for me to
override this setting. Our web admin will not remove the
allowoverride=false from the machine.config file for the machine sessionstate
and for good reason (we have a web farm and we can't risk having applications
deployed that don't use SQL for session state). However, it is extremely
frustrating that I cannot override the timeout property for one page because
the web admin has no problem with me overriding that particular property of
the sessionstate. If I misunderstood the link you sent me, please let me
know. Thank you for your assistance.

"Shaun" wrote:
Hey,

First of all i am not sure if i understood your problem but here goes anyways

According to you

1) The machine.config always overrides the settigns in web.config
2) You have removed the timeout in machine.config
3) inspite of you changing the session timeout at your side everytime 20
mins it timedout.

well according to my understanding of your problem from above :-

a) The default timeout for session is 20 mins ,hence as far as my
understanding goes even by removing the timeout attribute in machine.config
it will still take the dafult 20 mins timeout.
b) Inspite of you making changes to timeout at your end its taking the 20
mins timeout and as per your point 1) above i guess the attribute has a <
allowOverride=”false” > which isnt allowing the application config to
override the machine.config. Hence you are not being able to override the
machine.config settings.
Check this link for help :-

http://support.microsoft.com/kb/815174

Let me know what happens

"bdeviled" wrote:
I am deploying to a web environment that uses load balancing and to insure
that sessions persist across servers, the environment uses SQL to manage
sessions. The machine.config file determines how all applications will use
sessions and to insure that all application use this method, the session
properties cannot be overriden.

Within the sessionstate tags, the webadmin (upon my request)r emoved the
property for timeout, hoping that individual applications could override the
default of 20 minutes. I have a web application that I'm trying to deploy to
this environment and no matter what I do, I cannot increase the session
timeout for the application (or a particular page). Due to a large form the
users must fillout, I must have a session that persists longer than 20
minutes. Is there any way to override this. I've tried using several
methods including setting the session.timeout property in the session_start
event in global.aspx.db. I also have tried setting it in the page load event
of the page where I need the session to persist > 20 minutes. In order to
just get the application to work, I've had to comment out the sessionstate
tags altogether in the web.config file (probably because machine.config is
set to not override for sessionstate). Mode is required property of this tag
anyways and that is something I don't want to override. Any help would be
greatly appreciated.
--
Will

Nov 19 '05 #6
Thank you Shaun. I've tried several things to override this and I think
you're correct. Convincing my web admin will be quite a task. I don't think
he'll want to risk having an application deployed that is using mode=inproc,
on our server farm. If you have any alternatives I might suggest to him
regarding that issue, that would be very helpful. Again, thank you for your
assistance.

"Shaun" wrote:
Hi bdeviled,
As far as i am aware of, till the time your Admin gets rid of the <
allowOverride=”false > tag from the machine.config file you wont be able to
override the Session time out.
Will try and find out if thats possible by having some workaround and get
abck to you,but i dont think it might be possible.

The best option is for you to convince your Admin or get the server changed :)

***************************
Shaun, M.C.P (70-315)
http://blogs.wwwcoder.com/shaunakp
***************************
"bdeviled" wrote:
Hi Shaun. I believe you have the problem exactly right. From looking at
the link you provided me, I'm guessing that there is no way for me to
override this setting. Our web admin will not remove the
allowoverride=false from the machine.config file for the machine sessionstate
and for good reason (we have a web farm and we can't risk having applications
deployed that don't use SQL for session state). However, it is extremely
frustrating that I cannot override the timeout property for one page because
the web admin has no problem with me overriding that particular property of
the sessionstate. If I misunderstood the link you sent me, please let me
know. Thank you for your assistance.

"Shaun" wrote:
Hey,

First of all i am not sure if i understood your problem but here goes anyways

According to you

1) The machine.config always overrides the settigns in web.config
2) You have removed the timeout in machine.config
3) inspite of you changing the session timeout at your side everytime 20
mins it timedout.

well according to my understanding of your problem from above :-

a) The default timeout for session is 20 mins ,hence as far as my
understanding goes even by removing the timeout attribute in machine.config
it will still take the dafult 20 mins timeout.
b) Inspite of you making changes to timeout at your end its taking the 20
mins timeout and as per your point 1) above i guess the attribute has a <
allowOverride=”false” > which isnt allowing the application config to
override the machine.config. Hence you are not being able to override the
machine.config settings.
Check this link for help :-

http://support.microsoft.com/kb/815174

Let me know what happens

"bdeviled" wrote:

> I am deploying to a web environment that uses load balancing and to insure
> that sessions persist across servers, the environment uses SQL to manage
> sessions. The machine.config file determines how all applications will use
> sessions and to insure that all application use this method, the session
> properties cannot be overriden.
>
> Within the sessionstate tags, the webadmin (upon my request)r emoved the
> property for timeout, hoping that individual applications could override the
> default of 20 minutes. I have a web application that I'm trying to deploy to
> this environment and no matter what I do, I cannot increase the session
> timeout for the application (or a particular page). Due to a large form the
> users must fillout, I must have a session that persists longer than 20
> minutes. Is there any way to override this. I've tried using several
> methods including setting the session.timeout property in the session_start
> event in global.aspx.db. I also have tried setting it in the page load event
> of the page where I need the session to persist > 20 minutes. In order to
> just get the application to work, I've had to comment out the sessionstate
> tags altogether in the web.config file (probably because machine.config is
> set to not override for sessionstate). Mode is required property of this tag
> anyways and that is something I don't want to override. Any help would be
> greatly appreciated.
> --
> Will

Nov 19 '05 #7
I have a similar problem.
In my machine.config file, httpRuntime
executionTimeout="90".
and it dosent have <location> attribute nad
<allowOverride> attribute.
But my thread dies off after 1hr.
In the web.config, i have given httpRuntime
executionTimeout="7200"

Why is this happening?

-----Original Message-----
Hey,

First of all i am not sure if i understood your problem but here goes anyways
According to you

1) The machine.config always overrides the settigns in web.config2) You have removed the timeout in machine.config
3) inspite of you changing the session timeout at your side everytime 20 mins it timedout.

well according to my understanding of your problem from above :-
a) The default timeout for session is 20 mins ,hence as far as my understanding goes even by removing the timeout attribute in machine.config it will still take the dafult 20 mins timeout.
b) Inspite of you making changes to timeout at your end its taking the 20 mins timeout and as per your point 1) above i guess the attribute has a < allowOverride=?false? > which isnt allowing the application config to override the machine.config. Hence you are not being able to override the machine.config settings.
Check this link for help :-

http://support.microsoft.com/kb/815174

Let me know what happens

"bdeviled" wrote:
I am deploying to a web environment that uses load balancing and to insure that sessions persist across servers, the environment uses SQL to manage sessions. The machine.config file determines how all applications will use sessions and to insure that all application use this method, the session properties cannot be overriden.

Within the sessionstate tags, the webadmin (upon my request)r emoved the property for timeout, hoping that individual applications could override the default of 20 minutes. I have a web application that I'm trying to deploy to this environment and no matter what I do, I cannot increase the session timeout for the application (or a particular page). Due to a large form the users must fillout, I must have a session that persists longer than 20 minutes. Is there any way to override this. I've tried using several methods including setting the session.timeout property in the session_start event in global.aspx.db. I also have tried setting it in the page load event of the page where I need the session to persist > 20 minutes. In order to just get the application to work, I've had to comment out the sessionstate tags altogether in the web.config file (probably because machine.config is set to not override for sessionstate). Mode is required property of this tag anyways and that is something I don't want to override. Any help would be greatly appreciated.
--
Will

.

Nov 19 '05 #8
lekshmi,

check the setting in machine.config
maybe thats where it is 1 hr
********************************
Hope this helps,
Shaun (M.C.P)

http://blogs.wwwcoder.com/shaunakp
*********************************
"lekshmi" wrote:
I have a similar problem.
In my machine.config file, httpRuntime
executionTimeout="90".
and it dosent have <location> attribute nad
<allowOverride> attribute.
But my thread dies off after 1hr.
In the web.config, i have given httpRuntime
executionTimeout="7200"

Why is this happening?

-----Original Message-----
Hey,

First of all i am not sure if i understood your problem

but here goes anyways

According to you

1) The machine.config always overrides the settigns in

web.config
2) You have removed the timeout in machine.config
3) inspite of you changing the session timeout at your

side everytime 20
mins it timedout.

well according to my understanding of your problem from

above :-

a) The default timeout for session is 20 mins ,hence as

far as my
understanding goes even by removing the timeout attribute

in machine.config
it will still take the dafult 20 mins timeout.
b) Inspite of you making changes to timeout at your end

its taking the 20
mins timeout and as per your point 1) above i guess the

attribute has a <
allowOverride=�false� > which isnt allowing the

application config to
override the machine.config. Hence you are not being able

to override the
machine.config settings.
Check this link for help :-

http://support.microsoft.com/kb/815174

Let me know what happens

"bdeviled" wrote:
I am deploying to a web environment that uses load balancing and to insure that sessions persist across servers, the environment uses SQL to manage sessions. The machine.config file determines how all applications will use sessions and to insure that all application use this method, the session properties cannot be overriden.

Within the sessionstate tags, the webadmin (upon my request)r emoved the property for timeout, hoping that individual applications could override the default of 20 minutes. I have a web application that I'm trying to deploy to this environment and no matter what I do, I cannot increase the session timeout for the application (or a particular page). Due to a large form the users must fillout, I must have a session that persists longer than 20 minutes. Is there any way to override this. I've tried using several methods including setting the session.timeout property in the session_start event in global.aspx.db. I also have tried setting it in the page load event of the page where I need the session to persist > 20 minutes. In order to just get the application to work, I've had to comment out the sessionstate tags altogether in the web.config file (probably because machine.config is set to not override for sessionstate). Mode is required property of this tag anyways and that is something I don't want to override. Any help would be greatly appreciated.
--
Will

.

Nov 19 '05 #9

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

Similar topics

12
by: Geigho | last post by:
Setting session timeout in web.config file does not seem to have any effect. Any explanation or suggestion will be appreciated.
4
by: DavidS | last post by:
First: There are several ways to confuse one regarding session timeout. (1) web.config - <sessionState timeout="20"> (2) IIS Manager | Internet Information Services | ServerNode | Default Web Site...
11
by: Vishal | last post by:
Hello, can anybody tell me how I can extend the session expiry time? Is it done via code or via IIS? Sorry I am new and dont know about this.
2
by: lekshmi | last post by:
In my machine.config file, httpRuntime executionTimeout="90". and it dosent have <location> attribute nad <allowOverride> attribute. But my thread dies off after 1hr. In the web.config, i have...
1
by: RUSSELL MCGINNIS | last post by:
I have a web site that uses Form Authentication with the Session timeout set to 20 minutes, however one of the pages refreshes itself every 30 seconds. Is there a way to override the session...
17
by: jensen bredal | last post by:
Hello, i'm struggling with a somehow badly understood session scenario. I provide acces to my pages based on form authentication using Session cookies. Som of my pages are supposed to be...
4
by: UJ | last post by:
I have a page where the user can upload a video file. As you can guess, this may take a while. Is there a way I can change the session timeout for just this one page? I would also want to change...
25
by: =?Utf-8?B?RGF2aWQgVGhpZWxlbg==?= | last post by:
I tried: <sessionState timeout="1"> </sessionState> bounced IIS, and after 1 minute still had a session. ??? -- thanks - dave
6
by: ChrisAtWokingham | last post by:
I have been struggling with unexpected error messages on an ASP.NET system, using SQL and C#. The application draws organisation charts, based on data stored in the SQL database. Some of the chart...
2
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 7 Feb 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:30 (7.30PM). In this month's session, the creator of the excellent VBE...
0
by: MeoLessi9 | last post by:
I have VirtualBox installed on Windows 11 and now I would like to install Kali on a virtual machine. However, on the official website, I see two options: "Installer images" and "Virtual machines"....
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: marcoviolo | last post by:
Dear all, I would like to implement on my worksheet an vlookup dynamic , that consider a change of pivot excel via win32com, from an external excel (without open it) and save the new file into a...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...

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.