Skip to content

Coroot database replica cannot recover its PostgreSQL checkpoint #4662

Closed

Description

@devantler

🤖 Generated by the Agentic Engineer

Description

A Coroot metadata database replica repeatedly restarts during PostgreSQL recovery because it cannot locate a valid checkpoint. Database readiness is incomplete. The primary and a healthy replica remain ready in the bounded readback; application availability and data integrity have not been established by those readiness checks.

This is a distinct symptom from the connection-budget problem tracked in #4652. Its initiating cause and relationship to preceding recovery activity remain unproven.

Steps to observe

  1. Read the existing Coroot database readiness and instance restart state without changing production.
  2. Examine a finite tail from the failed replica's previous PostgreSQL startup.
  3. Join the recovery failure with the operator's current primary, target primary and readiness conditions.

Expected behavior

Every declared database replica completes recovery, remains ready, and serves the intended replication role.

Actual behavior

Bounded observations on 2026-10-08 show repeated startup failures containing the checkpoint error and an operator readiness condition that remains false. WAL archiving and the last-backup conditions report success, but those conditions alone do not prove a backup restore or complete data integrity.

An independent recovery then completed a replacement bootstrap. Subsequent readback still shows incomplete replica readiness and repeated adoption of the completed bootstrap job. A storage-management handoff remains incomplete; this is a candidate immediate recovery blocker, not proof of the initiating checkpoint failure's cause.

Environment

Production Coroot metadata database managed by CloudNativePG 1.30.1. Raw logs, storage identifiers, checkpoint positions and recovery commands remain private.

Recovery and acceptance

  • Preserve the healthy database members and retain diagnostic evidence from the failed replica.
  • Establish the initiating failure using checkpoint/WAL and storage evidence; do not infer it from restart timing alone.
  • Prepare and validate a supported, targeted replica recovery that retains the failed data for diagnosis and does not reset the primary's WAL or broaden a deploy exception.
  • Read back complete database readiness and a useful Coroot application response after recovery. Recheck health after the next protected deployment.
  • If a source or configuration defect is established, deliver its regression test and durable repair through the normal reviewed pipeline. Immediate recovery alone does not close this issue.

Recovery readback, 2026-10-08: A later bounded production read found every declared metadata database instance Ready and every declared Coroot server replica Ready. The readiness recovery happened independently; this run made no production changes. The earlier guarded storage handoff is stale and must not be applied. The initiating checkpoint failure cause remains unproven. The public application route returns its sign-in redirect, which does not prove a useful authenticated application response.

Remaining acceptance: establish the initiating checkpoint failure using retained checkpoint/WAL and storage evidence, and demonstrate supported durable prevention. The authenticated functional-response gap is cleared by the verification below; recovery readiness alone does not close this issue.

Part of #2043.

Verification checkpoint, 2026-10-11 00:36 UTC: The successful protected deployment was read from GitHub, and a fresh scoped cluster read confirmed readiness after it. Readiness does not demonstrate a useful authenticated application response, explain the original checkpoint failure, or prove prevention. No recovery or cluster mutation was performed; acceptance criteria and historical evidence are preserved.

Verification checkpoint, 2026-10-11 08:30 UTC: The existing browser session returned a populated Coroot application inventory and current alert data through the protected application route. A separate request without session credentials returned a sign-in redirect. Fresh scoped readback confirmed every declared metadata database member and every running workload in the observability namespace Ready. Native protected merge-group run 38085553374 was independently rechecked as successful. This establishes a useful application response after protected deployment. It does not establish the initiating checkpoint failure cause, durable prevention, data integrity or alert clearance. No recovery, credential, access-policy or production change was made; the historical recovery patch remains stale. The issue stays open for its remaining acceptance criteria.

Forensic checkpoint, 2026-10-12 21:20 UTC: Fresh scoped readback found all three declared database instances Ready, with zero restarts in their current Pod lifetimes. Those Pods were created after the 8 October incident. The affected persistent claim has the same identity as the retained incident receipt; that receipt records a successful replacement base backup before readiness recovered. The completed recovery job is no longer present, and the current event query contains no incident record. These facts do not prove that the original failed data or its causal storage evidence survived recovery.

