fnichol / dvm

An on demand Docker virtual machine, thanks to Vagrant and boot2docker. Works great on Macs and other platforms that don't natively support the Docker daemon. Support VirtualBox, VMware, and Parallels.
http://fnichol.github.io/dvm
Apache License 2.0
457 stars 67 forks source link

`dvm up` hangs on VMFusion 6, missing OS #42

Open bmabey opened 10 years ago

bmabey commented 10 years ago

When I run dvm up using VMFusion as my provider the VM never boots, it hangs here:

$ dvm up
Bringing machine 'dvm' up with 'vmware_fusion' provider...
==> dvm: Cloning VMware VM: 'boot2docker-1.0.1'. This can take some time...
==> dvm: Verifying vmnet devices are healthy...
==> dvm: Preparing network adapters...
==> dvm: Fixed port collision for 22 => 2222. Now on port 2200.
==> dvm: Starting the VMware VM...
==> dvm: Waiting for the VM to finish booting...

When I launch the VM from Fusion's GUI I see:

PXE-M0F: Exiting Intel PXE Rom.
Operating System not found

The vmware.log reads:

2014-07-02T20:35:28.346-07:00| vcpu-0| I120: Msg_Post: Warning
2014-07-02T20:35:28.346-07:00| vcpu-0| I120: [msg.Backdoor.OsNotFound.Mac] No operating system was found. Check your Startup Disk in the virtual machine settings. If you have not installed an operating system yet, you can choose an installation disc or disc image in the CD/DVD settings and restart the virtual machine.
2014-07-02T20:35:28.346-07:00| vcpu-0| I120: ----------------------------------------
2014-07-02T20:35:28.346-07:00| vcpu-0| I120: MsgIsAnswered: Using builtin default 'OK' as the answer for 'msg.Backdoor.OsNotFound.Mac'
2014-07-02T20:38:00.904-07:00| vmx| I120: VmdbAddConnection: cnxPath=/db/connection/#5/, cnxIx=2
2014-07-02T20:38:00.950-07:00| vmx| I120: VMXVmdbCbVmVmxExecState: Exec state change requested to state poweredOn without reset, default, softOptionTimeout: 0.
2014-07-02T20:38:00.999-07:00| mks| I120: KHBKL: Unable to parse keystring at: ''
2014-07-02T20:38:00.999-07:00| mks| I120: KHBKL: Unable to parse keystring at: ''
2014-07-02T20:38:01.322-07:00| mks| I120: GL-Backend: successfully started by HWinMux to do window composition.
2014-07-02T20:38:01.326-07:00| mks| I120: MKS-SWB: Number of MKSWindows changed: 1 rendering MKSWindow(s) of total 1.
2014-07-02T20:38:01.376-07:00| vmx| I120: TOOLS received request in VMX to set option 'synctime' -> '1'
2014-07-02T20:38:01.401-07:00| vmx| I120: VMXVmdb_SetCfgState: cfgReqPath=/vm/#_VMX/vmx/cfgState/req/#6/, remDevPath=/vm/#_VMX/vmx/vigor/setCfgStateReq/#40b/in/

Did I do something wrong or is the latest not working with VMFusion?

fnichol commented 10 years ago

Yeah, I wish this were not still an issue--I take it you're running Vagrant 1.6.0 or later?

I have a tiny bit of background in an old blog post, but the only decent workaround I've settled on was to using version 1.5.4 of Vagrant with the VMware Fusion provider. The related issues are linked in the post.

Sorry this is still happening

349

sykesm commented 10 years ago

@fnichol, I'm sort of working around the problem locally by using a modified snippet of the vmware config from the box's Vagrantfile in dvm's:

  ["vmware_fusion", "vmware_workstation"].each do |vmware|
    config.vm.provider vmware do |v, override|
      override.vm.box_url = "#{release_url}/boot2docker_vmware.box"

      # Copy config from box to work around config merging issue
      vagrant_home = ENV['VAGRANT_HOME'] || File.join(Dir.home, '.vagrant.d')
      v.vmx["bios.bootOrder"] = "CDROM,hdd"
      v.vmx["ide1:0.present"] = "TRUE"
      v.vmx["ide1:0.fileName"] = Dir.glob("#{vagrant_home}/boxes/boot2docker-#{b2d_version}/**/*vmware*/boot2docker-vagrant.iso").first
      v.vmx["ide1:0.deviceType"] = "cdrom-image"

      v.vmx["memsize"] = Integer(memory)
      v.vmx["numvcpus"] = Integer(cpus)
    end
  end

I'm happily running on Vagrant 1.6.3 with that modification. Perhaps it makes sense to make similar changes part of dvm?

zaps commented 10 years ago

At the risk of adding a "me too!" post, I can confirm that applying @sykesm's modification to my ~/.dvm/Vagrantfile worked like a charm on my Fusion 6/Vagrant 1.6.3 system.

rouge8 commented 10 years ago

This seems fixed with version 2.5.2 of the vagrant-vmware-fusion plugin. Works for me and also https://github.com/mitchellh/boot2docker-vagrant-box/issues/48#issuecomment-51965835