Repository navigation
Description
Update 2026-11-26 (infra move): the cluster files that this postmortem cites are in dan-petty/homelab.
- Read
k8s/llm/gateway/config.yaml,k8s/logging/loki-values.yaml,k8s/monitoring/dashboards/llm-stack.jsonandk8s/monitoring/prometheus-values.yamlthere. docs/SRE.mddoes not exist; usedocs/guidelines/sre.md.- The postmortem stays here. Put no host name or address in it.
Problem or Motivation
SLO 3 of the LLM gateway (99.5 % of the requests with no failure, set by the owner on 2026-11-11 in #4709) used 124 % of its 30-day error budget. The SRE service spec (docs/guidelines/sre.md, #5445) asks for a postmortem of each incident that used more than 20 % of the 28-day budget of an SLO. No incident record and no postmortem exist.
Measured on 2026-11-13 at 16:20 UTC:
1 - sum(increase(litellm_proxy_failed_requests_metric_total[30d])) / sum(increase(litellm_proxy_total_requests_metric_total[30d]))is 99.38 %, with n = 129,417 requests.sum(increase(litellm_proxy_failed_requests_metric_total[1d]))as a range query with a step of 86,400 s: most failures are from 2026-10-24 to 2026-11-05. The highest day had 346 failed requests. Since 2026-11-07, each day has 8 failed requests or fewer.
Proposed Solution
- Split the failed requests of each day by model group and by error class, from the gateway metrics and the gateway logs in Loki.
- Write the postmortem as a comment on this issue, in the outline of the SRE book: the summary, the impact with the SLI and the budget used, the UTC timeline, the root cause, the trigger, the detection, the resolution and the action items.
- Name the system conditions, not the persons or the agents.
- File each action item with
uv run devops roadmap intake, or comment on its open issue.
Acceptance Criteria
- The postmortem comment has each section of the outline, and each number names its query.
- The failures of each day are split by model group and by error class, with n.
- Each action item links an issue.
Existing Tool Considered
Prometheus, Loki and the postmortem outline of the SRE book ("Postmortem Culture"). No new tool. Cost: about 0.2 M tokens and 1 hour.
Related
#4709, #4714 (the postmortem section of the project review).
Source: #5445
Alternatives check of 2026-11-26: not-applicable.
Class: docs, no model call.
Tool: none found.
Proposed design
Problem statement
SLO 3 of the LLM gateway (99.5 % of requests with no failure over 28 days) used 124 % of its 30-day error budget as measured on 2026-11-13 at 16:20 UTC, and the failures cluster from 2026-10-24 to 2026-11-05. The SRE guideline asks for a postmortem when an incident uses more than 20 % of the 28-day budget, and no incident record or postmortem exists. This item writes the postmortem with the SRE outline and T10 tables, pins each figure to its query, store and measurement time, splits the daily failures by model group and error class, files and links the action items, and keeps the document in this repository with no host name or address.
Acceptance criteria
Requirement: Postmortem document
The pull request SHALL add the gateway postmortem at docs/postmortems/2026-11-05-litellm-gateway-failures.md with the eight sections of the SRE outline.
Scenario: The eight sections are present
- WHEN A test reads the postmortem document
- THEN The test finds the headings Summary, Impact, Timeline, Root Cause, Trigger, Detection, Resolution and Action Items, in that order
Requirement: Postmortem in the docs site
The pull request SHALL list docs/postmortems/*.md in a tab of .nav.yml, so that the strict docs site build includes the postmortem.
Scenario: The docs site build finds the postmortem in no tab
- WHEN The change runs
uv run devops docs site build --strict - THEN The command exits 0 and its page count includes the postmortem page
Requirement: Each figure names its query
Each number in the postmortem MUST name the query that produced it, with the store, the pinned start and end, and the measurement time.
Scenario: A figure has no query
- WHEN A test reads the figures table of the postmortem
- THEN The test finds a query with
start=,end=, a measurement time and a store of Prometheus or Loki on each row
Requirement: Daily split by model group and error class
The postmortem SHALL split the failed requests of each day from 2026-10-24 to 2026-11-05 by model group and by error class, and SHALL give n and the store for each row.
Scenario: Each day of the range has its split
- WHEN A test reads the split table
- THEN The test finds at least one row for each date from 2026-10-24 to 2026-11-05, and each row gives a model group, an error class, n and a store, or marks the date as not retained with the store's retention and the measurement time
Requirement: Impact figures
The Impact section SHALL state the SLI, the budget used, the request count, the highest day and the quiet period, and SHALL name the 28-day SLO window and the 30-day dashboard window of #4709.
Scenario: A figure is missing
- WHEN A test reads the Impact section
- THEN The test finds 99.38 %, n = 129,417, a highest day of 346, at most 8 failures per day since 2026-11-07, the 28-day SLO window with a budget query pinned by start and end, and the 30-day dashboard window of feat(monitoring): define the Service SLOs in a Sloth spec #4709 with 124 %
Requirement: Postmortem tables follow T10
The Action Items and Timeline tables MUST use the columns of rule T10.
Scenario: A table uses other columns
- WHEN A test reads the Action Items and Timeline tables
- THEN The test finds exactly the columns Item, Type, Owner role, Issue and State in the Action Items table and exactly Time (UTC) and Event in the Timeline table
Requirement: Action items have a priority and an issue
The Action Items section SHALL list each action item with a priority of P0, P1, P2 or P3 and with the issue that files it.
Scenario: An action item has no priority or no issue
- WHEN A test reads the Action Items table
- THEN The test finds at least one row, each row holds one of P0, P1, P2 or P3 in its Item cell, and each Issue cell holds a
#<number>link
Requirement: System conditions and no private data
The postmortem MUST name system conditions and MUST NOT name a person, an agent with an @ handle, a host name or a private address.
Scenario: A handle or a host name appears
- WHEN A test searches the postmortem for an
@handle, a private IPv4 address and a.localor.internalhost name - THEN The test finds no
@handle, no private IPv4 address and no.localor.internalhost name
Existing Tool Considered
The alternatives check of 2026-11-26 records not-applicable for class docs, with tool none found; it makes no search for this class. Prometheus and Loki are the open, maintained stores that give the figures, and the SRE book gives the outline; no open tool writes a postmortem, and the change builds no code. Cost: about 0.2 M tokens and 1 hour, as the issue records.
Key questions
- Where does the postmortem live, and how does one pull request deliver it?: The pull request adds
docs/postmortems/2026-11-05-litellm-gateway-failures.mdin this repository and adds a comment on docs(monitoring): write the postmortem of the gateway failures to Nov 5 #5473 that links it. The SRE guideline names the incident issue or the postmortem section of the project review. No incident issue exists, and the project review section is a separate item (feat(roadmap): report SLOs and incidents in the project review #4714), so a versioned document is the record that one pull request can deliver. The postmortem follows the guideline's outline and T10 tables. (best practice) [sources: docs/guidelines/sre.md:175, docs/guidelines/sre.md:176, docs/guidelines/sre.md:177, CONTEXT.md:12, docs/DESIGN.md:261]- Chosen: Document in the repository, with a link comment. One pull request delivers a versioned record, and the comment links it from the issue.
- Rejected: Comment on the issue only. No pull request delivers it, so the item cannot reach Planned.
- Rejected: Document and comment as two copies. Two copies drift; the comment only links the document.
- Which store gives the split of the failed requests by model group and by error class?: Prometheus gives the daily count and the model group: SLO 3 reads
litellm_proxy_failed_requests_metric_totalover the total counter, and the gateway series carryrequested_model, the client-facing model group before routing. Loki gives the error class:query_loki_metricsruns LogQL metric queries over the gateway pod logs, and the failed counter carries no error-class label in the repository's fixtures. (best practice) [sources: k8s/devops/monitoring/slos/llm-gateway-requests.yaml:16, k8s/devops/monitoring/prometheus-rules-values.yaml:647, tests/fixtures/dashboard_queries/ai-spend.yaml:19, tests/fixtures/prometheus_rules/slo_llm_gateway_requests_tests.yaml:28, src/devops_cli/k8s/logql.py:391]- Chosen: Prometheus for the model group and Loki for the error class. The metric carries the requested model and the count; the logs carry the exception that the metric does not label.
- Rejected: Prometheus only. The repository shows no error-class label on the failed counter.
- Rejected: Loki only. The SLO count is the Prometheus counter, and Loki holds no budget arithmetic.
- Rejected: Add labels to the gateway metrics. It changes the gateway and is out of the scope of this item.
- How does each figure stay reproducible after the 30-day window moves?: Each query pins
startandendand gives the measurement time and the store.PrometheusClient.query_rangesendsstart,endandstep, and the SRE design records each number with its query and its date. A[30d]range moves with the day, so the same query gives a different number. (best practice) [sources: src/devops_cli/prometheus/client.py:120, openspec/changes/archive/2026-11-13-5445-add-the-sre-service-spec/design.md:6, docs/guidelines/kubernetes.md:51]- Chosen: Pin the start and the end time. The query gives the same number while the store holds the range.
- Rejected: Keep the
[30d]range. The window moves with the day, so the number changes.
- Which budget window does the postmortem use: the 28 days of the SRE spec or the 30 days of SLO 3?: The postmortem uses the 28-day SLO window for the budget and labels the issue's 30-day figure of 124 % as the dashboard window of feat(monitoring): define the Service SLOs in a Sloth spec #4709. The SRE guideline sets 28 days for each SLO, and the SLO 3 spec states the 28-day window. The SRE design records the 30-day dashboard window as a gap of feat(monitoring): define the Service SLOs in a Sloth spec #4709. (best practice) [sources: docs/guidelines/sre.md:53, docs/guidelines/sre.md:96, k8s/devops/monitoring/slos/llm-gateway-requests.yaml:12, openspec/changes/archive/2026-11-13-5445-add-the-sre-service-spec/design.md:5]
- Chosen: The 28-day SLO window, with the 30-day figure labeled as the dashboard gap of feat(monitoring): define the Service SLOs in a Sloth spec #4709. The SRE guideline and the SLO 3 spec set 28 days; the 30-day window is a recorded gap of feat(monitoring): define the Service SLOs in a Sloth spec #4709.
- Rejected: The 30-day window of the dashboard. It is not the SLO window; the SRE design records it as a gap of feat(monitoring): define the Service SLOs in a Sloth spec #4709.
- Rejected: Both windows as equal budgets. Two budgets confuse the impact; the 30-day figure is labeled, not used as the SLO budget.
- Does the pull request file the action items as issues?: The item files each action item with
uv run devops roadmap intakebefore the pull request and links each issue from the postmortem. The pull request creates no issue. The SRE guideline requires each action item to be an issue and to be linked from the postmortem, so a follow-up after the merge would leave the postmortem without the links that the rule requires. Each action item also gets a priority from the roadmap's P0 to P3 scale. (best practice) [sources: docs/guidelines/sre.md:178, docs/guidelines/sre.md:246, docs/DESIGN.md:246, CONTEXT.md:28]- Chosen: File them before the pull request and link each from the postmortem. The item can run
uv run devops roadmap intake, and the postmortem then meets SRE7 at the merge. - Rejected: File the action items in the pull request. An issue is a tracker record; the pull request changes only the repository.
- Rejected: File them in a follow-up. The postmortem would merge without the issue links that SRE7 requires.
- Rejected: File no action item. The postmortem then changes nothing and breaks SRE7.
- Chosen: File them before the pull request and link each from the postmortem. The item can run
- What does the postmortem do when a store no longer holds the range?: The postmortem records the measured figure, its query and its measurement time, and marks a day or a query as not retained once the range has left the store's retention. Prometheus keeps 30 days and Loki keeps 720 h, and a query reads at most the retention of its store. On 2026-11-26 the 30-day retention no longer holds 2026-10-24 to 2026-10-26, so the split table marks those days not retained with the measurement of 2026-11-13 and gives the split for the days that the stores still hold. (best practice) [sources: docs/guidelines/kubernetes.md:51, docs/guidelines/sre.md:53, CHANGELOG.md:6789, CHANGELOG.md:7012, openspec/changes/archive/2026-11-13-5445-add-the-sre-service-spec/design.md:5]
- Chosen: Record the measurement and mark a query that cannot rerun. The reader knows the source and the date of each figure, and no figure is invented.
- Rejected: Rerun each query only. The stores no longer hold 2026-10-24 to 2026-10-26, and the rest of the range leaves retention as time passes.
- Rejected: Omit a figure that cannot rerun. The Impact section would lose the SLI or the budget used.
- Does this item wait on docs(sre): add the SRE service spec #5445 for the postmortem outline?: No. docs(sre): add the SRE service spec #5445 is archived, and docs(monitoring): split the SRE spec into a guideline and decisions #5538 moved its spec to
docs/guidelines/sre.mdandk8s/README.md. The outline is in the guideline, so the work can start now. [sources: openspec/changes/archive/2026-11-13-5445-add-the-sre-service-spec/proposal.md:34, openspec/changes/archive/2026-11-13-5538-split-the-sre-spec/proposal.md:9, docs/guidelines/sre.md:175] - Which columns do the timeline and the action items use?: The T10 columns: the action items have Item, Type, Owner role, Issue and State, and the timeline has Time (UTC) and Event. The SRE guideline requires those tables. (best practice) [sources: docs/DESIGN.md:246, docs/guidelines/sre.md:177]
- Chosen: The T10 tables. T10 gives the columns that a reader and a test can check.
- Rejected: Free-form lists. The guideline requires the T10 tables.
- Which files does the postmortem read for the gateway metrics and logs?: The postmortem reads
k8s/llm/gateway/config.yaml,k8s/logging/loki-values.yaml,k8s/monitoring/dashboards/llm-stack.jsonandk8s/monitoring/prometheus-values.yamlin dan-petty/homelab, as the 2026-11-26 infra-move update names. The environment files outsidek8s/devopsare in that repository now, and the postmortem stays in devops-cli. It puts no host name or address in the text. [sources: docs/HOMELAB_REPO_SWITCH.md:5, k8s/README.md:395, docs/roadmap/stage.md:96, CHANGELOG.md:6649, CHANGELOG.md:5726] - How does the postmortem page reach the docs site?: The pull request adds the glob
docs/postmortems/*.mdto the Guides tab of.nav.yml. The strict docs site build fails for a built page that no nav tab lists, and the Docs Site Build workflow runsuv run devops docs site build --stricton each pull request that changes a site source. (best practice) [sources: .nav.yml:3, docs/SDLC.md:248, .github/workflows/docs-site.yml:71]- Chosen: Add
docs/postmortems/*.mdto the Guides tab. The SRE guideline and the cluster documents are in that tab, and the glob adds each later postmortem with no edit. - Rejected: Add a new Postmortems tab. One page does not need a new tab; the glob adds later postmortems to the same tab.
- Rejected: Leave the page out of the nav.
uv run devops docs site build --strictfails for a built page in no tab.
- Chosen: Add
Fit
Fits in one pull request.
Suspected block
None.
Dependencies
None.
Activity
dan-petty commentedon Nov 13, 2026
Both address SLO incident reporting; #4714 builds the review report mechanism, the candidate writes the postmortem for the Nov 5 gateway failures.devops-cli-service commentedon Nov 17, 2026
Alternatives check: not-applicable
Class: docs. The check makes no search and no model call for an item of this class.
Tool: none found
Checked on 2026-11-17. A person decides what this means for the item. The check changes no label and closes no issue.
devops-cli-service commentedon Nov 18, 2026
Status set to Ready at 955013e (see proposed design in issue body).
devops-cli-service commentedon Nov 27, 2026
Next step: the stage job writes the plan of the item. See the section Proposed design of the body.