Incident Library
  • Root cause
  • Component
  • Symptom
  • Contributing factor
  • Case

Cases11 cases

6 to 10 of 11

  1. Symptoms

    On 2025-03-12 from 10:58 UTC, alerts for high backend response times came in, and the MediaWiki deployments mw-api-int, mw-parsoid and mw-jobrunner, which serve MediaWiki for non-user-facing purposes, showed high latency and database errors. The External Storage cluster, whose hosts store the compressed text of wiki page revisions, had a sharp rise in load and connections. The same happened again on 2025-03-13 from 11:15 UTC.

    Trigger

    At 10:44 UTC on 12 March a Scap deployment of the PHP 8.1 rollout for mw-api-int, mw-parsoid and mw-jobrunner was run with the flag -Dbuild_mw_container_image:False; the rollout was deployed with Scap again at 11:15 UTC on 13 March.

    Root cause
    Component
    Contributing factor
    Detection

    Alerts for high backend response times started at 10:58 UTC on 12 March, 14 minutes after the Scap deployment; 2 on-call engineers were paged. The MediaWikiMemcachedHighErrorRate alert that pointed at the cause fired only briefly because its log pipeline was overloaded.

    Remediation
    • Deployed a patch to cirrus-streaming-updater that reduced SUP parallelism
    • Reduced the concurrency of the categoryMembershipChange job in changeprop-jobqueue
    • On 12 March, reverted 1126607 and 1126650 and re-ran Scap
    • On 13 March, rolling-restarted changeprop-jobqueue
    • Rolling-restarted mw-api-int
    • Disabled the categorymembership job in changeprop-jobqueue
    • Reverted 1127476 and 1127478
    • Redeployed mw-api-int to pick up the revert
    • Increased the number of mw-api-int replicas
    • Redeployed mw-jobrunner to pick up the revert
    • Redeployed mw-parsoid to pick up the revert
    Action items
    • Reduce the number of messages sent through channel:Memcached during failures
    • Add helm rollback functionality to Scap
    • Decide whether Scap should update helmfile-defaults when -Dbuild_mw_container_image:False is set
    • Consider removing envvars.inc from MediaWiki images
    • Consider "Why" dashboards that give an overview of a group of related components together with relevant links to follow
    • Coordinate incident responders better
    • Be able to work with MediaWiki developers during incidents
    Lessons

    The write-up puts the weight not on the technical root cause but on why the team could not see, even after the 12 March incident, that three MediaWiki deployments were running without Memcached. Alert dashboards showed what was happening, such as many busy PHP workers, but not why; dashboards linking components that affect each other, such as SQLBlobStore keys and External Storage, would have helped. The alert that pointed in the right direction did not stay firing and would probably have been lost among 78 others. The incident coordinator could not tell who was working on what or who had joined or left, the channels were noisy, the external impact was judged more critical than it was, and trace.wikimedia.org was not used although it might have helped.

  2. Symptoms

    From 3:42 PM to 4:04 PM PT on 10 October 2024, the Sentry US site and event ingestion were unavailable, and the status page reported an issue with the Postgres database that made the site unavailable. The dashboard, the API and every US ingestion type, including errors, transactions, attachments, profiles, replays, spans, cron monitoring and custom metrics, were affected.

    Trigger

    A database migration ran certain database operations through the RunSQL command without lock and statement timeouts.

    Root cause
    Component
    Contributing factor
    Remediation
    • Issued a fix, after which the dashboard and ingestion recovered
    Action items
    • Replace RunSQL commands with more robust solutions in the migration framework
    • Update the database framework to the latest version, which handles some operations RunSQL was used for
    • Write runbooks for recovering from lock or timeout issues during migrations
    • Improve alerting and observability so the team reacts sooner
  3. Symptoms

    About 20 minutes into a batch that rewrote the preset smart-list data of STORES 予約 (STORES reservation), an alert fired for a sudden rise in 504 errors (Gateway Timeout). The work had started a little after 03:00 UTC, and the metrics watched during it, such as web server response latency and the load of the writer database, had shown no large change.

    Trigger

    The preset smart lists 初回予約の顧客 (first-reservation customers) and 要フォロー顧客 (customers needing follow-up), created more than a month earlier, were rewritten with new search parameters after the search specification changed, which switched them onto the new search query.

    Root cause
    Component
    Contributing factor
    Detection

    An alert on a sudden increase in 504 errors (Gateway Timeout), about 20 minutes after the preset rewrite batch started.

    Action items
    • Rework the database design so the inline-view search logic is no longer used
    • Add a test that checks this API's EXPLAIN output for scans larger than expected
    • Provide an environment where the timing of this logic can be measured easily
    Lessons

    Rushing to meet the schedule led to both a failure that affected users and a later release. In a multi-tenant database an EXPLAIN that shows index use can still hide large scans, tests need the case where one query is fast and the next is slow, the metrics to watch during a data change are those of the instance that serves the affected queries, and metrics sent at the end of a request are lost for requests that never finish.

  4. Symptoms

    After further bug-fix deployments and reconnecting users on the launch day of the package sales ranking feature, a database alarm fired and the CPU of the Cookie Run: OvenBreak AWS Aurora MySQL database was at 100%. Database connections then failed, and players could not log in to or play the game.

    Trigger

    The package sales ranking feature was deployed, and further bug-fix deployments followed that reconnected users; each server update left more servers with empty caches that ran the ranking query against the database.

    Root cause
    Component
    Contributing factor
    Detection

    A database alarm fired, and the CPU graph of the Aurora MySQL database showed 100%.

    Remediation
    • Put the game servers into maintenance
    • Added a switch for the package sales ranking feature and turned the feature off, which restored the service
    • Rewrote the ranking query to group products that share a sale start time and to drop the current-time condition
    • Moved the ranking query to a scheduler server that runs it periodically and stores one shared cached result
    • Turned the package sales ranking feature back on after both fixes
    Lessons

    A heavy query combined with per-server caches in a distributed server setup caused a problem nobody expected, so the points likely to cause trouble need to be found in advance. During an outage, restoring the service comes before finding the cause, and a switch that turns a feature off, built in ahead of time, is a safety device that helps run a stable service. The online ALTER itself went well with Percona Toolkit and was used again for later schema changes.

  5. Symptoms

    At 09:20 UTC on 4 April 2023, seven minutes after a deployment was triggered, Open Collective's service degraded: a migration in the deployment had locked the entire Transactions table in the production database.

    Trigger

    A deployment ran a migration that dropped indexes on the Transactions table and re-created them with CONCURRENTLY, excluding soft-deleted rows.

    Root cause
    Component
    Contributing factor
    Detection

    The degradation of service was noticed at 09:20 UTC, seven minutes after the deployment was triggered.

    Remediation
    • Killed the migration, though the table remained locked
    • Put the frontend into maintenance mode to limit queries
    • Closed the other connections to the database
    • Cancelled the new index creation and restored the old index
    • Restored the frontend and confirmed the issue was resolved
    Action items
    • Add a script that simulates production load locally, using a tool like vegeta
    • Run this kind of migration during specific maintenance windows
    • Create the new index first and drop the old one afterwards in future migrations
    • Insist on a review from another engineer before merging such a pull request
    Lessons

    Dropping the old index before creating the new one was too optimistic under constant production queries, even with CONCURRENTLY, and an unreviewed pull request let it through. Tests locally and on staging did not show the problem because there were no tools to run migrations in stressed environments. Putting the frontend in maintenance mode limited the impact while showing users a clear message.

