minikube/site/content/en/docs
Nir Soffer b66888d972
vfkit: Use EFI booloader (#20833)
* vfkit: Log serial console to file

To make debugging easier, add virtio-serial device logging serial
console to file:

    ~/.minikube/machines/NAME/serial.log

To enable logging, we need to enable the console in the kernel command
line, since we still use direct kernel boot.

Example log:

    % cat /Users/nir/.minikube/machines/vfkit/vfkig.log
    [    0.896094] cacheinfo: Unable to detect cache hierarchy for CPU 0
    [    0.897186] loop: module loaded
    [    0.897670] virtio_blk virtio2: [vda] 840488 512-byte logical blocks (430 MB/410 MiB)
    [    0.897733] vda: detected capacity change from 0 to 430329856
    [    0.898460] virtio_blk virtio3: [vdb] 40960000 512-byte logical blocks (21.0 GB/19.5 GiB)
    [    0.898533] vdb: detected capacity change from 0 to 20971520000
    ...
    [    1.794714] systemd[1]: Detected virtualization vm-other.
    [    1.794752] systemd[1]: Detected architecture arm64.

    Welcome to Buildroot 2025.02!

    [    1.794944] systemd[1]: Hostname set to <minikube>.
    [    1.795011] systemd[1]: Initializing machine ID from random generator.
    ...
    [  OK  ] Started Container Runtime Interface for OCI (CRI-O).
    [  OK  ] Reached target Multi-User System.

    Welcome to minikube
    vfkit login: [    6.681578] systemd-ssh-generator[630]: Binding SSH to AF_UNIX socket /run/ssh-unix-local/socket.

* vfkit: Use EFI bootloader

With the fixed iso, we can simplify the driver using the EFI bootloader
option[1] instead of the legacy and deprecated --kernel, --kernel-cmdline,
and --initrd options[2].

Example run:

    % minikube start -p vfkit --driver vfkit --container-runtime containerd --network vmnet-shared
    😄  [vfkit] minikube v1.36.0 on Darwin 15.5 (arm64)
      Using the vfkit driver based on user configuration
    👍  Starting "vfkit" primary control-plane node in "vfkit" cluster
    🔥  Creating vfkit 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 "vfkit" cluster and "default" namespace by default

Comparing direct kernel boot and --bootloader efi shows that it is little bit faster and boot time is more consistent.

    % hyperfine -r 10 -C "minikube delete" \
        "vfkit-efi/out/minikube start --driver vfkit --network vmnet-shared --container-runtime containerd --no-kubernetes" \
        "vfkit-direct/out/minikube start --driver vfkit --network vmnet-shared --container-runtime containerd --no-kubernetes"
    Benchmark 1: vfkit-efi/out/minikube start --driver vfkit --network vmnet-shared --container-runtime containerd --no-kubernetes
      Time (mean ± σ):     10.205 s ±  0.656 s    [User: 0.381 s, System: 0.266 s]
      Range (min … max):    9.106 s … 11.254 s    10 runs

    Benchmark 2: vfkit-direct/out/minikube start --driver vfkit --network vmnet-shared --container-runtime containerd --no-kubernetes
      Time (mean ± σ):     10.933 s ±  1.616 s    [User: 0.402 s, System: 0.406 s]
      Range (min … max):    9.155 s … 14.168 s    10 runs

    Summary
      vfkit-efi/out/minikube start --driver vfkit --network vmnet-shared --container-runtime containerd --no-kubernetes ran
        1.07 ± 0.17 times faster than vfkit-direct/out/minikube start --driver vfkit --network vmnet-shared --container-runtime containerd --no-kubernetes

[1] https://github.com/crc-org/vfkit/blob/main/doc/usage.md#efi-bootloader
[2] https://github.com/crc-org/vfkit/blob/main/doc/usage.md#deprecated-options

* docs: Update vfkit driver documentation

- Separate vfkit requirements and vmnet-shared requirements
- Update minimal macOS version required for --bootloader efi
- Simplify vfkit upgrade, it is available in brew now
2025-06-10 10:21:10 -07:00
..
benchmarks add time-to-k8s benchmark for v1.36.0 (#20825) 2025-05-23 10:19:44 -07:00
commands Update auto-generated docs and translations (#20897) 2025-06-06 16:08:09 -07:00
contrib Update yearly leaderboard (#20864) 2025-06-02 14:32:24 -07:00
drivers vfkit: Use EFI booloader (#20833) 2025-06-10 10:21:10 -07:00
faq site: improve none docs 2023-05-08 16:20:19 -07:00
handbook remove tiller addon (#19636) 2024-09-19 11:21:24 -07:00
presentations Added latest presentation info 2024-02-14 09:30:20 -05:00
runtimes Document container runtimes available 2022-01-17 20:13:20 +01:00
start improved invoke-webrequest command (#20574) 2025-05-20 15:26:34 -07:00
tutorials site: Add example to ingress tutorial (#20814) 2025-05-21 11:34:12 -07:00
_index.md Update releases.json & releases-v2.json to include v1.36.0 (#20824) 2025-05-22 11:54:08 -07:00