Skip to content

Commit ad35afa

Browse files
committed
fix(e2e): disable guest fsync on ephemeral CI VM disks
The e2e QEMU guests boot with three raw virtio -drive lines that carry no cache= option, so QEMU defaults to cache=writeback and honors every guest fsync. The management-cluster Talos etcd fsyncs on each Raft commit, while containerd unpacks dozens of images and CDI imports multi-GB VM disks onto the same host-backed raw files during the VM-heavy suites. The fsync storm serializes etcd's writes into multi-second stalls, the mgmt apiserver times out lease PUTs, and many operators (capk, etcd-operator, fdb-operator, cilium-operator, kamaji) lose leadership at once — failing whichever chainsaw suite is mid-flight, a different one each run. Add cache=unsafe to each guest drive so guest flushes become no-ops against the host page cache, removing the fsync-gated etcd stalls. This is safe only because these CI VMs are ephemeral and destroyed every run; never use it for real data. Assisted-By: Claude <[email protected]> Signed-off-by: Andrei Kvapil <[email protected]>
1 parent d598e67 commit ad35afa

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

‎hack/e2e-prepare-cluster.bats‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -100,9 +100,9 @@ EOF
100100
qemu-system-x86_64 -machine type=pc,accel=kvm -cpu host -smp 8 -m 24576 \
101101
-device virtio-net,netdev=net0,mac=52:54:00:12:34:5${i} \
102102
-netdev tap,id=net0,ifname=cozy-srv${i},script=no,downscript=no \
103-
-drive file=srv${i}/system.img,if=virtio,format=raw \
104-
-drive file=srv${i}/seed.img,if=virtio,format=raw \
105-
-drive file=srv${i}/data.img,if=virtio,format=raw \
103+
-drive file=srv${i}/system.img,if=virtio,format=raw,cache=unsafe \
104+
-drive file=srv${i}/seed.img,if=virtio,format=raw,cache=unsafe \
105+
-drive file=srv${i}/data.img,if=virtio,format=raw,cache=unsafe \
106106
-display none -daemonize -pidfile srv${i}/qemu.pid
107107
done
108108

0 commit comments

Comments
 (0)