Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase

How to find who changed the database to Single_user mode. Expand / Collapse
Author
Message
Posted Thursday, July 4, 2013 3:55 AM
SSC Rookie

SSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC RookieSSC Rookie

Group: General Forum Members
Last Login: Wednesday, March 5, 2014 2:59 AM
Points: 31, Visits: 205

Hi All,

One of our databases changed to single_user mode. But we could not find the exact user, hostname etc. Is there is any way to find these details?
I had gone through the SQL Server Error logs and Windows event error logs. But could find the exact user who changed the database to single_user mode? Do database automatically changed to single user mode?

Regards,
Varun
Post #1470376
Posted Thursday, July 4, 2013 4:04 AM


SSC-Forever

SSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-ForeverSSC-Forever

Group: General Forum Members
Last Login: Yesterday @ 1:14 PM
Points: 40,615, Visits: 37,081
SQL will never automatically change the recovery model. If it was changed, someone changed it.

Check the default trace, if the change was recent enough it may still be in there.



Gail Shaw
Microsoft Certified Master: SQL Server 2008, MVP
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability

We walk in the dark places no others will enter
We stand on the bridge and no one may pass

Post #1470383
Posted Friday, July 5, 2013 8:17 AM
UDP Broadcaster

UDP BroadcasterUDP BroadcasterUDP BroadcasterUDP BroadcasterUDP BroadcasterUDP BroadcasterUDP BroadcasterUDP Broadcaster

Group: General Forum Members
Last Login: 2 days ago @ 8:05 AM
Points: 1,445, Visits: 2,163
If the security's tight (which is rarely the case, from experience taking on new DB), in SQL you can track who has the ALTER DATABASE permission.

But most of the times almost everyone has full sysadmin access (unfortunately) which makes things complicated.
What you could do however is setup a DDL trigger and log any information you can for the next time it occurs.

Otherwise go as what Gail's suggest.
Post #1470752
« Prev Topic | Next Topic »

Add to briefcase

Permissions Expand / Collapse