[Ubuntu] Disable the DEP-11/AppStream apt index target - #14719
v-dunjadenic wants to merge 1 commit into
Conversation
- Skip DEP-11 metadata, which CI never uses, removing 15 of ~51 index items and 7.6 MB from every apt-get update. - Assert the effective value in Apt.Tests.ps1 and ubuntu-slim/test.sh.
There was a problem hiding this comment.
🟢 Approval recommended
The reviewed changes include validation checks and no unresolved blocking issues were identified.
Pull request overview
This pull request disables unnecessary DEP-11/AppStream APT metadata downloads for Ubuntu and Ubuntu Slim images and adds validation checks.
Changes:
- Adds APT index-target overrides for both image variants.
- Verifies the effective APT configuration.
File summaries
| File | Description |
|---|---|
images/ubuntu/scripts/tests/Apt.Tests.ps1 |
Verifies the effective APT setting. |
images/ubuntu/scripts/build/configure-apt.sh |
Disables DEP-11 metadata downloads. |
images/ubuntu-slim/test.sh |
Verifies the effective setting. |
images/ubuntu-slim/scripts/build/configure-apt.sh |
Disables DEP-11 metadata downloads for Slim. |
Review details
- Files reviewed: 4/4 changed files
- Comments generated: 0
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Worst case scenario calculationsDEP-11 changes only one variable, the number of index items apt fetches, from 51 to 36. Since time to failover is that count multiplied by the per item cost, the improvement is the same 1.4x whichever retry and timeout settings are in effect. Case 1: Mirror unavailable
On top of #14643, where the per item cost drops to 31s, the same reduction takes 26m down to 19m. Either way it is roughly 1.4x faster. Case 2: Mirror slow but still sending dataThis is the only change in the whole effort that helps here.
Roughly 1.2x faster. The 204 kB/s figure is the degraded metadata rate reported in #14594, against a median of about 6,900 kB/s. Unlike the retry and timeout bounds in #14643, this applies to every image including 22.04 and 24.04 arm64, since it reduces work regardless of whether a mirror list is in use. |
Description
ubuntuandubuntu-slim.Apt.Tests.ps1andubuntu-slim/test.sh.Split out of #14643 so it can be validated separately from the retry and timeout work.
Reasoning:
DEP-11 is metadata for graphical software centres. A CI runner never reads it, but we download it on every
apt-get update, where it is 15 of the roughly 51 index items and 7.6 MB. It is enabled only becauseappstreamregisters the target withoutDefaultEnabled, unlike its own icon targets.It also helps with the stalls in #14594. Time-to-failover scales with the number of index items, since the mirror method restarts from
priority:1for every one of them, so this takes the worst case from about 26 minutes to about 19 on top of #14643. It is also the only part of this work that helps when a mirror is slow rather than dead, since timeouts cannot bound that case and fetching less is the only lever left.The setting lives in
/etc/apt/apt.conf.d/90-index-targets, which sorts after50appstreamso it wins.Related issue:
#14594
Split from:
Check list