Skip to content

fix(ci): harden apt-get against mirror hangs in eBPF/vrf-module steps - #435

Closed
privateip wants to merge 1 commit into
mainfrom
fix/apt-get-mirror-hangs
Closed

fix(ci): harden apt-get against mirror hangs in eBPF/vrf-module steps#435
privateip wants to merge 1 commit into
mainfrom
fix/apt-get-mirror-hangs

Conversation

@privateip

Copy link
Copy Markdown
Contributor

Summary

Both #424 and #425 hit the same CI failure in the same run window, on two otherwise-unrelated branches: an apt-get update/apt-get install step hung until the job's timeout-minutes killed it, rather than failing fast or retrying.

Root cause: none of this repo's three apt-get call sites set any retry/timeout options, so a single unreachable/slow mirror blocks indefinitely instead of failing over quickly.

Fix

Add -o Acquire::Retries=3 -o Acquire::http::Timeout=10 -o Acquire::https::Timeout=10 to every CI apt-get update/apt-get install invocation:

  • .github/actions/install-ebpf-deps/action.yaml (clang/llvm/linux-libc-dev — used by every job)
  • .github/workflows/ci.yaml's test-unit-root job (vrf kernel module)
  • scripts/ci.sh's e2etest case (same vrf kernel module install, for local/CI parity)

This bounds each mirror attempt to ~10s and retries up to 3 times, so a bad mirror fails in well under a minute instead of consuming the entire job timeout.

Test plan

🤖 Generated with Claude Code

Bare "apt-get update"/"apt-get install" have no per-request timeout, so
a stalled connection to GitHub's default regional mirror
(azure.archive.ubuntu.com has been observed hanging outright) blocks
until the job's own timeout-minutes kills it, burning the whole
15-25 minute budget instead of failing fast or retrying. This hit both
#424 (install-ebpf-deps, inside the E2E Tests job) and #425 (the vrf
kernel module step, inside Unit Tests (root)) in the same CI run
window, on two otherwise-unrelated branches -- both jobs got cancelled
at their timeout with apt still stuck on the initial 'update'.

Add -o Acquire::Retries=3 -o Acquire::http::Timeout=10
-o Acquire::https::Timeout=10 to every apt-get invocation that
installs CI-only packages (install-ebpf-deps' clang/llvm/
linux-libc-dev, and the two copies -- ci.yaml and scripts/ci.sh -- of
the linux-modules-extra vrf-module install) so a bad mirror fails
each attempt in ~10s and retries up to 3 times instead of hanging for
the full job timeout.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@privateip
privateip requested a review from a team as a code owner August 19, 2026 21:17
@privateip
privateip requested a review from ecv August 19, 2026 21:17
@privateip
privateip enabled auto-merge August 20, 2026 14:13
@privateip

Copy link
Copy Markdown
Contributor Author

Closing as redundant — this exact commit (fix(ci): harden apt-get against mirror hangs in eBPF/vrf-module steps, same diff by patch-id) already landed in main via #425 (fix/usid-tenant-isolation, merged 2026-08-19), which carried it as a bundled ancestor commit. git rebase origin/main on this branch confirms it: skipped previously applied commit 1965ddc -- patch contents already upstream, collapsing this branch to exactly main with zero commits ahead.

@privateip privateip closed this Aug 20, 2026
auto-merge was automatically disabled August 20, 2026 14:16

Pull request was closed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant