pushleft
Deploy your first app
Manual contents
Handbook
HandbookPushleftArchitecture
Operate
Install the control planeYour own serversFleetOperations and alertsAuthenticationAccess gateDomains and DNSUsage and budgetsScheduled jobsAbuse controlsAI provider proxyCustomer mailErrors and performanceLogs and metricsRetentionObject storageContainer registryGit server
Develop
The .pl.yaml manifestOnboard with an AI agentThe pl up demoBuild executorSource ingestionAgent gatewayManaged databasesSecurity findingsTunnels and shellsDev workspacesPrivate hostnamesMesh coordinatorsDesign baseline
Runbooks
Control-plane host failoverControl-plane PostgreSQL failoverControl-plane PostgreSQL restoreCustom domains and certificatesGateway key compromiseIngress host failureNode busyNode disk fullNode drain and replacementNode lostRegistry outageHetzner Robot hostsSecret rotationSecurity incidentStaging fleet on ProxmoxStaging build cacheStuck deploymentVault/OpenBao backup and recovery
More
CI pipelines
Manual · docs/runbooks/node-lost.md

Node lost

Use this when node_heartbeat_stale fires and pushleft-controller fleet list then shows a node as lost.

The scheduler marks a node lost when it has not leased or heartbeated for PUSHLEFT_NODE_LOST_AFTER_SECONDS (default 300, minimum 30). It then reclaims the node’s work (lost nodes). This page says what is automatic, what is not, and what to check.

Symptoms

  • node_heartbeat_stale, then fleet list shows a line such as lost app-3 since …: fenced 4 job(s), 3 instance(s) lost, replacements 2 ready / 1 queued, 0 database instance(s) stranded (data not moved).
  • Deployment events node_lost, then application_ready for the replacement instances, ingress_relocating and ingress_route_relocated. Or deployment_degraded.
  • pushleft-controller fleet events shows node_lost, and database_instance_stranded for a database node.
  • The Fleet app’s Overview counts both as open events while the node is lost.

Automatic steps

  1. The node is lost and unschedulable. Every queued or leased job targeted at it is failed with last_error='target node lost; lease fenced'. A late heartbeat or completion from it gets 409.
  2. Its application instances are lost (rows kept). Each instance of an active deployment has a replacement row (replaces_instance_id, generation + 1) with a normal ensure_application job.
  3. Its application and environment-gateway capacity is released. Subnet slots are not reused.
  4. A live deployment stays live on its old route. When the replacement web instances are ready on a healthy node, a relocation route is published there. The old route drains only after the new one is active.
  5. Database instances on the node are error and keep their allocation. Nothing is moved.

Before you start

  • Get an operator host with pushleft-controller, and access to the Cloudflare zone for <base>.
  • Set DATABASE_URL to the pushleft_controller role.

Diagnosis

  1. Read the reclamation record. The line has the fenced jobs, the lost instances and the stranded databases:

    pushleft-controller fleet events --limit 100 | grep node_lost
  2. Read the replacement count on the lost line of pushleft-controller fleet list.

  3. List the deployments that had instances on the node. The lost instances are included:

    pushleft-controller fleet deployments-on <node>
  4. Open Deployments in the Fleet app. Filter Status to Degraded, then open each deployment, and any deployment the tenant names:

    • Services lists each role’s instances, with their node, generation and status.
    • What happened has node_lost, waiting_for_capacity and application_placement_rejected. These tell you why a replacement is not placed.
    • Routes lists the hostnames still on the lost node.
  5. Open Pipeline. Waiting for capacity lists deployments that have no room.

A replacement stays queued, retried every 15 s, until a node qualifies. The node must be a fresh, schedulable application node in the deployment’s regions. It needs capacity and fresh network admission evidence for the environment. In an environment with a sealed topology, a node that is not yet a member joins through a topology revision. The mesh worker adds it and rolls every live member to the next generation. The replacement starts after that. The lost node stays a member and does not block the revision. A role bound to a volume or a box-bound address is not moved: the placement is rejected (application_placement_rejected) and the deployment is degraded.

Actions

  1. Ingress DNS. If the lost node was the ingress host, find the node that now carries the relocation route. Routes on the deployment’s page names it. The node’s page shows its public address.

    With platform DNS configured (PUSHLEFT_PLATFORM_DNS_ZONE_ID, more than one application node), the controller already points each hostname’s record there; check with dig +short <hostname>. Otherwise point the wildcard *.<base> record at that address. The operator manages that record.

  2. Capacity. If replacements are queued and the deployment is degraded, add capacity with fleet provision --pool application … (a Robot host: enroll it) and fleet admit. Placement continues by itself. The deployment returns to live when its long-lived roles are ready.

  3. Degraded with a failed relocation. If automatic relocation stopped, ask the user to run pl up again. This publishes a fresh generation (ingress host failure).

    A failed relocation shows deployment_degraded with reason ingress relocation off a lost node failed. Pushleft retries it per hostname after five minutes, up to three failures. Each hostname drains its lost route only when its own replacement is active. After the third failure, automatic relocation stops.

  4. Database node. The data is on the lost host’s volume. Pushleft does not relocate database data. Do one of these:

    • Recover the host and its volume, then decommission and replace it (node drain).
    • Restore from the tenant’s own backups.
  5. The host comes back. Its lease requests get 403 node_lost and a cleanup list. Its agent removes the containers of each fenced instance. The agent journal shows node was marked lost; removed fenced instance …. Then the node returns to service (return of a lost node):

    1. After 300 s of polls without a gap (PUSHLEFT_NODE_RETURN_AFTER_SECONDS), the node is active and not schedulable. fleet events shows node_returned.
    2. Each fenced instance gets one more teardown on the node. Each stranded database gets a health check, and the result sets it ready or degraded.
    3. When the teardowns and the checks are complete, the node gets back its status from before the loss. Replacements bound to its volume go back to it.

    If a teardown fails, the node stays unschedulable. Check the containers on the host, then decommission the node or contact Pushleft support:

    docker ps --filter label=com.pushleft.managed=true
  6. Keep a host out. Block a host that you do not trust before it comes back, for example a host with bad hardware. The host then stays lost, however steadily it polls:

    pushleft-controller fleet block <node>
    pushleft-controller fleet unblock <node>   # lets it return

    To retire the host for good, decommission it. fleet decommission revokes the certificate and accepts a lost node. The command fails while the node holds a stranded database allocation. To use the host again, enroll it as a new node (bringing a lost host back).

    pushleft-controller fleet decommission <node>

Check it worked

  • fleet list shows replacements N ready / 0 queued, and the deployment is live.
  • Routes on the deployment’s page shows Active for the relocation route and Draining for the lost node’s route.
  • curl -sI https://<app>.<base> answers from the new node.

Do not

  • Do not set a lost node back to active by hand or edit a lost instance. Pushleft takes the node back itself once it has cleaned up; a lost instance stays lost (a trigger refuses a change), and its replacement owns the role slot.
  • Do not retarget the fenced jobs or reuse their lease tokens.
  • Do not release a stranded database allocation by hand. The data is still on that disk.
  • Do not run fleet ca rotate --complete while a lost node that may come back still runs containers. Completion revokes its certificate, and it then cannot receive its cleanup list.
Rendered from the repository at build time. Edit docs/runbooks/node-lost.md to change it.