Home > Archive > MS SQL Server > December 2006 > Does SQL Server 2005 Clean Up Unclosed Connections?









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Does SQL Server 2005 Clean Up Unclosed Connections?
Simon Harvey

2006-12-13, 5:18 am

Hi all,

I have a quick question with regards to how SQL Server (2005) will treat
conncetions that are left open (due to a programmer forgetting to close
them in a .net web app).

I'm basically wondering if they'll just sit their indefinately, or will
SQL Server kill them after a period of inactivity? If it will eventually
kill them off, what is the period of time that it will wait for?

Thanks to anyone who can advise

Simon
Tibor Karaszi

2006-12-13, 7:12 pm

SQL Server will kill (first rollback if necessary) the connections when the network layer had
informed that this is no more.

--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www. solidqualitylearning
.com/



"Simon Harvey" <nothanks@hotmail.com> wrote in message
news:%23k1h3RqHHHA.420@TK2MSFTNGP02.phx.gbl...
> Hi all,
>
> I have a quick question with regards to how SQL Server (2005) will treat conncetions that are left
> open (due to a programmer forgetting to close them in a .net web app).
>
> I'm basically wondering if they'll just sit their indefinately, or will SQL Server kill them after
> a period of inactivity? If it will eventually kill them off, what is the period of time that it
> will wait for?
>
> Thanks to anyone who can advise
>
> Simon



Simon Harvey

2006-12-13, 7:12 pm

Hi there

OK - now what will cause the network layer that the connection is no
more? The application or website being restarted?

Thanks

Simon

Tibor Karaszi wrote:
> SQL Server will kill (first rollback if necessary) the connections when the network layer had
> informed that this is no more.
>

Tibor Karaszi

2006-12-13, 7:12 pm

I guess that is more a question to the networking people. But if you terminate the application, I'd
assume that the network layer will report that the TCP session (for instance) has been terminated.

--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www. solidqualitylearning
.com/



"Simon Harvey" <nothanks@hotmail.com> wrote in message news:Or9TxGtHHHA.1784@TK2MSFTNGP06.phx.gbl...[color=darkred]
> Hi there
>
> OK - now what will cause the network layer that the connection is no more? The application or
> website being restarted?
>
> Thanks
>
> Simon
>
> Tibor Karaszi wrote:


Sponsored Links





Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive | Programming forum archive

Copyright 2008 droptable.com