So, how do I monitor *open* connections?

  • Thread starter Thread starter Sgt. Sausage
  • Start date Start date
S

Sgt. Sausage

I can look at performance monitor for pools, pooled
connections etc. What I don't see is a way to tell, say,
of the 25 pooled connections in the pool, how many are
active and open.

Anyone know of any tools for this?

Any ideas?

Anyone ...
 
I knew somebody would use that answer. Yes, sp_who, and sp_who2
work. Sorry I didn't make myself clear -- I want to monitor in
real time and watch stuff happening "live" like with the performance
counters.
 
I knew somebody would use that answer. Yes, sp_who, and sp_who2
work. Sorry I didn't make myself clear -- I want to monitor in
real time and watch stuff happening "live" like with the performance
counters.

What's wrong with SQL Server's own performance counters?

Massimo
 
The SqlClient performance counters in the 1.1 Framework are notoriously
buggy and unreliable. The SQL Server General Statistics User Connections (of
the top of my head) return an accurate count of the number of user
connections regardless of process. The 2.0 Framework has all new counters
that I have not played with so far, but they are supposed to be fixed.

--
____________________________________
William (Bill) Vaughn
Author, Mentor, Consultant
Microsoft MVP
www.betav.com/blog/billva
www.betav.com
Please reply only to the newsgroup so that others can benefit.
This posting is provided "AS IS" with no warranties, and confers no rights.
__________________________________
 
If you are using the .NET framework for your program, you can hook to the
StateChange events of the SqlConnection objects you are creating to have
some code of yours called when the connections get opened or closed.
That way, you will have a live picture of what conenctions are opened.
 
Yes, but these don't work when the server closes the connection from its
end. That won't be a feature until ADO.NET 2.0.

--
____________________________________
William (Bill) Vaughn
Author, Mentor, Consultant
Microsoft MVP
www.betav.com/blog/billva
www.betav.com
Please reply only to the newsgroup so that others can benefit.
This posting is provided "AS IS" with no warranties, and confers no rights.
__________________________________
 
Back
Top