Vagrant box rockylinux/8 fails for virtualbox provider with error VBOX_E_OBJECT_NOT_FOUND

To enable UEFI in VirtualBox 7.0 there’s info in the respective manuals:

To test the supplied fix:

  • Create Vagrantfile in working directory:
    Vagrant.configure("2") do |config|
      config.vm.box = "rockylinux/8"
      config.vm.provider "virtualbox" do |domain|
        domain.customize ["modifyvm", :id, "--firmware", "efi"]
      end
    end
    
  • Create bugfix box metadata file named box-metadata.json in working directory:
    {
      "name" : "rockylinux/8",
      "description" : "Rocky Linux 8 7.0.0 Bugfix",
      "versions" : [
        {
          "version" : "7.0.1-20221213.0",
          "providers" : [
            {
              "name" : "virtualbox",
              "url" : "http://dl.rockylinux.org/pub/rocky/8/images/x86_64/Rocky-8-Vagrant-Vbox-8.7-20221213.0.x86_64.box"
            }
          ]
        }
      ]
    }
    
  • Add bugfix box:
    vagrant box add box-metadata.json
    
  • Bring up the box:
    vagrant up
    
  • Box runs without error.
    $ vagrant ssh -- "sudo cat /etc/rocky-release"
    Rocky Linux release 8.7 (Green Obsidian)
    

Thanks again @nazunalika

3 Likes