Please start any new threads on our new site at We've got lots of great SQL Server experts to answer whatever question you can come up with.

Our new SQL Server Forums are live! Come on over! We've restricted the ability to create new threads on these forums.

SQL Server Forums
Profile | Active Topics | Members | Search | Forum FAQ
Save Password
Forgot your Password?

 All Forums
 General SQL Server Forums
 New to SQL Server Administration
 SA login usage tracking
 Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Yak Posting Veteran

64 Posts

Posted - 01/22/2013 :  10:28:40  Show Profile  Reply with Quote
While I was on vacation, my boss gave the sa password out to a couple people in our finance department. Now I have to change it for the first time in a few years (no IT turnover).

What's the best way to trace what programs are using the sa login to access the databases?

I'm guessing I could run a trace on the sa login for a day or so and that should catch most of the programs that connect, and the HostName field should tell me which PC's are connecting, but what's the best filter I can use so a 24 hour trace doesn't bog down the server?

I've run some SQL profilers to try and see what programs use it for access, but the trace fills up pretty quickly with thousands or records. We've been bad in the past with setting up 3rd party access with the sa password, trying to slowly remedy that. But now because these users have the sa password and the ability to connect to the database to run queries with the sa login, I'm panicking a bit and feel the need to change it asap.

Almighty SQL Goddess

38200 Posts

Posted - 01/22/2013 :  13:52:50  Show Profile  Visit tkizer's Homepage  Reply with Quote
A trace with a filter for sa is not going to bog down the server, but alternatively you could query sysprocesses for the info say once a minute.

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server

Subscribe to my blog
Go to Top of Page

Starting Member

35 Posts

Posted - 01/26/2013 :  12:42:38  Show Profile  Reply with Quote
or you could create a logon trigger and insert the results into a table. :)
Go to Top of Page

Flowing Fount of Yak Knowledge

United Kingdom
2179 Posts

Posted - 01/27/2013 :  02:17:59  Show Profile  Visit jackv's Homepage  Reply with Quote
Are the users actually supposed to be logging on with sa? If not , and you feel confident you won't break the applications, why don't you change the sa password - and issue users with a logon with less privileges?

Jack Vamvas
Go to Top of Page
  Previous Topic Topic Next Topic  
 Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.04 seconds. Powered By: Snitz Forums 2000