"Failed to start virtualbox VM"

As far as I can tell, I’m supposed to do the following:

  1. Install VirtualBox (done)
  2. Install Minikube (done)
  3. cp -R ./saved_model_half_plus_two_cpu /var/tmp
  4. minikube start --mount=True --mount-string="/var/tmp:/var/tmp" --vm-driver=virtualbox
    etc…

But I can’t get past step 4.
my setup:
macOS Big Sur Version 11.6,
VirtualBox, Version 6.1.28 r147628 (Qt5.6.3)
minikube, stable 1.23.2, via Homebrew

I gave access via System Preferences | Security & Privacy but I don’t seem to see any mention of VirtualBox there now.??.. so I’m not entirely sure if VirtualBox is or isn’t “blocked by my system”. The minikube error message (below) doesn’t help me at all:

$ minikube start --mount=True --mount-string="/var/tmp:/var/tmp" --vm-driver=virtualbox

:grinning_face_with_smiling_eyes: minikube v1.23.2 on Darwin 11.6
:sparkles: Using the virtualbox driver based on user configuration
:+1: Starting control plane node minikube in cluster minikube
:fire: Creating virtualbox VM (CPUs=2, Memory=4000MB, Disk=20000MB) …
:fire: Deleting “minikube” in virtualbox …
🤦 StartHost failed, but will try again: creating host: create: creating: Error setting up host only network on machine start: /usr/local/bin/VBoxManage hostonlyif ipconfig vboxnet10 --ip 192.168.99.1 --netmask 255.255.255.0 failed:

VBoxManage: error: Code E_ACCESSDENIED (0x80070005) - Access denied (extended info not available)
VBoxManage: error: Context: “EnableStaticIPConfig(Bstr(pszIp).raw(), Bstr(pszNetmask).raw())” at line 242 of file VBoxManageHostonly.cpp
:fire: Creating virtualbox VM (CPUs=2, Memory=4000MB, Disk=20000MB) …
:crying_cat_face: Failed to start virtualbox VM. Running “minikube delete” may fix it: creating host: create: creating: Error setting up host only network on machine start: /usr/local/bin/VBoxManage hostonlyif ipconfig vboxnet11 --ip 192.168.99.1 --netmask 255.255.255.0 failed:
VBoxManage: error: Code E_ACCESSDENIED (0x80070005) - Access denied (extended info not available)
VBoxManage: error: Context: “EnableStaticIPConfig(Bstr(pszIp).raw(), Bstr(pszNetmask).raw())” at line 242 of file VBoxManageHostonly.cpp

A bit of random googling led me to something that seemed vaguely related to my blocker:

I randomly chose to try one of the solutions (by ‘scottblinch’) to downgrade my VirtualBox version to 6.1.26 (from latest version which is 6.1.28).

It no longer has a problem starting up minikube.

minikube start --mount=True --mount-string="/var/tmp:/var/tmp" --vm-driver=virtualbox

:grinning_face_with_smiling_eyes: minikube v1.23.2 on Darwin 11.6
:sparkles: Using the virtualbox driver based on existing profile
:+1: Starting control plane node minikube in cluster minikube
:arrows_counterclockwise: Restarting existing virtualbox VM for “minikube” …
:whale: Preparing Kubernetes v1.22.2 on Docker 20.10.8 …
:black_small_square: Generating certificates and keys …
:black_small_square: Booting up control plane …
:black_small_square: Configuring RBAC rules …
:file_folder: Creating mount /var/tmp:/var/tmp …
:black_small_square: Using image gcr.io/k8s-minikube/storage-provisioner:v5
╭───────────────────────────────────────────────────────────────────────────────────────────────────╮
│ │
│ You have selected “virtualbox” driver, but there are better options ! │
│ For better performance and support consider using a different driver: │
│ - hyperkit │
│ │
│ To turn off this warning run: │
│ │
│ $ minikube config set WantVirtualBoxDriverWarning false │
│ │
│ │
│ To learn more about on minikube drivers checkout Drivers | minikube
│ To see benchmarks checkout CPU Usage Benchmarks | minikube
│ │
╰───────────────────────────────────────────────────────────────────────────────────────────────────╯
:star2: Enabled addons: storage-provisioner, default-storageclass
:mag_right: Verifying Kubernetes components…
:surfing_man: Done! kubectl is now configured to use “minikube” cluster and “default” namespace by default

(Ahhh yes the vague meandering googling mysterious world of software development.)

Hi,

I re-install the older version (6.1.28) on Mac OS (Big Sur), still got the same problem:

Blockquote

StartHost failed, but will try again: driver start: Error setting up host only network on machine start: The host-only adapter we just created is not visible. This is a well known VirtualBox bug. You might want to uninstall it and reinstall at least version 5.0.12 that is is supposed to fix this issue…

Blockquote

Have any idea on it?

thanks
Eric