09 Sep 2012, 09:19
Greg-for-profiles_pragsmall

Greg Clarke (5 posts)

Hi

I followed the instructions to get the first_box going with lucid64, but never got the “VM booted…” message.

I’ve repeated this process several times, with the same result each time. The “vagrant up” process does not finish - I eventually kill it.

You’ll see below that I waited nearly 20 minutes before killing it in the session below.

I know you cover the guest additions warning message, but I don’t get far enough to do anything about that. I get an error for vagrant ssh, which I’ve also included below.

Running Mac OS X Mountain Lion: 10.8.1

gregcmbp Sun Sep 09 18:33:22   ~/deployingrails  
$ mkdir first_box
gregcmbp Sun Sep 09 18:33:28  ~/deployingrails  
$ cd first_box/
gregcmbp Sun Sep 09 18:33:31  ~/deployingrails/first_box  
$ vagrant init
A `Vagrantfile` has been placed in this directory. You are now
ready to `vagrant up` your first virtual environment! Please read
the comments in the Vagrantfile as well as documentation on
`vagrantup.com` for more information on using Vagrant.
gregcmbp Sun Sep 09 18:33:37  ~/deployingrails/first_box  
$ ls
.           ..          Vagrantfile
gregcmbp Sun Sep 09 18:33:48  ~/deployingrails/first_box  
$ vi Vagrantfile 
gregcmbp Sun Sep 09 18:34:24  ~/deployingrails/first_box  
$ vi Vagrantfile 
gregcmbp Sun Sep 09 18:34:42  ~/deployingrails/first_box  
$ vagrant up
[default] Importing base box 'lucid64'...
[default] The guest additions on this VM do not match the install version of
VirtualBox! This may cause things such as forwarded ports, shared
folders, and more to not work properly. If any of those things fail on
this machine, please update the guest additions and repackage the
box.


Guest Additions Version: 4.1.16
VirtualBox Version: 4.1.22
[default] Matching MAC address for NAT networking...
[default] Clearing any previously set forwarded ports...
[default] Forwarding ports...
[default] -- 22 => 2222 (adapter 1)
[default] Creating shared folders metadata...
[default] Clearing any previously set network interfaces...
[default] Booting VM...
[default] Waiting for VM to boot. This can take a few minutes.
^C[default] Waiting for cleanup before exiting...
Vagrant exited after cleanup due to external interrupt.
gregcmbp Sun Sep 09 18:52:31  ~/deployingrails/first_box  
$ cat Vagrantfile 
# -*- mode: ruby -*-
# vi: set ft=ruby :

Vagrant::Config.run do |config|
  config.vm.box = "lucid64"
end


gregcmbp Sun Sep 09 18:54:10  ~/deployingrails/first_box  
$ vagrant ssh
ssh_exchange_identification: Connection closed by remote host

Greg

09 Sep 2012, 11:06
Greg-for-profiles_pragsmall

Greg Clarke (5 posts)

Hi

I found some getting-started instructions at vagrantup.com and tried those. First for lucid32:

$ vagrant box add lucid32 http://files.vagrantup.com/lucid32.box
$ vagrant init lucid32
$ vagrant up

This booted the vm and I was able to “vagrant ssh” in.

Then I tried the same instructions, but substituted lucid64 for lucid32, and they worked too.

gregcmbp Sun Sep 09 20:22:52  ~/deployingrails  
$ mkdir lucid64
gregcmbp Sun Sep 09 20:23:01  ~/deployingrails  
$ cd lucid64
gregcmbp Sun Sep 09 20:23:04  ~/deployingrails/lucid64  
$ vagrant box add lucid64_2 http://files.vagrantup.com/lucid64.box
[vagrant] Downloading with Vagrant::Downloaders::HTTP...
[vagrant] Downloading box: http://files.vagrantup.com/lucid64.box
[vagrant] Extracting box...
[vagrant] Verifying box...
[vagrant] Cleaning up downloaded box...
gregcmbp Sun Sep 09 20:37:25  ~/deployingrails/lucid64  
$ ls
.  ..
gregcmbp Sun Sep 09 20:38:06  ~/deployingrails/lucid64  
$ vagrant init lucid64_2
A `Vagrantfile` has been placed in this directory. You are now
ready to `vagrant up` your first virtual environment! Please read
the comments in the Vagrantfile as well as documentation on
`vagrantup.com` for more information on using Vagrant.
gregcmbp Sun Sep 09 20:38:20  ~/deployingrails/lucid64  
$ vagrant up
[default] Importing base box 'lucid64_2'...
[default] The guest additions on this VM do not match the install version of
VirtualBox! This may cause things such as forwarded ports, shared
folders, and more to not work properly. If any of those things fail on
this machine, please update the guest additions and repackage the
box.

