Errors running "vagrant up"

Hi Kenneth,

I run a Mac with Mountain Lion (10.8) on it with the latest Virtualbox (4.2.12) and Vagrant (1.2.2). When I run "vagrant up", I get these errors, although it says the VM us running afterward. Could you perpaps shed some light on my problem please?

(output is below)

Thanks, Wim

⌘ ~/Sites/gswd/ ls
total 696
-rw-r--r--@  1 wimo  staff     305 Nov 24 01:45 Cheffile
-rw-r--r--@  1 wimo  staff    2741 Dec  1 02:10 Vagrantfile
drwxr-xr-x  18 wimo  staff     612 Nov 24 01:47 cookbooks
-rw-r--r--@  1 wimo  staff  346677 May  8 04:18 gswd-vagrant.zip
drwxr-xr-x   3 wimo  staff     102 Nov 23 23:21 site-cookbooks
⌘ ~/Sites/gswd/ vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
[default] Box 'precise64' was not found. Fetching box from specified URL for
the provider 'virtualbox'. Note that if the URL does not have
a box for this provider, you should interrupt Vagrant now and add
the box yourself. Otherwise Vagrant will attempt to download the
full box prior to discovering this error.
Downloading or copying the box...
Extracting box...te: 665k/s, Estimated time remaining: --:--:--)
Successfully added box 'precise64' with provider 'virtualbox'!
[default] Importing base box 'precise64'...
[default] Matching MAC address for NAT networking...
[default] Setting the name of the VM...
[default] Clearing any previously set forwarded ports...
[default] Creating shared folders metadata...
[default] Clearing any previously set network interfaces...
[default] Preparing network interfaces based on configuration...
[default] Forwarding ports...
[default] -- 22 => 2222 (adapter 1)
[default] -- 8000 => 8888 (adapter 1)
[default] Booting VM...
[default] Waiting for VM to boot. This can take a few minutes.
[default] VM booted and ready for use!
[default] Configuring and enabling network interfaces...
[default] Mounting shared folders...
[default] -- /vagrant
[default] -- /tmp/vagrant-chef-1/chef-solo-1/cookbooks
[default] -- /tmp/vagrant-chef-1/chef-solo-2/cookbooks
[default] Running provisioner: shell...
[default] Running: inline script
stdin: is not a tty
Successfully installed mixlib-cli-1.3.0
Successfully installed net-ssh-2.6.7
Successfully installed chef-11.4.4
3 gems installed
[default] Running provisioner: chef_solo...
Generating chef JSON and uploading...
Running chef-solo...
stdin: is not a tty
[2013-05-08T02:32:21+00:00] INFO: *** Chef 11.4.4 ***
[2013-05-08T02:32:23+00:00] INFO: Setting the run_list to ["recipe[postgresql::server_debian]", "recipe[postgresql::ruby]", "recipe[redis::server]", "recipe[git]", "recipe[mercurial]", "recipe[emacs]", "recipe[vim]", "recipe[nano]", "recipe[gswd::database]"] from JSON
[2013-05-08T02:32:23+00:00] INFO: Run List is [recipe[postgresql::server_debian], recipe[postgresql::ruby], recipe[redis::server], recipe[git], recipe[mercurial], recipe[emacs], recipe[vim], recipe[nano], recipe[gswd::database]]
[2013-05-08T02:32:23+00:00] INFO: Run List expands to [postgresql::server_debian, postgresql::ruby, redis::server, git, mercurial, emacs, vim, nano, gswd::database]
[2013-05-08T02:32:23+00:00] INFO: Starting Chef Run for precise64
[2013-05-08T02:32:23+00:00] INFO: Running start handlers
[2013-05-08T02:32:23+00:00] INFO: Start handlers complete.
[2013-05-08T02:32:23+00:00] WARN: Missing gem 'right_aws'
================================================================================
Recipe Compile Error in /tmp/vagrant-chef-1/chef-solo-1/cookbooks/yum/resources/key.rb
================================================================================
ArgumentError
-------------
wrong number of arguments (2 for 1)
Cookbook Trace:
---------------
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/resource/lwrp_base.rb:42:in `const_defined?'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/resource/lwrp_base.rb:42:in `build_from_file'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:208:in `load_lwrp_resource'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:193:in `load_lwrps_from_cookbook'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:192:in `each'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:192:in `load_lwrps_from_cookbook'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:120:in `compile_lwrps'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:119:in `each'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:119:in `compile_lwrps'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_context/cookbook_compiler.rb:72:in `compile'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_context.rb:86:in `load'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/client.rb:224:in `setup_run_context'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/client.rb:467:in `do_run'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/client.rb:200:in `run'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/application.rb:190:in `run_chef_client'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/application/solo.rb:239:in `run_application'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/application/solo.rb:231:in `loop'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/application/solo.rb:231:in `run_application'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/application.rb:73:in `run'
  /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/chef-solo:25
  /opt/vagrant_ruby/bin/chef-solo:19:in `load'
  /opt/vagrant_ruby/bin/chef-solo:19
