Skip to content

[Backport release-1.5] fix(velero): add startupProbe so slow startup does not crashloop the install gate - #3533

Merged
myasnikovdaniil merged 1 commit into
release-1.5from
backport-3138-to-release-1.5
Aug 4, 2026
Merged

[Backport release-1.5] fix(velero): add startupProbe so slow startup does not crashloop the install gate#3533
myasnikovdaniil merged 1 commit into
release-1.5from
backport-3138-to-release-1.5

Conversation

@myasnikovdaniil

Copy link
Copy Markdown
Contributor

What this PR does

Hand-backport of #3138 to release-1.5. The backport label was applied at merge time but no backport PR was ever opened, so the change never reached this branch — found by auditing the branch with cmd/backport-audit, which reported it as MISSING. Like the other items in that set, it merged before #3155 fixed the bot's conflict_resolution input, so the conflicting cherry-pick was dropped with no draft and no failing check.

Velero binds its metrics/health endpoint (:8085) only after loading plugins and connecting to the API server. Under a heavy parallel platform install the upstream liveness probe starts checking at initialDelaySeconds=10 and kills the container after failureThreshold=5, so velero BackOff-restarts and never escapes the loop inside the install-gate window. Because backupstrategy-controller hard-depends on velero, this blocks the gate. The fix adds a startupProbe, which holds liveness and readiness off entirely while it is failing, granting 30 * 10s = 300s of startup grace and then handing over to the unchanged upstream liveness for steady-state crash detection.

Backport adaptations

This branch vendors velero chart 11.0.0 (appVersion 1.17.0) rather than main's 12.0.3 (1.18.1), so three things differ from the original. All are recorded in the commit message as well.

  • The chart version is not bumped. Only the patch re-application is added to update. The helm pull here was previously unpinned, which would have let update float to a chart the patch does not apply to, so it is pinned to 11.0.0 — the version already vendored. That makes the new patch step deterministic and leaves the vendored tree byte-identical.
  • The test: target is added. It exists on main but not here, so without it the shipped regression guard would never run.
  • The image assertions pin this branch's own versions (velero v1.17.0, plugin-for-aws v1.12.1, kubevirt plugin v0.8.0), and the upgrade-crds rationale is restated for chart 11.0.0, where that Job still runs a kubectl image — main's comment about the Job running the velero image natively is true for 12.x only.

The startupProbe hunk itself applies to chart 11.0.0's deployment template unchanged, in the same position inside the metrics.enabled gate.

Verification

helm unittest . passes 5/5 in packages/system/velero. The assertions are mutually corroborating rather than vacuous: the equal assertions prove the startupProbe path actually renders, and the same paths are asserted absent under velero.metrics.enabled: false, proving it follows the same gate as liveness and readiness so disabling metrics can never leave a startupProbe pointed at an unbound port.

Screenshots

Not applicable — no UI change.

Release note

fix(velero): add a startupProbe so a slow velero server start under heavy parallel install no longer crashloops the container and blocks the install gate

…install gate

Velero binds its metrics/health endpoint (:8085, http-monitoring) only
after the server loads its plugins and connects to the API server. Under
a heavy parallel platform install that can take minutes, but the upstream
liveness probe begins checking /metrics at initialDelaySeconds=10 and
kills the container after failureThreshold=5 (~130s total) before :8085
is bound. The kubelet SIGTERMs velero (exitCode 0/Completed), it
BackOff-restarts, and never escapes the loop inside the install-gate
window. Because backupstrategy-controller hard-depends on velero, this
blocks the gate.

Add a startupProbe to the velero server container. While it is failing
the kubelet holds off liveness and readiness entirely, granting
failureThreshold * periodSeconds = 30 * 10s = 300s of startup grace, then
hands over to the unchanged, tight upstream liveness (10s / 30s / 5) for
steady-state crash detection. This is strictly better than loosening
liveness, which would also blunt steady-state detection.

The upstream velero chart (12.0.3) does not render a startupProbe, so the
package patches the deployment template via patches/add-startup-probe.patch
(re-applied after re-vendor by the Makefile update target, matching the
seaweedfs/ingress-nginx convention) and supplies the startupProbe through
the package values override. Pin the startupProbe budget and the unchanged
liveness with a helm-unittest regression guard.

Backport adaptations for release-1.5, which vendors velero chart 11.0.0
(appVersion 1.17.0) rather than main's 12.0.3 (1.18.1):

- The chart version pin stays at the version this branch already
  vendors; only the patch re-application is added to `update`. The
  `helm pull` was previously unpinned, which would have let `update`
  float to a chart the patch does not apply to, so it is pinned to
  11.0.0 to keep the new patch step deterministic.
- Added the `test:` target, which exists on main but not here, so the
  shipped regression guard actually runs.
- The image assertions pin this branch's own vendored versions
  (velero v1.17.0, plugin-for-aws v1.12.1, kubevirt plugin v0.8.0),
  and the upgrade-crds rationale is restated for chart 11.0.0, where
  that Job still runs a kubectl image.

The startupProbe hunk applies to chart 11.0.0's deployment template
unchanged, in the same position inside the metrics.enabled gate.

Assisted-By: Claude <noreply@anthropic.com>
Signed-off-by: Aleksei Sviridkin <f@lex.la>
(cherry picked from commit f7271b8)
Signed-off-by: Myasnikov Daniil <myasnikovdaniil2001@gmail.com>
@gemini-code-assist

Copy link
Copy Markdown
Contributor

Caution

The consumer version of Gemini Code Assist on GitHub has been sunset. All code review activity has officially ceased.

@coderabbitai

coderabbitai Bot commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: 7b5557a3-9329-47fa-93c6-89ee0f2c822d

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@dosubot dosubot Bot added area/platform Issues or PRs related to platform infrastructure (bundle, flux, talos, installer) backport Should change be backported on previous release kind/bug Categorizes issue or PR as related to a bug labels Aug 4, 2026
@github-actions github-actions Bot added area/release Issues or PRs related to release tooling (changelog, backport, release pipeline) area/storage Issues or PRs related to storage (linstor, seaweedfs, bucket, velero, harbor) size/L This PR changes 100-499 lines, ignoring generated files labels Aug 4, 2026
@myasnikovdaniil
myasnikovdaniil merged commit 00ab459 into release-1.5 Aug 4, 2026
14 of 15 checks passed
@myasnikovdaniil
myasnikovdaniil deleted the backport-3138-to-release-1.5 branch August 4, 2026 09:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/platform Issues or PRs related to platform infrastructure (bundle, flux, talos, installer) area/release Issues or PRs related to release tooling (changelog, backport, release pipeline) area/storage Issues or PRs related to storage (linstor, seaweedfs, bucket, velero, harbor) backport Should change be backported on previous release kind/bug Categorizes issue or PR as related to a bug size/L This PR changes 100-499 lines, ignoring generated files

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants