Graph
Cases4 cases
1 to 4 of 4
IL-0302Peak load on GitHub's mysql1 MySQL cluster maxed out its database proxy's connections and stopped writes in March 2022GitHub2022- Symptoms
On March 16, 2022 at 14:09 UTC, write operations across GitHub stopped working, including git operations, webhooks, pull requests, API requests, issues, GitHub Packages, GitHub Codespaces, GitHub Actions and GitHub Pages. Under peak-hour load, the database proxy in front of the shared mysql1 MySQL database had reached its maximum number of connections.
- Trigger
Increased load on mysql1 during peak hours, combined with poor query performance in specific circumstances, pushed the database proxy to its maximum number of connections.
- Root cause
- Component
- Contributing factor
- Remediation
- Failed over mysql1 to a healthy replica on March 16
- Reset the application connections to the new primary on March 17
- Added an index that fixed the main query performance problem
- Performed a primary failover on March 22
- Performed a primary failover on March 23
- Throttled webhook traffic to reduce load
- Action items
- Keep throttling webhook traffic at peak load times
- Audit the load patterns of mysql1 during peak hours and make performance fixes based on the audits
- Move traffic to other databases to reduce load and speed up failover
- Review change management, particularly monitoring and changes during high load in production
- Shard the databases and scale up hardware
IL-0456Inflearn went down six times during a January 2022 free-course event as slow queries piled up on Aurora PostgreSQLInflab2022- Symptoms
During a 100% discount event that made 125 courses free, Inflearn received 5 to 20 times its normal traffic, and on four days, 3, 4, 7 and 17 January 2022, the service became unusable around 9 a.m. and 10 p.m. There were six outages in all.
- Trigger
A 100% discount event on 125 courses, from 3 to 17 January and 18 to 24 January 2022, went viral and brought 5 to 20 times the usual traffic.
- Root cause
- Component
- Contributing factor
- Detection
The team followed the outages through hourly transaction counts, RDS metrics, monitoring and slow query alerts.
- Remediation
- Added an index to the interested-companies query on the course page
- Changed how often the cache data stored in the database was reset and regenerated
- Moved the read queries that loaded the writer DB to the reader DBs
- Scaled the database to 8 r5.8xlarge instances, which bought only a few tens of minutes
- Rewrote slow course queries or added indexes so they use indexes, and switched off features whose queries could not be fixed
- Removed the large course description column from the select * course queries
- Split the IDs of the IN clause into batches of 20 run with Promise.all
- Upgraded PostgreSQL from 10.16 to 11.13
- Set a 5-second query timeout
- Raised max connections
- Ran VACUUM by hand on the course table
- Moved the large course description column into a separate table
- Action items
- Change the structure in which one table's failure spreads to the whole service
- Improve the table and cache structures that are hard to tune
- Make the SQL code easier to follow
- Improve code that gives no confidence to change, such as code without types or test code
- Build a stable batch environment
- Keep a monolith of reasonable size and separate the domains through which failures spread most
- Lessons
Because every database bottleneck appeared as slow queries on the reader DBs, watching only the readers hid the root cause on the writer. In PostgreSQL, frequent updates to a table with large columns produce large dead tuples in bulk and slow every query on that table. Before the second event the team could not run a meaningful performance test because the first week showed that almost any page could fail under load. The event exposed high sensitivity to failure in every area, one table's failure spreading to the whole service, hard-to-tune table and cache structures, unintuitive SQL code, code without types or tests, no stable batch environment, and many hidden failure points not yet found.
- Symptoms
Early on Sunday 20 September 2015, the error rate of customer requests to Amazon DynamoDB in the US-East Region rose far beyond any level of the previous 3 years by 2:37am PDT and settled at about 55%. Some other AWS services in the region that depend on DynamoDB were affected as well.
- Trigger
At 2:19am PDT a brief network disruption affected a portion of DynamoDB's storage servers, and they all requested their membership data from the metadata service at the same time.
- Root cause
- Component
- Contributing factor
- Detection
For the errors that remained after the main recovery, a growing number of customer support cases on Monday about tables stuck in the updating or deleting stage and higher than normal error rates showed that the low overall error rate was hitting some customers hard.
- Remediation
- Paused requests to the metadata service, which cut the retries and relieved its load
- Added significant capacity to the metadata service once it could answer administrative requests
- Turned requests to the metadata service back on and returned storage servers to the customer request path
- Restored a metadata partition that was still not taking its full traffic, ending the remaining errors on Monday
- Action items
- Significantly increased the capacity of the metadata service, which AWS had already done by the time of the summary
- Add stricter monitoring on performance dimensions such as membership size, to plan capacity ahead
- Reduce the rate at which storage nodes request membership data
- Lengthen the time allowed to process membership queries
- Segment DynamoDB into many metadata service instances, each serving only part of the storage server fleet
- Change SQS metadata caching so send and receive keep working without long access to the metadata table
- Partition work across the Auto Scaling servers to process a backlog of scaling jobs in parallel
- Prune older scaling activities that have been superseded
- Increase the capacity available to process scaling activities
- Change CloudWatch caching of DynamoDB group membership data to refresh only the smallest set of metrics
- Deliver CloudWatch metrics faster through write-through caching
- Roll out the shorter timeout on the DynamoDB-dependent API call in Console login
- Lessons
A low overall error rate can hide disproportionately high error rates for a few customers, and AWS should have posted to the dashboard sooner. A call that does not need to succeed, like the DynamoDB-dependent API call in Console login, should fail quickly instead of blocking on a very long timeout. Splitting the metadata service into many instances, each serving part of the fleet, is meant to contain the impact of software, capacity or infrastructure failures.
- Symptoms
On 3 June 2014, PagerDuty's notification pipeline performed poorly and some notifications were delayed after the Cassandra cluster behind it became heavily degraded. About 3% of events sent to the integration API could not be received.
- Trigger
On 3 June 2014 the Cassandra background repair process started its normal run on one node of the cluster while other high load was on the cluster; on 4 June the team restarted the postponed repair by hand.
- Root cause
- Component
- Contributing factor
- Remediation
- Reduced the load on the Cassandra cluster
- Stopped the Cassandra repair process
- Cut communication between some Cassandra nodes to stabilise the cluster
- On 4 June, deleted all in-flight data in the notification pipeline in a "factory reset"
- Brought downstream systems back into a consistent state with the emptied pipeline by hand
- Action items
- Scale the existing Cassandra nodes vertically to bigger, faster servers
- Set up multiple Cassandra clusters and spread the workloads across them
- Set system load thresholds at which the Cassandra clusters are scaled out horizontally ahead of need
- Upgrade the current and new clusters to a more recent Cassandra version
- Add more load shedding techniques to control Cassandra under high load
- Bring more Cassandra expertise in-house
- Lessons
PagerDuty concluded that its Cassandra cluster was underscaled and shared by too many services with different load and usage patterns, and that the scaling work should have come before the planned Cassandra version upgrade.
These 4 cases involve Database and PostgreSQL vacuum. kubegap audits a Kubernetes cluster for gaps like these, read-only, from Claude Code or Codex; its checks cite public reports like the ones in this library.
By root cause1
Capacity exhaustion4 cases
- Contributing factor
- Organisation
IL-0302Peak load on GitHub's mysql1 MySQL cluster maxed out its database proxy's connections and stopped writes in March 2022GitHub2022IL-0456Inflearn went down six times during a January 2022 free-course event as slow queries piled up on Aurora PostgreSQLInflab2022IL-0282DynamoDB in US-East reached about 55% request errors as storage servers overloaded its metadata serviceIL-0383PagerDuty's shared Cassandra cluster degraded during a repair, delaying notifications and losing incoming eventsPagerDuty2014