Check your cluster for this

These 11 cases involve Database and Schema migration. 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

Faulty deployment11 cases

  1. IL-0510 MIT Learn's RDS PostgreSQL ran out of storage after a release and learn.mit.edu returned 503s and 504s for hours
  2. IL-0369 Railway's backend API went down when a column migration waited on locks and replicas could not get database connections
  3. IL-0547 Buildkite annotation queries timed out and drove database CPU up across shards after a migration removed an index
  4. IL-0315 Railway's backend API went down when an index build locked a billion-row Postgres table and used up every connection
  5. IL-0327 After a blue/green upgrade of CircleCI's workflows database every query hit disk, and workflow starts lagged or failed
  6. IL-0324 Three MediaWiki deployments lost Memcached after a PHP 8.1 rollout and overloaded the External Storage database cluster
  7. IL-0554 A database migration used up Sentry US's Postgres connections, and the site and event ingestion were down for 22 minutes
    Sentry2024
  8. IL-0571 STORES reservation returned bursts of 504 errors when a smart-list query held a database process for over 20 minutes
    STORES2024
  9. IL-0567 Aurora MySQL behind Cookie Run: OvenBreak hit 100% CPU after a sales-ranking feature launch, and players could not play
  10. IL-0524 An index migration locked Open Collective's whole Transactions table and degraded the service for nearly an hour
  11. IL-0566 Hot ranges after a Cookie Run: Kingdom guild update drove CockroachDB nodes to 100% CPU, forcing emergency maintenance