0% found this document useful (0 votes)
3 views2 pages

DB Contention Case Study & Troubleshooting

Uploaded by

demy2014
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views2 pages

DB Contention Case Study & Troubleshooting

Uploaded by

demy2014
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd

1

Real-World Incident Case Study – Peak  Coordinated with dev team →


Traffic DB Contention optimized SQL queries & transaction
Situation: handling.
During a peak traffic period, Grafana Result:
triggered high latency alerts. PagerDuty  Latency normalized in minutes,
escalated to the on-call engineer. downtime avoided.
Task:  Added deadlock-specific alerts in
Identify and fix the root cause without monitoring stack.
downtime or affecting customer  Enhanced pre-deployment load
experience. testing to catch similar issues earlier.
Action:
 Checked Azure Monitor → One-Page DB & Distributed App
CPU/memory were stable. Troubleshooting SOP
 Investigated Azure SQL metrics →
query execution times spiked. 1️⃣ Monitoring — Proactive Detection
 Used Splunk → found repeated Tools: Grafana, Prometheus, Azure
deadlock errors in logs. Monitor, SSMS, SolarWinds
 Applied OpenTelemetry distributed Why: Early detection of anomalies before
tracing → found a specific impact.
microservice creating contention. Actions:
 Rolled back latest microservice  Track CPU, memory, query execution

deployment via Helm → contention times, deadlocks, blocking sessions


dropped immediately.  Set baseline performance metrics
 Configure alerts via PagerDuty /
Opsgenie

1
2

Azure SQL:
2️⃣ Alert Response — Initial Triage  Query Performance Insight → Top
Tools: Azure Service Map, Grafana queries
Dashboards, SSMS Activity Monitor  Intelligent Insights & auto-tuning
Why: Narrow down affected services & recommendations
scope.  DMVs for waits, blocking
Actions:
 Verify service health in Azure Monitor 4️⃣ Remediation — Apply Fix
 Compare current metrics vs baseline Distributed Apps: Rollback via Helm,
 Identify if issue is DB, app, or infra- scale services, disable features via feature
related flags
On-Prem SQL: Kill blocking sessions, add
3️⃣ Diagnosis — Root Cause Analysis indexes, optimize queries, tune TempDB
Distributed Apps: Azure SQL: Apply safe index
 Logs → Splunk / ELK Stack recommendations, temporarily scale
 Tracing → OpenTelemetry, Jaeger compute, optimize slow queries
 Identify slow endpoints or high error
rates 5️⃣ Postmortem — Prevention
On-Prem SQL:  Document RCA in Confluence / Jira
 SSMS Activity Monitor &  Add targeted alerts (e.g., deadlocks >
sp_whoisactive for X)
blocking/deadlocks  Improve pre-deployment load testing
 Execution plans for query tuning (JMeter, k6)
 DMVs (sys.dm_exec_requests) for  Add chaos testing to simulate failures
active query inspection

You might also like