Skip to content

doctor: install the cocoonstack fork builds of cloud-hypervisor and the firmware - #215

Merged
CMGS merged 1 commit into
masterfrom
doctor/fork-dev-pins
Sep 5, 2026
Merged

doctor: install the cocoonstack fork builds of cloud-hypervisor and the firmware#215
CMGS merged 1 commit into
masterfrom
doctor/fork-dev-pins

Conversation

@CMGS

@CMGS CMGS commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Why

cocoon-check --upgrade installed upstream Cloud Hypervisor v53.0, which has no CopyOnWrite memory restore. cocoon's default clone/restore mode is mmap, which maps to exactly that mode, so a doctor-provisioned host rejects every default clone with a 400 from vm.restore. The cocoonstack fork dev release build (upstream main plus diff snapshots and the QCOW cluster-leak fix, cloud-hypervisor v54.0.0) has it. The firmware fork carries the EFI ResetSystem and IA32_FEATURE_CONTROL/VMXON-lock fixes that Windows guests need, and the docs already told people to use both forks by hand.

What

  • doctor/check.sh --upgrade installs cloud-hypervisor-<arch> from the cocoonstack/cloud-hypervisor release tag CH_REF (default dev) and, on x86_64, hypervisor-fw from the cocoonstack/rust-hypervisor-firmware tag FW_REF (default dev). Both downloads are verified against the published SHA256SUMS / .sha256 before install, and the FIXED line records the build commit from the release's build-info.json.
  • ch-remote (CH_REMOTE_VERSION, v53.0 — the fork release ships no ch-remote asset), Firecracker (FC_VERSION, v1.16.1), the aarch64 firmware (FW_VERSION, 0.5.0 — the fork publishes x86_64 only) and the CNI plugins stay on upstream releases.
  • The check pass fails a cloud-hypervisor older than v54 with the reason (no CopyOnWrite restore, default mode rejected) instead of passing a host that cannot clone.
  • docs/install.md and docs/windows.md state what the forks actually carry today. The DISCARD and virtio-net ctrl_queue fixes the Windows page attributed to the fork are upstream (v51.0 / v52.0); the fork's own delta is diff snapshots and the QCOW fix.

No cocoon code change: a CH that rejects CopyOnWrite already fails loud (PUT vm.restore → 400: <CH body> through utils.DoAPI), and a silent fallback to copy would be the ~6x restore-latency regression the restore code refuses by design.

Evidence

  • bash -n doctor/check.sh clean; shellcheck -S warning reports only the pre-existing SC2034 (prefix_len, untouched).
  • --upgrade run in debian:bookworm-slim containers on both architectures (COCOON_*_DIR under /tmp, curl + libcap2-bin only):
# linux/arm64 (native)
==> Install cloud-hypervisor (cocoonstack fork dev)
  [FIXED] cloud-hypervisor dev (commit 815f40b5) -> /usr/local/bin/cloud-hypervisor
==> Install ch-remote v53.0 … [FIXED]
==> Install firecracker v1.16.1 … [FIXED]
==> Install hypervisor-fw 0.5.0
  [FIXED] hypervisor-fw 0.5.0 -> /tmp/cocoon/firmware/CLOUDHV.fd
==> Install CNI plugins v1.9.1 … [FIXED]
20fa683ac2626b97efabdbaae300b5119699aaf9f558c81108c8bce7bbda5e2c  /usr/local/bin/cloud-hypervisor   (= SHA256SUMS cloud-hypervisor-aarch64)

# linux/amd64 (emulated)
==> Install cloud-hypervisor (cocoonstack fork dev)
  [FIXED] cloud-hypervisor dev (commit 815f40b5) -> /usr/local/bin/cloud-hypervisor
==> Install hypervisor-fw (cocoonstack fork dev)
  [FIXED] hypervisor-fw dev (commit 4161be33) -> /tmp/cocoon/firmware/CLOUDHV.fd
0bd06a827ee943185c11142f04406380d8240f6ae3668e49aa4089cca9055064  /usr/local/bin/cloud-hypervisor   (= SHA256SUMS cloud-hypervisor-x86_64)
b53d0a7492ac4cdbac1c5d6a05acd53e8d96e71b955720a20171b026383fce9c  /tmp/cocoon/firmware/CLOUDHV.fd   (= hypervisor-fw.sha256)
  • The same fork builds (cloud-hypervisor v54.0.0 815f40b) drove cocoon master on the bare-metal testbed today: vm run, vm net --nics 2, vm disk attach/detach, stop and rm all clean (cocoon-specs tests/2026-09-05-fc-hotplug-mtu-parity.md).

…he firmware

The default clone/restore mode (mmap) needs CopyOnWrite memory restore,
which upstream v53.0 rejects; the fork dev release (upstream main plus
diff snapshots and the QCOW cluster-leak fix) has it, and the firmware
fork carries the EFI ResetSystem and VMXON-lock fixes Windows guests
need. --upgrade now downloads both from the cocoonstack release tags,
verifies them against the published checksums, and records the build
commit; ch-remote, Firecracker, the aarch64 firmware and the CNI plugins
stay on upstream releases. The check pass fails a cloud-hypervisor older
than v54. install.md and windows.md describe what the forks actually
carry: the DISCARD and ctrl_queue fixes are upstream since v51/v52.
@CMGS
CMGS merged commit 4112a30 into master Sep 5, 2026
4 checks passed
@CMGS
CMGS deleted the doctor/fork-dev-pins branch September 5, 2026 14:53
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