Determine when SQL Principal and Mirror Flipped

We are using mirroring between two SQL 2005 Standard edition installations. ServerA is the host of the principal database. ServerB is the host of the mirrored version.

Is there a way to determine the history of flips? Meaning how do we determine when the databases have flipped. We don't see a specific eventid and even so it would be nice to see this in a report or a SQL query. The reason it flipped would be even better!

Thanks :)
GCIT_ManagerAsked:
Who is Participating?
 
Eugene ZConnect With a Mentor Commented:
check table  msdb.dbm_monitor_data  
but use : the stor proc:
sp_dbmmonitorresults
http://msdn.microsoft.com/en-us/library/ms366320(SQL.90).aspx
 --
more
Monitoring Mirroring Status
http://msdn.microsoft.com/en-us/library/ms365781(SQL.90).aspx
 
--
more:

sys.dm_db_mirroring_connections  
 http://sqlblogcasts.com/blogs/simons/archive/2005/11/15/Database-mirror-state-information.aspx
----
0
 
Eugene ZCommented:
did you check GUI and sql server error log/
Database Mirroring History
http://msdn.microsoft.com/en-us/library/ms365382(SQL.90).aspx 
0
 
GCIT_ManagerAuthor Commented:
Technically this works. Except this makes you scroll through thousands of entries since it creates one every minute. There's got to be a way to run a SQL query to find this information out.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.