Box fails to unpackage on Vagrant 1.6.2 / OSX (xz utility required)
Closed this issue · 11 comments
When I run 'vagrant up' in this project (using Vagrant 1.6.2 / OSX Mavericks), Vagrant can't parse the box once downloaded and produces the following error:
default: Downloading: https://github.com/flynn/flynn-demo/releases/download/v0.4.0/flynn-base_virtualbox.box
The box failed to unpackage properly. Please verify that the box
file you're trying to add is not corrupted and try again. The
output from attempting to unpackage (if any):
bsdtar: Error opening archive: Can't initialize filter; unable to run program "xz -d -qq"
On closer inspection it is complaining because the xz
utility is not installed by default in Mavericks, so users on this platform should brew install xz
first. Alternatively, should xz be added (or perhaps removed if not really needed?) as a dependency of flynn-demo?
Every other pre-packaged Vagrant box I have used works fine, leading me to think this is something specific to flynn-demo's box rather than a general Vagrant bug. But I could be mistaken.
How did you install Vagrant?
Vagrant 1.6.2 installed from .pkg
K, testing locally with xz not installed.
Replicated. I think this is a Vagrant bug, I'm pretty sure the omnibus installers are supposed to include all dependencies. I will file a bug and add a note to the README.
After further research, it looks like Vagrant might only support 7-zip formatted LZMA compression. I'm testing now.
If it helps... I can confirm this bug
A box compressed with bsdtar --lzma
fails with a similar message:
bsdtar: Error opening archive: Can't initialize filter; unable to run program "lzma -d -qq"
Still testing...
A box compressed with 7z
fails with this error:
x packer_virtualbox-iso_virtualbox.box: LZMA codec is unsupported
bsdtar: Error exit delayed from previous errors.
Filing an upstream issue now.
Upstream issue: hashicorp/vagrant#3893
On mac this fixed the issue
$ brew install xz
@srobertson yep, I've noted that in the README.