r/SQL • u/MooseSea6 • Aug 22 '26
SQL Server Question for DBAs: How much do you actually use Extended Events (.xel) vs. standard DMVs for emergency troubleshooting?
Hey everyone, senior dev here working heavily with SQL Server performance tuning lately. Every time a server hits a massive wave of deadlocks or unexpected latency drops, the standard advice is 'spin up an Extended Event session and read the system health .xel file.'
Am I the only one who finds opening, filtering, and digging through those logs in SSMS incredibly clunky during a crisis? Do you guys actually sit there shredding the XML nodes manually, or do you rely on third-party tools/scripts to give you plain answers?
9
Upvotes
6
u/VladDBA SQL Server DBA Aug 22 '26 edited Aug 22 '26
If I want to get all the relevant data in one go with 0 setup I just use PSBlitz which gets me everything (instance health info, security issues, top x resource intensive queries from the plan cache and query store, information about active sessions, index information and diagnostics) in a nice HTML or Excel report complete with execution plan and deadlock graph files.
If it's an instance where people can create objects and I don't need the data in a nice portable format (e.g. instances I personally handle and not for some customer) then I just use Brent Ozar's FRK and Erik Darling's sp_QuickieStore. If you're working with extended events (I generally don't), you might want to check out sp_HumanEvents.
Also,
Do you mean blocking or are you just getting actual deadlocks in a sudden spike?
4
u/ihaxr Aug 22 '26
I wouldn't even attempt to setup an extended event for emergency troubleshooting...
If I absolutely needed to see a specific query or error I'd just setup a profiler trace and eat the performance overhead.
Otherwise the Brent Ozar stored procs and sp_whoisactive are usually enough for my needs.
1
u/warehouse_goes_vroom Aug 22 '26 edited Aug 22 '26
Both extended events and DMVs have their place. Note that xel is only one of many supported targets for extended events - for example, you can also send them to an ETW session if that's more in line with your needs: https://learn.microsoft.com/en-us/sql/relational-databases/extended-events/targets-for-extended-events-in-sql-server?view=sql-server-ver17#etw_classic_sync_target-target
Don't forget the query store or the error log, depending on the emergency in question.
I'm not a DBA though. I do, however, contribute to the SQL Server codebase (as part of working on Microsoft Fabric Warehouse).
Edit: also, why are you running into deadlocks super frequently? If you can, consider looking into enabling Optimized Locking and Lock After Qualification: https://learn.microsoft.com/en-us/sql/relational-databases/performance/optimized-locking?view=sql-server-ver17.