422,946 Members | 1,131 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 422,946 IT Pros & Developers. It's quick & easy.

Override Session Timeout

P: n/a
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
Share this Question
Share on Google+
8 Replies


P: n/a
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

P: n/a
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

P: n/a
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

P: n/a
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

P: n/a
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

P: n/a
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

P: n/a
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

P: n/a
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 discussion thread is closed

Replies have been disabled for this discussion.