ansible: growing a volume does not grow its filesystem (add resizefs: true) #298

Stängd
öppnade 2026-08-01 09:01:54 +00:00 av supernaut · 0 kommentarer
Ägare

Growing a Cinder volume does not grow its filesystem, and nothing in the playbook closes the gap.

community.general.filesystem in the forgejo and podman roles creates a filesystem but never
resizes one, and no task runs resize2fs. So bumping lfs_volume_size / data_volume_size and
applying leaves the block device larger and the filesystem exactly as it was. On 2026-08-01 that meant
lsblk reporting 60G while df still showed 20G with 4.1G free, until resize2fs was run by hand.

The runbook documents the manual step, but it is easy to apply the volume change and believe the job
is done — the plan says ~ size, the apply succeeds, and monitoring still shows a nearly full disk
with no obvious link between the two.

What to do

Add resizefs: true to the community.general.filesystem tasks for the data and LFS volumes. It is
idempotent and a no-op when the filesystem already fills the device, so it costs nothing on a normal
converge and removes a footgun that only ever appears during a capacity emergency.

Check whether the root volume needs the growpart step handled too, since that one is partitioned and
resize2fs alone is not enough there.

Growing a Cinder volume does not grow its filesystem, and nothing in the playbook closes the gap. `community.general.filesystem` in the `forgejo` and `podman` roles creates a filesystem but never resizes one, and no task runs `resize2fs`. So bumping `lfs_volume_size` / `data_volume_size` and applying leaves the block device larger and the filesystem exactly as it was. On 2026-08-01 that meant `lsblk` reporting 60G while `df` still showed 20G with 4.1G free, until `resize2fs` was run by hand. The runbook documents the manual step, but it is easy to apply the volume change and believe the job is done — the plan says `~ size`, the apply succeeds, and monitoring still shows a nearly full disk with no obvious link between the two. ## What to do Add `resizefs: true` to the `community.general.filesystem` tasks for the data and LFS volumes. It is idempotent and a no-op when the filesystem already fills the device, so it costs nothing on a normal converge and removes a footgun that only ever appears during a capacity emergency. Check whether the root volume needs the `growpart` step handled too, since that one is partitioned and `resize2fs` alone is not enough there.
Logga in för att delta i denna konversation.
Ingen milstolpe
Inga tilldelade
1 deltagare
Notiser
Förfallodatum
Förfallodatumet är ogiltigt eller utanför gränserna. Använd formatet "åååå-mm-dd".

Inget förfallodatum satt.

Beroenden

Inga beroenden satta

Referens
bitborg/bitborg-infra#298
Ingen beskrivning angiven.