mitchellh / boot2docker-vagrant-box

Packer scripts to build a Vagrant-compatible boot2docker box.
424 stars 183 forks source link

Unable to boot on vmware, goes straight to PXE #48

Closed jacobat closed 5 years ago

jacobat commented 10 years ago

I'm trying to boot this box on vmware using the example Vagrantfile from: http://docs.vagrantup.com/v2/docker/basics.html

When I run vagrant up --provider=docker and monitor the progress in the GUI, I can see that VMWare is trying to boot from PXE instead of booting into Linux, and then it just hangs there.

I've tested this on a coworkers machine that exhibits the exact same problem.

chadcatlett commented 10 years ago

I ran into this as well, for some reason the resulting VM doesn't have the boot2docker iso attached.

kryton commented 10 years ago

steps to work around

  1. start via command line
  2. go to the gui, and attach the iso (available $HOME/.vagrant.d/boxes/mitchellh-VAGRANTSLASH-boot2docker/0.8.0/vmware_desktop ) for me
  3. connect the CD-drive
  4. restart the VM and restart the command line

It seems to progress further

ashb commented 10 years ago

I just tried something on a clean Vagrantfile. If I have this:

VAGRANTFILE_API_VERSION = "2"

Vagrant.configure("2") do |config|
  config.vm.box = "hashicorp/precise64"
  config.vm.define "db" do |v|
  end

  config.vm.provider "vmware_fusion" do |v|
    v.vmx["bios.bootorder"]    = "CDROM,hdd"
    v.vmx["ide1:0.present"]    = "TRUE"
    v.vmx["ide1:0.filename"]   = File.expand_path("../boot2docker-vagrant.iso", __FILE__)
    v.vmx["ide1:0.devicetype"] = "cdrom-image"
    v.gui = true
  end
end

(I.e. basically like the default here) then the image boots to its HDD. If however I add the following two VMX lines in:

    v.vmx["ide1:0.autodetect"] = "TRUE"
    v.vmx["ide1:0.startConnected"] = "TRUE"

Then it boots off the CD.

This is on VMWare Fusion 6.0.3 here. I'll see if I can now tie this into a working boot2docker Vagrant box for me.

(Thanks to @kryton for the pointer of what was going wrong)

fnichol commented 10 years ago

Confirmed--the appears to be a change made between 1.5.4 and 1.6.0. There is a related issue at mitchellh/vagrant#3996

copumpkin commented 10 years ago

Any updates on this? If nothing else, I'd like to tell it to use virtualbox for boot2docker (I use the vmware fusion provider for most things and it seems to default to it)

bennettrogers commented 10 years ago

Put this in your Vagrantfile: ENV['VAGRANT_DEFAULT_PROVIDER'] = 'virtualbox'

This will force Vagrant to use virtualbox for the docker host.

chadcatlett commented 10 years ago

I tried this running the VMware Fusion v2.5.2 plugin and it now works. I'm not sure if it was fixed in 2.5.1, or 2.5.2.

adambiggs commented 10 years ago

@chadcatlett hard to tell since the changelog hasn't been updated since 2.5.0. Nice to hear this is working though!

boztek commented 9 years ago

I can confirm this works again after updating to latest VMWare fusion plugin (currently 3.0.1).

adambiggs commented 9 years ago

Seems to be working for me now as well.

jacobat commented 5 years ago

People are saying this has been fixed. Closing.