Skip to content
dkingofpa edited this page Jun 15, 2012 · 11 revisions
  1. How do I fix Cookbook xforty not found?
  2. My cookbooks folder won't mount. How do I fix it?
  3. Why doesn't drush site-install work when selecting a custom profile?
  4. Why can't vagrant mount my shared folder?
  5. Why did "Drush command terminated abnormally due to an unrecoverable error"?
## Q1. How do I fix Cookbook xforty not found?
 [default] [Wed, 11 Jan 2012 17:29:41 +0000] FATAL: Chef::Exceptions::CookbookNotFound: Cookbook xforty not found. If you're loading xforty from another cookbook, make sure you configure the dependency in your metadata
 : stdout
 The following SSH command responded with a non-zero exit status.
 Vagrant assumes that this means the command failed!

 chef-solo -c /tmp/vagrant-chef-1/solo.rb -j /tmp/vagrant-chef-1/dna.json

 The output of the command prior to failing is outputted below:

A1. You need to run librarian-chef install.

 host$ librarian-chef install

## Q2. My cookbooks folder won't mount. How do I fix it?
 The following SSH command responded with a non-zero exit status.
 Vagrant assumes that this means the command failed!

 mount -t vboxsf -o uid=`id -u vagrant`,gid=`id -g vagrant` v-csc-1 /tmp/vagrant-chef-1/chef-solo-1/cookbooks

A2. Make sure your cookbooks folder exists.

 host$ librarian-chef install

## Q3. Why doesn't drush site-install work when selecting a custom profile?

We have experienced problems when using both site-install and port_forwards to install drupal with custom profiles.

A3. Try switching to host-only networking and running the install using the http://local.vbox/install.php.

This thread talks a little bit about the complexities. http://drupal.stackexchange.com/questions/4519/why-is-drush-behaving-strangely-on-this-site-install-run-of-open-atrium/6374#6374


## Q4. Why can't vagrant mount my shared folder?

In my Vagrantfile:

srv_path = File.expand_path(File.dirname(__FILE__)) + "/srv"
config.vm.share_folder("srv", "/srv", srv_path, :owner => "vagrant", :group => "www-data", :create => true)    

Doing a vagrant up:

[default] Importing base box 'CentOS-5.7-x86_64'...
[default] Matching MAC address for NAT networking...
[default] Clearing any previously set forwarded ports...
[default] Forwarding ports...
[default] -- 22 => 2222 (adapter 1)
[default] -- 80 => 4567 (adapter 1)
[default] Creating shared folders metadata...
[default] Clearing any previously set network interfaces...
[default] Running any VM customizations...
[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] -- srv: /srv
The following SSH command responded with a non-zero exit status.
Vagrant assumes that this means the command failed!

mount -t vboxsf -o uid=`id -u vagrant`,gid=`id -g www-data` srv /srv

Running the mount command directly on the vm:

[vagrant@localhost ~]$ sudo mount -t vboxsf -o uid=`id -u vagrant`,gid=`id -g www-data` srv /srv
id: www-data: No such user
uid= requires an argument (i.e. uid==<arg>)

A4. Using wrong group and misconfigured basebox.

  1. The www-data group are incorrect for CentOS. Should be apache.
  2. CentOS basebox didn't have httpd installed so the apache group didn't exist.

## Q5. Why did "Drush command terminated abnormally due to an unrecoverable error"?

Can happen when running something as simple as drush status. No other errors given.

vagrant@ubuntu-10 /srv/www $ drush status
Drush command terminated abnormally due to an unrecoverable error.                            [error]

A5. Headers are being output or a php exit is called when they shouldn't be.

This can be difficult to track down because you don't get any output. Some possibilities:

  1. <front> is being redirected, which outputs headers when drush doesn't expect them. See path_redirect or redirect modules.
  2. A php exit is called unexpectedly.
  3. In general, a misbehaving module that only assumes a request is being made via the web.
  4. Poorly written hook_init in a module that does any of the above.