You have a database named database1.
Database developers report that there are many deadlocks.
You need to implement a solution to monitor the deadlocks. The solution must meet the
following requirements:
Support real-time monitoring.
Be enabled and disabled easily.
Support querying of the monitored data.
What should you implement?
More than one answer choice may achieve the goal. Select the BEST answer.
A.
Log errors by using trace flag 1222
B.
Log errors by using trace flag 1204
C.
A SQL Server Profiler template
D.
An Extended Events session
Explanation:
http://www.sqlservercentral.com/blogs/james-sql-footprint/2012/08/12/monitor-deadlock-insql-2012/
http://blogs.technet.com/b/mspfe/archive/2012/06/28/how_2d00_to_2d00_monitor_2d00_de
adlocks_2d00_in_2d00_sql_2d00_server.aspx
It could be A and B http://www.mytechmantra.com/LearnSQLServer/Identify-Deadlocks-in-SQL-Server-Using-Trace-Flag-1222-and-1204/ not D… Am I missing something?
Using trace flags, all monitored data writes to log , so it is not easy to query:
– “Support querying of the monitored data”
D – Extended Events
Do you still use trace flag 1204 and 1222 to monitor Deadlock? or using profile to capture deadlock? Now we are in SQL Server 2012! One of the biggest improvement of SQL 2012 is Extended Events.
Extended Events can replace SQL Profiler, and it is more powerful with less performance impact than SQL Profiler. Extended Events has been introduced in SQL Server world from SQL2008, and in SQL2012, it has been integrated into SQL Server Management Studio(SSMS)
D