When running Chef for the first time on a VM, you may see an error like the following:
apt-get -q -y install couchdb=0.10.0-1ubuntu2 returned 100, expected 0
The problem is that your Vagrantfile script does not require Chef to do an “apt-get update” before running it’s scripts. This normally triggers updating the apt database, and something is referenced in the Chef script that is missing from the VM.
To fix this, download the cookbook called “apt” and run it prior to running the cookbooks you actually want.
I spent a couple of hours looking for a solution before I saw your post. Thanks a lot.
I run into the same problem installing Oracle’s JDK and PostgreSQL on Ubuntu Precise 12.04.
The error was:
apt-get -q -y install openjdk-6-jdk=6b24-1.11.4-1ubuntu0.12.04.1 returned 100, expected 0