Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is the difference between web.config timeout and IIS timeout?

What is the difference between the following entry in web.config:

 <sessionState timeout="30"/>

And this setting in IIS 7.5 (Default web site > Advanced Settings > Connection Limits) :

enter image description here

I know that the web.config is supposed to apply to the time that the ASP.NET session is kept alive, but what is the IIS setting for?

like image 241
333Mhz Avatar asked Aug 03 '11 06:08

333Mhz


People also ask

What is IIS connection timeout?

The ConnectionTimeout property specifies the amount of time (in seconds) that the server waits before disconnecting an inactive connection. Specify a value between 1 and 65535 (0xffff). If a value outside of this range is specified, IIS uses the default of 120 seconds.

What is timeout in web config?

The timeout attribute specifies the number of minutes a session can be idle before it is abandoned. The default value for this attribute is 20. By assigning a value of 1 to this attribute, you've set the session to be abandoned in 1 minute after its idle.

How do I set connection timeout in IIS?

Expand the local computer node, expand "Web Sites", right-click the appropriate website, point to "Manage Web Site", click Advanced Settings. 3.In the Advanced Settings window, expand Connection Limits, change the value in the "Connection time-out" field, and then click OK.

What is the maximum execution timeout in web config?

Adjustments to ASP.Net configuration Increase the timeout span for your web application. Add or edit the executionTimeout attribute, giving it a higher value. The default value is 110 seconds and the maximum value is 999999 seconds.


1 Answers

The connection timeout is how long a connection from a browser to the server should take till it times out. So, when the browser requests a page/image/resource, how long should IIS wait till it terminates the connection. It is stated in seconds.

It can also be set in the web.config (example is for 2 minutes, 120 seconds):

<limits connectionTimeout="00:02:00" />

The session timeout is how long the session can live. This is across multiple connections and is stated in minutes.

They are two different settings that control different things.

like image 168
Oded Avatar answered Sep 21 '22 08:09

Oded