Guest Additions Version: 4.1.16
VirtualBox Version: 4.1.22
[default] Matching MAC address for NAT networking...
[default] Clearing any previously set forwarded ports...
[default] Fixed port collision for 22 => 2222. Now on port 2200.
[default] Forwarding ports...
[default] -- 22 => 2200 (adapter 1)
[default] Creating shared folders metadata...
[default] Clearing any previously set network interfaces...
[default] Booting VM...
[default] Waiting for VM to boot. This can take a few minutes.
[default] VM booted and ready for use!
[default] Mounting shared folders...
[default] -- v-root: /vagrant
gregcmbp Sun Sep 09 20:39:41  ~/deployingrails/lucid64  
$ vagrant ssh
Linux lucid64 2.6.32-38-server #83-Ubuntu SMP Wed Jan 4 11:26:59 UTC 2012 x86_64 GNU/Linux
Ubuntu 10.04.4 LTS

Welcome to the Ubuntu Server!
 * Documentation:  http://www.ubuntu.com/server/doc
New release 'precise' available.
Run 'do-release-upgrade' to upgrade to it.

Welcome to your Vagrant-built virtual machine.
Last login: Thu Jun  7 01:57:06 2012 from 10.0.2.2

Still puzzled by the original problem though.

Greg Clarke

10 Sep 2012, 05:08
Greg-for-profiles_pragsmall

Greg Clarke (5 posts)

Hi

Following up - I’ve now reached the end of section 2.1 with a lucid64_with_ruby193 box that I can “vagrant up” and “vagrant halt” then “vagrant up” again successfully. Phew. But it was a long, hard process. The incompatible guest additions seemed to be the main problem.

After getting the bare lucid64 going as described above, I followed your instructions in the “VirtualBox Guest Additions” section without success, then googled and read lots of posts on vagrant at github. I also found http://software.darrenthetiger.com/2012/01/installing-virtualbox-guest-additions-on-a-vagrant-lucid64-box/ which seemed to be the best alternative detailed advice.

I’ve been going at this now for about 6 hours, and after many restarts and iterations of the various instructions I can’t document a definitive repeatable process.

I can say that after following Darren’s instructions for my version of vbox, I found “sudo restart” (his last instruction) wanted a job number and so failed. Then I exited and tried “vagrant halt” / “vagrant up”, as suggested. But “vagrant up” would still fail, until I tried (after several iterations) to reboot my mac first. That seemed to work because “vagrant up” worked and I noticed the guest additions warning had gone. But I had also opened the box in :gui mode once and tried some of the incantations from a github issues post.

This has been tough going. Vagrant looks so good, I just want it to work a bit more easily.

regards

Greg

10 Sep 2012, 09:06
Greg-for-profiles_pragsmall

Greg Clarke (5 posts)

I should have finished the previous comment with the wish for Vagrant to work consistently.

Via github I see there is an existing problem with Vagrant, #1066

`vagrant up` hangs at "Waiting for VM to boot. This can take a few minutes" 

which was closed today with the comment:

This is a dupe of #391. There is a LOT of info on this bug there. In short: its complicated.

You can see I'm working on various workarounds there. If you have any more to add please add it there. Sorry about this.

There is indeed a lot of info at #391 - 77 comments over the past year, continuing up till last week, but no definitive solutions. And yet the issue is technically closed.

I’m trying to work out a pattern for getting one vm to go up and down consistently. This was after I could get only one of the multiple vms to go up - :app would go up but :db would just hang.

Can I say this is very frustrating without appearing ungrateful?

Greg Clarke

14 Sep 2012, 00:13
Tom_sq_150_pragsmall

Tom Copeland (78 posts)

Yikes, that’s quite a thing. I haven’t upgraded to Mountain Lion; I’m hesitating due to other issues with the v8 gem. Bleah…

  You must be logged in to comment