Relevant File Content:
----------------------
/opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/resource/lwrp_base.rb:
 35:  
 36:        # Evaluates the LWRP resource file and instantiates a new Resource class.
 37:        def self.build_from_file(cookbook_name, filename, run_context)
 38:          rname = filename_to_qualified_string(cookbook_name, filename)
 39:  
 40:          # Add log entry if we override an existing light-weight resource.
 41:          class_name = convert_to_class_name(rname)
 42>>         if Resource.const_defined?(class_name, false)
 43:            old_class = Resource.send(:remove_const, class_name)
 44:            # CHEF-3432 -- Chef::Resource keeps a list of subclasses; need to
 45:            # remove old ones from the list when replacing.
 46:            resource_classes.delete(old_class)
 47:            Chef::Log.info("#{class_name} light-weight resource already initialized -- overriding!")
 48:          end
 49:  
 50:          resource_class = Class.new(self)
 51:  
[2013-05-08T02:32:24+00:00] ERROR: Running exception handlers
[2013-05-08T02:32:24+00:00] ERROR: Exception handlers complete
[2013-05-08T02:32:24+00:00] FATAL: Stacktrace dumped to /tmp/vagrant-chef-1/chef-stacktrace.out
[2013-05-08T02:32:24+00:00] FATAL: ArgumentError: wrong number of arguments (2 for 1)
Chef never successfully completed! Any errors should be visible in the
output above. Please fix your recipes so that they properly complete.
⌘ ~/Sites/gswd/ vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
[default] VirtualBox VM is already running.
⌘ ~/Sites/gswd/
Sorry You must be a logged in, registered user to answer a question.

Answers

Weird. I tried Nathan's solution:

$ vagrant ssh
$ sudo apt-get update
$ sudo apt-get install ruby1.9.3
$ exit
$ vagrant reload

But I got this error message: ``` PS C:\Users\Chris\Documents\django_dev\gswd-vagrant> vagrant reload [default] Attempting graceful shutdown of VM... [default] Setting the name of the VM... [default] Clearing any previously set forwarded ports... [default] Creating shared folders metadata... [default] Clearing any previously set network interfaces... [default] Preparing network interfaces based on configuration... [default] Forwarding ports... [default] -- 22 => 2222 (adapter 1) [default] -- 8000 => 8888 (adapter 1) [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] -- /vagrant [default] -- /tmp/vagrant-chef-1/chef-solo-1/cookbooks [default] -- /tmp/vagrant-chef-1/chef-solo-2/cookbooks [default] Running provisioner: shell... [default] Running: inline script stdin: is not a tty Building native extensions. This could take a while... ERROR: Error installing chef: ERROR: Failed to build gem native extension.

    /usr/bin/ruby1.9.1 extconf.rb

creating Makefile

make sh: 1: make: not found

Gem files will remain installed in /var/lib/gems/1.9.1/gems/yajl-ruby-1.1.0 for inspection. Results logged to /var/lib/gems/1.9.1/gems/yajl-ruby-1.1.0/ext/yajl/gem_make.out The following SSH command responded with a non-zero exit status. Vagrant assumes that this means the command failed!

chmod +x /tmp/vagrant-shell && /tmp/vagrant-shell ```

I'm trying to get vagrant working on a Dell laptop running Windows Vista Business. The laptop is a 32 bit laptop. Not sure if that makes a difference. If someone can help me with this frustrating process, you will have my eternal gratitude. Not sure how much that is worth though...

!@#!% Is there a way for me to edit comment, so that it is legible!!!???
Christopher Spears on

I had the same problem and upgrading ruby to version 1.9.3 fixed it.