Next investigation: use incident-time retained database and storage diagnostics, or an independently preserved snapshot, to correlate the invalid checkpoint with its WAL and storage state. The retained startup observation establishes the checkpoint symptom only. Current readiness, current Pod logs, successful archiving and a successful replacement bootstrap cannot establish the initiating cause. If historical evidence cannot discriminate a cause, record that limit before proposing a repair; do not infer corruption, select a WAL reset or repeat recovery from timing alone. The original cause and durable-prevention criteria remain open. No production or credential change was performed. Raw diagnostic details remain in the private operator store.

Activity

  1. added theissue type on Oct 8, 2026
  2. added 2 commits that reference this issue on Oct 11, 2026
  3. devantler commented on Oct 12, 2026

    @devantler
    ContributorAuthor

    🤖 Generated by the Agentic Engineer

    Removed the blocked label: nothing outside the engineer's reach is holding this issue.

    • The label dates from the operator request of 8 October. The database recovered without it; a read today (17:40 UTC) shows coroot-db at 3 of 3 ready and the cluster healthy.
    • The issue body carries no blocker record, so the label was hiding the issue from selection with no condition that could ever clear it.
    • What remains is engineering work: establish why the replica could not recover its checkpoint, from the retained evidence, and show durable prevention. The card stays in Verifying as started work; if that investigation turns out to depend on something only the maintainer or an upstream project can provide, it gets a blocker record that says so.
  4. added a commit that references this issue on Oct 12, 2026
  5. devantler commented on Oct 15, 2026

    @devantler
    ContributorAuthor

    🤖 Generated by the Agentic Engineer

    Read-only forensic checkpoint, 15 October: all declared Coroot database members are Ready. The native storage snapshot metadata associated with the current and historical claims is newer than the 8 October incident; one ready snapshot was created today. Its existence does not establish that the failed checkpoint or its WAL survived the replacement base backup. The complete typed Longhorn Backup resource list is empty, which is not proof that no driver-side or external backup exists.

    No snapshot was mounted, no backup was restored and no production object was changed. The next useful evidence is an incident receipt joined to an independently preserved, pre-replacement storage copy. Until that identity and content are established, current readiness and newer snapshots cannot establish the initiating cause or durable prevention. Those acceptance criteria remain open; this is not a new recovery authorization.

  6. added a commit that references this issue on Oct 16, 2026
  7. devantler commented on Oct 16, 2026

    @devantler
    ContributorAuthor

    🤖 Generated by the Agentic Engineer

    Evidence limit recorded: this incident's own evidence cannot establish why the checkpoint was rejected. The cause and prevention work continues in #4955; closing this issue.

    What a read-only check on 16 October established:

    • The failed data is gone. The recovery on 8 October wrote a fresh base backup into the affected storage, every volume snapshot that exists was taken after the incident, and no retained (released) volume exists for this database. So there is no pre-replacement copy left to read, and current readiness, logs and archiving status cannot discriminate a cause.
    • The recovery itself is verified. All database members are ready, and a useful authenticated Coroot response after a protected deployment was recorded on 11 October.
    • The same failure happened to the wedding database the same day (Wedding database replica fails PostgreSQL checkpoint recovery #4673): same operator version, same rejected-checkpoint symptom. Its original volume was retained, so it is the only surviving copy of this failure class.

    So the remaining acceptance criteria here (find the initiating cause, then prove durable prevention) move to #4955, which covers both incidents, starts from the retained wedding volume, and requires that a recurrence keeps its failed storage instead of having it overwritten as happened here. Nothing is dropped: if #4955 finds a cause, its repair ships there.

    No production object, credential or recovery was changed by this check.

  8. moved this from 📊 Verifying to ✅ Done in 🌊 Project Boardon Oct 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Fields

    Priority

    None yet

    Effort

    None yet

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions