From da0839e79d4d1767f70b4fe9b8fd5141de99001b Mon Sep 17 00:00:00 2001 From: Nir Soffer Date: Thu, 5 Jun 2025 20:54:58 +0300 Subject: [PATCH] iso: Fix console for vfkit/krunkit (#20832) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * iso: Fix console for vfkit/krunkit The serial console name depends on the driver. We had setting for qemu that does not work for vfkit and krunkit, breaking boot from minikube iso. Fixed by using 2 console= options, one is known to work for qemu, and one for vfkit and krunkit. With this we can use the same iso image with qemu, vfkit, and krunkit. This will allow simplifying vfkit driver. Previously we had to extract the kernel and initrd and start it using the legacy --kernel, --kernel-cmdline and --initrd options. I tested this by building the iso with this fix and running with --iso-url. Example run with qemu: % minikube start -p qemu --driver qemu --container-runtime containerd \ --iso-url file://$PWD/minikube-arm64.iso 😄 [qemu] minikube v1.36.0 on Darwin 15.5 (arm64) ✨ Using the qemu2 driver based on user configuration 🌐 Automatically selected the socket_vmnet network 👍 Starting "qemu" primary control-plane node in "qemu" cluster 🔥 Creating qemu2 VM (CPUs=2, Memory=6000MB, Disk=20000MB) ... 📦 Preparing Kubernetes v1.33.1 on containerd 1.7.23 ... ▪ Generating certificates and keys ... ▪ Booting up control plane ... ▪ Configuring RBAC rules ... 🔗 Configuring bridge CNI (Container Networking Interface) ... 🔎 Verifying Kubernetes components... ▪ Using image gcr.io/k8s-minikube/storage-provisioner:v5 🌟 Enabled addons: default-storageclass, storage-provisioner 🏄 Done! kubectl is now configured to use "qemu" cluster and "default" namespace by default Example run with krunkit: % minikube start -p krunkit --driver krunkit --container-runtime containerd \ --iso-url file://$PWD/minikube-arm64.iso 😄 [krunkit] minikube v1.36.0 on Darwin 15.5 (arm64) ✨ Using the krunkit (experimental) driver based on user configuration 👍 Starting "krunkit" primary control-plane node in "krunkit" cluster 🔥 Creating krunkit VM (CPUs=2, Memory=6000MB, Disk=20000MB) ... 📦 Preparing Kubernetes v1.33.1 on containerd 1.7.23 ... ▪ Generating certificates and keys ... ▪ Booting up control plane ... ▪ Configuring RBAC rules ... 🔗 Configuring bridge CNI (Container Networking Interface) ... 🔎 Verifying Kubernetes components... ▪ Using image gcr.io/k8s-minikube/storage-provisioner:v5 🌟 Enabled addons: default-storageclass, storage-provisioner 🏄 Done! kubectl is now configured to use "krunkit" cluster and "default" namespace by default * Updating ISO to v1.36.0-1749066232-20832 --------- Co-authored-by: minikube-bot --- Makefile | 2 +- deploy/iso/minikube-iso/board/minikube/aarch64/grub.cfg | 5 ++++- pkg/minikube/download/iso.go | 2 +- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 02a3d1b6f4..770cc6c9d0 100644 --- a/Makefile +++ b/Makefile @@ -24,7 +24,7 @@ KIC_VERSION ?= $(shell grep -E "Version =" pkg/drivers/kic/types.go | cut -d \" HUGO_VERSION ?= $(shell grep -E "HUGO_VERSION = \"" netlify.toml | cut -d \" -f2) # Default to .0 for higher cache hit rates, as build increments typically don't require new ISO versions -ISO_VERSION ?= v1.36.0-1748823857-20852 +ISO_VERSION ?= v1.36.0-1749066232-20832 # Dashes are valid in semver, but not Linux packaging. Use ~ to delimit alpha/beta DEB_VERSION ?= $(subst -,~,$(RAW_VERSION)) diff --git a/deploy/iso/minikube-iso/board/minikube/aarch64/grub.cfg b/deploy/iso/minikube-iso/board/minikube/aarch64/grub.cfg index e06366b9ab..0e78c7d16a 100644 --- a/deploy/iso/minikube-iso/board/minikube/aarch64/grub.cfg +++ b/deploy/iso/minikube-iso/board/minikube/aarch64/grub.cfg @@ -2,6 +2,9 @@ set default="0" set timeout="5" menuentry "Buildroot" { - linux /boot/bzimage console=ttyAMA0 # kernel + # The console depends on the driver: + # qemu: console=ttyAMA0 + # vfkit,krunkit: console=hvc0 + linux /boot/bzimage console=ttyAMA0 console=hvc0 initrd /boot/initrd # rootfs } diff --git a/pkg/minikube/download/iso.go b/pkg/minikube/download/iso.go index 5cef53355c..9e7f38940a 100644 --- a/pkg/minikube/download/iso.go +++ b/pkg/minikube/download/iso.go @@ -41,7 +41,7 @@ const fileScheme = "file" // DefaultISOURLs returns a list of ISO URL's to consult by default, in priority order func DefaultISOURLs() []string { v := version.GetISOVersion() - isoBucket := "minikube-builds/iso/20852" + isoBucket := "minikube-builds/iso/20832" return []string{ fmt.Sprintf("https://storage.googleapis.com/%s/minikube-%s-%s.iso", isoBucket, v, runtime.GOARCH),