$ vagrant ssh
$ sudo apt-get update
$ sudo apt-get install ruby1.9.3
$ exit
$ vagrant reload
Weird. I tried your solution and got this error message:
Christopher Spears on
Weird. I tried your solution and got this error message:
Christopher Spears on
Weird. I tried your solution and got this error message:
Christopher Spears on
Thank you Nathan, but why did it have to be so difficult? Seems like the VM is where a lot of people hit a wall and we have not even begun playing with Django yet.
Peteraa on
Thank you Nathan, but why did it have to be so difficult? Seems like the VM is where a lot of people hit a wall and we have not even begun playing with Django yet.
Peteraa on
Fixed using your file. (updating ruby didn't work for some reason.) Thanks very much Nathan!
RogerTangos on
(Mac 10.8.1) The new Vagrant file gswd-vagrant file from Nathan worked. I first tried apt-get install'ing ruby1.9.3 and symlinking /etc/alternatives/ruby to /usr/bin/ruby1.9.3 but that didn't work. Thanks Nathan!
Bryan Wilson on
This fixed it! Thank you Nathan!
jantGuerrero on
Or use this vagrant file instead of the default: https://dl.dropboxusercontent.com/u/1343706/gswd-vagrantfile
Nathan on

For me it was an error that vagrant up does not use the right version of chef (a to old version).

I did: vagrant destroy

(vagrant reload did not do the trick)

And then i changed this ruby config.vm.provision :shell, :inline => "gem install --no-ri --no-rdoc chef" line in the Vagrantfile to: Ruby config.vm.provision :shell, :inline => "gem install chef --version 11.4.2 --no-rdoc --no-ri"

And then when vagrant up worked.

I found the answer here: http://stackoverflow.com/questions/11325479/how-to-control-the-version-of-chef-that-vagrant-uses-to-provision-vms

Note that you do not need to destroy the VM, simply replace the install chef gem on it, basically, do a "vagrant ssh" and then a "sudo gem uninstall --all chef"
Steven Fernandez on
Note that you do not need to destroy the VM, simply replace the install chef gem on it, basically:
Steven Fernandez on
Note that you do not need to destroy the VM, simply replace the install chef gem on it, basically:
Steven Fernandez on
This fixed it for me. Thanks!
Jeremy Johnson on
The ruby and Ruby thing infront of the lines in the Vagrant file shall not be there, but I can not find a way to edit this post :(
Hatlen on

I was experiencing the same error. Installing the latest version of chef from http://www.opscode.com/chef/install/ and rerunning vagrant resolved the issue. It seems to have something to do with the version mismatch of some recipes installed and the version of Ruby used in older vagrant versions.

I'm using win7. I Downloaded chef-client 11.4.2.1 . Please note this is not latest version. The latest version did not work for me
kc1 on
I'm using win7. I Downloaded chef-client 11.4.2.1 . Please note this is not latest version. The latest version did not work for me
kc1 on
@adotellison You use the version for the OS that's running in the VM, with this I believe it's Ubuntu 12.04
Leonard Jackson on
I'm getting the same error too, does anyone have an answer? I have download the latest version of Chef but there isn't a one for Mountain Lion (10.8) is this an issue?
adotellison on
I have the same error - this did not fix it.
TurtlesAreCute on

The following worked for me

  1. vagrant up
  2. vagrant ssh
  3. edit line 11 in postinstall.sh - replace (ruby_ver="1.8.7-p358") with (ruby_ver="1.9.3-p429")
  4. execute the script - sudo ./postinstall.sh
  5. exit out of VM.
  6. vagrant halt
  7. vagrant up

You should now see no errors when you bring up your VM.

I was able to combine answers from a few different places to solve this problem myself.

I'm running windows 7 64bit.

You should be able to ssh to the VM despite the errors. Once you've ssh'd to the VM, install these packages:

sudo apt-get install build-essential ruby1.9.1 libopenssl-ruby ruby1.9.1-dev

It seems that the box at vagrantbox.es no longer contains build-essentials (make fails) and includes ruby 1.8.x which Chef doesn't like in this instance.

Hope this helps!

upgraded to ruby 1.9 as someone in this thread recommended but still getting the same error as OP.

actually, I just tried to reinstall this vagrant deployment and it's not working. Looks like that gist wasn't the answer after all. Bummer, I'm back and square 1
Kevin Wilson on
@ Leonard Jackson - this install gist should be executed on the virtual machine
Kevin Wilson on
@ Leonard Jackson - this install gist should be executed on the virtual machine
Kevin Wilson on
@ Kevin Wilson, do you install gist from bartimaeus into the vm or on your local machine?
Leonard Jackson on
Sorry, let me try that again, here's the link: https://gist.github.com/bartimaeus/2845824
Kevin Wilson on
Sorry, let me try that again, here's the link: https://gist.github.com/bartimaeus/2845824
Kevin Wilson on
I noticed that even after trying to install ruby1.9, it still wasn't being used at default. In order to get it running as default, I followed these instructions and "vagrant up" appears to be working for me:
Kevin Wilson on

After upgrading to ruby 1.9 in the VM and running "sudo ./postinstall.sh" and then "vagrant halt; vagrant up", I get the following error:

Any idea why this happens?

⌘ ~/Sites/gswd/ vagrant up Bringing machine 'default' up with 'virtualbox' provider... [default] Setting the name of the VM... [default] Clearing any previously set forwarded ports... [default] Creating shared folders metadata... [default] Clearing any previously set network interfaces... [default] Preparing network interfaces based on configuration... [default] Forwarding ports... [default] -- 22 => 2222 (adapter 1) [default] -- 8000 => 8888 (adapter 1) [default] Booting VM... [default] Waiting for VM to boot. This can take a few minutes. [default] VM booted and ready for use! [default] Configuring and enabling network interfaces... [default] Mounting shared folders... [default] -- /vagrant [default] -- /tmp/vagrant-chef-1/chef-solo-1/cookbooks [default] -- /tmp/vagrant-chef-1/chef-solo-2/cookbooks [default] Running provisioner: shell... [default] Running: inline script stdin: is not a tty Building native extensions. This could take a while... ERROR: Error installing chef: ERROR: Failed to build gem native extension.

    /usr/bin/ruby1.9.1 extconf.rb

creating Makefile

make sh: 1: make: not found

Gem files will remain installed in /var/lib/gems/1.9.1/gems/yajl-ruby-1.1.0 for inspection. Results logged to /var/lib/gems/1.9.1/gems/yajl-ruby-1.1.0/ext/yajl/gem_make.out The following SSH command responded with a non-zero exit status. Vagrant assumes that this means the command failed!

chmod +x /tmp/vagrant-shell && /tmp/vagrant-shell ⌘ ~/Sites/gswd/

Do the sudo apt-get install make after you run vagrant ssh, otherwise you will get message that make is already installed
Bharath on
After installing ruby 1.9, I also had to install make (sudo apt-get install make)
piffle on

The version of Ruby is part of the VM so I don't think it can be that.

I decided to build my own Ubuntu Precise VM instead, install the required software and setup the port forwarding and shared folder symlinks myself.

Thanks, Wim

I had this issue but I talked with Kenneth and was able to sort it out. He mentioned below that you need ruby 1.9 instead of ruby 1.8. Here's what I did after my first "vagrant up" 1. vagrant ssh 2. sudo apt-get install ruby1.9.1-full 3. Exit your ssh session and run "vagrant halt" 4. vagrant up again and it should go through the whole process without any errors.

Worked for me, good luck!

I got a similar, if not identical error on Win 7:

←[0m ←[31mRecipe Compile Error in /tmp/vagrant-chef-1/chef-solo-1/cookbooks/yum/resou

rces/key.rb←[0m

←[0m

←[0m ArgumentError←[0m -------------←[0m wrong number of arguments (2 for 1)←[0m

←[0m Cookbook Trace:←[0m ---------------←[0m /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/resource/ lwrp_base.rb:42:in const_defined?' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/resource/ lwrp_base.rb:42:inbuild_from_file' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_conte xt/cookbook_compiler.rb:208:in load_lwrp_resource' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_conte xt/cookbook_compiler.rb:193:inload_lwrps_from_cookbook' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_conte xt/cookbook_compiler.rb:192:in each' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_conte xt/cookbook_compiler.rb:192:inload_lwrps_from_cookbook' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_conte xt/cookbook_compiler.rb:120:in compile_lwrps' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_conte xt/cookbook_compiler.rb:119:ineach' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_conte xt/cookbook_compiler.rb:119:in compile_lwrps' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_conte xt/cookbook_compiler.rb:72:incompile' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/run_conte xt.rb:86:in load' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/client.rb :224:insetup_run_context' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/client.rb :467:in do_run' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/client.rb :200:inrun' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/applicati on.rb:190:in run_chef_client' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/applicati on/solo.rb:239:inrun_application' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/applicati on/solo.rb:231:in loop' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/applicati on/solo.rb:231:inrun_application' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/applicati on.rb:73:in run' /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/chef-solo:25 /opt/vagrant_ruby/bin/chef-solo:19:inload' /opt/vagrant_ruby/bin/chef-solo:19←[0m

←[0m Relevant File Content:←[0m ----------------------←[0m /opt/vagrant_ruby/lib/ruby/gems/1.8/gems/chef-11.4.4/bin/../lib/chef/resource/lw rp_base.rb:

35: 36: # Evaluates the LWRP resource file and instantiates a new Resource c lass. 37: def self.build_from_file(cookbook_name, filename, run_context) 38: rname = filename_to_qualified_string(cookbook_name, filename) 39: 40: # Add log entry if we override an existing light-weight resource. 41: class_name = convert_to_class_name(rname) 42>> if Resource.const_defined?(class_name, false) 43: old_class = Resource.send(:remove_const, class_name) 44: # CHEF-3432 -- Chef::Resource keeps a list of subclasses; need t o 45: # remove old ones from the list when replacing. 46: resource_classes.delete(old_class) 47: Chef::Log.info("#{class_name} light-weight resource already init ialized -- overriding!") 48: end 49: 50: resource_class = Class.new(self) 51: ←[0m

←[0m [2013-05-10T05:29:36+00:00] ERROR: Running exception handlers [2013-05-10T05:29:36+00:00] ERROR: Exception handlers complete [2013-05-10T05:29:36+00:00] FATAL: Stacktrace dumped to /tmp/vagrant-chef-1/chef -stacktrace.out [2013-05-10T05:29:36+00:00] FATAL: ArgumentError: wrong number of arguments (2 f or 1) Chef never successfully completed! Any errors should be visible in the output above. Please fix your recipes so that they properly complete.

I asked the guy that created the Chef recipes for me (the awesome @kantrn that the likely problem is that you've got Ruby 1.8. I'm not sure what you need to upgrade to Ruby 1.9, but that seems to be the answer.

"postinstall.sh completed successfully. After running "sudo ./postinstall.sh", I now get the following error after running "vagrant halt; vagrant up": ⌘ ~/Sites/gswd/ vagrant up Bringing machine 'default' up with 'virtualbox' provider... [default] Setting the name of the VM... [default] Clearing any previously set forwarded ports... [default] Creating shared folders metadata... [default] Clearing any previously set network interfaces... [default] Preparing network interfaces based on configuration... [default] Forwarding ports... [default] -- 22 => 2222 (adapter 1) [default] -- 8000 => 8888 (adapter 1) [default] Booting VM... [default] Waiting for VM to boot. This can take a few minutes. [default] VM booted and ready for use! [default] Configuring and enabling network interfaces... [default] Mounting shared folders... [default] -- /vagrant [default] -- /tmp/vagrant-chef-1/chef-solo-1/cookbooks [default] -- /tmp/vagrant-chef-1/chef-solo-2/cookbooks [default] Running provisioner: shell... [default] Running: inline script stdin: is not a tty Building native extensions. This could take a while... ERROR: Error installing chef: ERROR: Failed to build gem native extension. /usr/bin/ruby1.9.1 extconf.rb creating Makefile make sh: 1: make: not found Gem files will remain installed in /var/lib/gems/1.9.1/gems/yajl-ruby-1.1.0 for inspection. Results logged to /var/lib/gems/1.9.1/gems/yajl-ruby-1.1.0/ext/yajl/gem_make.out The following SSH command responded with a non-zero exit status. Vagrant assumes that this means the command failed! chmod +x /tmp/vagrant-shell && /tmp/vagrant-shell ⌘ ~/Sites/gswd/
Wim Olivier on
Thanks Kenneth and "pmasucci". Upgrading to Ruby 1.9 in the VM worked. Kenneth, you should change the Chef scripts to install Ruby 1.9 before doing anything else to avoid more people having this problem. Regards,
Wim Olivier on

Is this happening the Nth time after you vagrant up or the 1st time? If it's happening after the first time, it seems like that's Vagrant trying to re-run the cookbooks when it doesn't need to.

If it's happening on the first time, my best suggestion is making sure you're running the same versions of VirtualBox and Vagrant that I am (Vbox is 4.2.4 and Vagrant is 1.0.5).

Sorry for the multiple messages.. The Carriage return instead of a new line, just posts what I typed. Just to let you know, I did the first introduction chapter with no issues. When I got back to start working on the second chapter, I started getting the errors posted above. Installing ruby1.9 fixed the issue, but I had already destroyed my VM and had to start from scratch. So I am not sure about when to run the postinstall.sh script. After I install ruby1.9? Can you maybe publish a new package which works with ruby1.9?
shireenrao on
There was a problem with the configuration of Vagrant. The error message(s) are printed below: vm: * Base MAC address for eth0/NAT must be set. Contact box maintainer for more information.
shireenrao on
but then after reading the VagrantFile, I saw the comment about puppet not working with ruby1.9. So I uninstalled my virtualbox and vagrant install on my Mountain Lion and then installed Vbox 4.2.4 and Vagrant 1.0.5. That combination does not work either. Here is the error I am getting
shireenrao on
I was getting the same errors as the original post. I tried installing ruby1.9 from a vagrant session by running "sudo apt-get install ruby1.9.1-full"
shireenrao on