Vagrant fails to bring up xenial64 instance on VirtualBox
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
vagrant (Ubuntu) |
Confirmed
|
Medium
|
Unassigned |
Bug Description
When trying to bring up a local vagrant box using the official vagrant ubuntu/xenial64 image, the process fails with the following error:
$ vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'ubuntu/
==> default: Matching MAC address for NAT networking...
==> default: Checking if box 'ubuntu/xenial64' is up to date...
==> default: Setting the name of the VM: ubuntu-
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
default: Adapter 1: nat
default: Adapter 2: hostonly
==> default: Forwarding ports...
default: 80 (guest) => 8080 (host) (adapter 1)
default: 22 (guest) => 2222 (host) (adapter 1)
==> default: Running 'pre-boot' VM customizations...
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
default: SSH address: 127.0.0.1:2222
default: SSH username: ubuntu
default: SSH auth method: password
default:
default: Inserting generated public key within guest...
default: Removing insecure key from the guest if it's present...
default: Key inserted! Disconnecting and reconnecting using new SSH key...
==> default: Machine booted and ready!
==> default: Checking for guest additions in VM...
==> default: Configuring and enabling network interfaces...
The following SSH command responded with a non-zero exit status.
Vagrant assumes that this means the command failed!
/sbin/ifdown eth1 2> /dev/null
Stdout from the command:
Stderr from the command:
sudo: unable to resolve host ubuntu-xenial
mesg: ttyname failed: Inappropriate ioctl for device
The "unable to resolve hostname" and "ttyname" problems can be fixed through simple modification of a couple of files. However, because the default image doesn't include those, vagrant is unable to bring up a box properly.
ProblemType: Bug
DistroRelease: Ubuntu 16.04
Package: vagrant 1.8.1+dfsg-1
ProcVersionSign
Uname: Linux 4.4.0-34-generic x86_64
NonfreeKernelMo
ApportVersion: 2.20.1-0ubuntu2.1
Architecture: amd64
CurrentDesktop: Unity
Date: Mon Aug 22 11:16:14 2016
InstallationDate: Installed on 2016-05-02 (111 days ago)
InstallationMedia: Ubuntu 16.04 LTS "Xenial Xerus" - Release amd64 (20160420.1)
PackageArchitec
SourcePackage: vagrant
UpgradeStatus: No upgrade log present (probably fresh install)
Changed in vagrant (Ubuntu): | |
importance: | Undecided → Medium |
I can't reproduce this on either of my Ubuntu machines, both of which are running the same version of Vagrant and the Linux kernel.
What happens if you run 'vagrant box update' in the same directory as the Vagrantfile? It could be that you are running an older box which doesn't have this issue fixed (the official Vagrant boxes are updated every few days).
For reference, the commands I ran were:
cd /tmp
vagrant init ubuntu/xenial64
vagrant up
I didn't have the ubuntu/xenial64 box installed, so it fetched the latest version automatically the first time I ran vagrant up.