Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
ubuntu 15.10 & 16.04 guests wont work with private networks #7155
Comments
|
Hi @kiorky Thank you for opening an issue. I am unable to reproduce this issue with the following vanilla Vagrantfile. The Vagranfile you supplied is doing a lot of things including monkey-patching the ruby, defining helpers, and performing conditional execution that makes it very difficult to reason about the actual Vagrantfile that is being used and the parameters. Are you able to reproduce this with a vanilla Vagrantfile? Vagrant.configure(2) do |config|
config.vm.box = "bento/ubuntu-15.04"
config.vm.network "private_network", ip: "33.33.33.10"
endThere are so many variables in your Vagrantfile that it's not possible to narrow down where the problem might be:
Unfortunately there are just too many variables. Could you please reduce to a vanilla Vagrantfile and see if the issue reproduces? If it does, I am happy to try and fix it. If it doesn't, it means there is an issue in one of the items in the list above. Thanks! |
sethvargo
added
the
waiting-reply
label
Mar 18, 2016
valkum
commented
Mar 18, 2016
|
@sethvargo I think u misread the issue. Try a 16.04 box as guest.
The problem seems to be a upgrade of ifupdown package. From the changelog (http://changelogs.ubuntu.com/changelogs/pool/main/i/ifupdown/ifupdown_0.8.10ubuntu1/changelog)
As debian/cap/configure_networks.rb:L44 always tries to ifdown an interface, even if it is not defined for the system, because first start and the fact that all interfaces except eth0 are removed from /etc/network/interfaces by debian/cap/configure_networks.rb:L16-17 this now throws an error as the command returns non-zero. |
sethvargo
added
bug
guest/ubuntu
and removed
waiting-reply
labels
Mar 18, 2016
kiorky
commented
Mar 19, 2016
|
i said 15.10+ and you edited what i gave to use 15.04... come on. |
kiorky
commented
Mar 19, 2016
|
BTW; ubuntu16.04 is the next lts, which is coming soon ;) and cyring on users to adapt a bit their vagrantfile is a bit chilly where there is a bug on the first place. |
|
Hi @kiorky Thank you for your reply. My intent was not to be rude, so I apologize if it came off that way. Please understand that your Vagrantfile is very complex with many variables, so I was trying to help you narrow down the cause of the issue. @valkum was able to provide a much smaller reproduction case, which we can convert into a test case and fix the bug. |
kiorky
commented
Mar 20, 2016
|
yes, i reproduce it with this vagrantfile: Vagrant.configure(2) do |config|
config.vm.box = "xenial64"
config.vm.box_url = "http://cloud-images.ubuntu.com/xenial/current/xenial-server-cloudimg-amd64-vagrant.box"
config.vm.network "private_network", ip: "192.168.33.10"
end
|
added a commit
that referenced
this issue
Mar 20, 2016
sethvargo
added
the
has-pr
label
Mar 20, 2016
valkum
commented
Mar 20, 2016
|
#6871 is the same problem. Maybe you mark one as a duplicate. |
ecirtap
commented
Mar 20, 2016
|
Waiting for the fix, I used the following workaround to test my puppet code base against Xenial:
The argument of ifconfig (eth1) may depend on the Xenial box you use; the one I built today using packer replaces eth1 by enp0s8 as soon as it can:
(and ... I don't know why). |
kiorky
commented
Mar 21, 2016
|
i confirm this to be a dup of #6871 |
sevein
commented
Mar 24, 2016
|
0505771 worked for me, thanks! |
valkum
commented
Mar 24, 2016
|
@ecirtap Thats another new feature with ubunut. The chaning the devise names to pci port and slot to better find a defunct network port in real life. |
hbokh
commented
Mar 27, 2016
|
@valkum and @ecirtap Check Ask Ubuntu for the specific kernel boot parameters: http://askubuntu.com/a/732638/16590 |
sethvargo
closed this
in
#7159
Mar 31, 2016
added a commit
to kamigerami/vagrant
that referenced
this issue
Apr 1, 2016
dougneal
referenced this issue
Apr 18, 2016
Closed
Handle new 'predictable' network interface naming style #7241
dougneal
commented
Apr 18, 2016
|
Although this could be worked around by sending the |
DBeazy
commented
Apr 19, 2016
|
Is there a fix for this in the mean time, if that PR ever gets merged and put in a tag release, as this issue is causing halts in development cycles for myself and clients. |
ashantyk
commented
Apr 21, 2016
|
i can confirm i had the same issue and ended up making my own box (vagrant init gbarbieru/xenial) using this script bit.ly/vagrant-xenial . |
cnk
commented
Apr 22, 2016
|
I have been able to get a xenial box working using the code currently on vagrant master (the gem calls itself 1.8.2-dev) + the vbox image from boxcutter - boxcutter/ubuntu1604. The official ubuntu/xenial64 image is missing libnss-myhostname so all the I would love to find contact info for the maintainers of the official ubuntu vagrant images. It looks like a relatively small change might make the current code on master work. |
Ma27
referenced this issue
in Sententiaregum/Sententiaregum
Apr 30, 2016
Closed
use ubuntu/xenial64 basebox #264
taylorotwell
commented
May 1, 2016
|
Also having this problem. |
added a commit
to simbo/packer-ubuntu
that referenced
this issue
May 1, 2016
ryanwohara
commented
May 3, 2016
|
+1 I am also encountering this issue |
Repox
commented
May 4, 2016
|
+1 |
jhulick
commented
May 4, 2016
|
+1 |
hbokh
commented
May 4, 2016
|
All, |
ar-lex
commented
May 4, 2016
|
@cnk, the package libnss-myhostname isn't missing, it isn't recommended - see https://bugs.launchpad.net/ubuntu/+source/libnss-myhostname/+bug/1162478/comments/6 |
This was referenced May 5, 2016
topikito
commented
May 12, 2016
|
@hbokh I don't know if you know @geerlingguy, but I found in his image that theres a lock file at |
|
@topikito / @hbokh - Yikes! Sorry about that... I didn't run into it in my testing, but I did just notice someone else having an issue with apt being locked last night. Can you file an issue upstream, in the Packer config? https://github.com/geerlingguy/packer-ubuntu-1604 |
gretel
commented
May 12, 2016
•
|
@topikito @hbokh @geerlingguy it works as intended when unattended-upgrades are enabled. there is a possible solutions:
it's a good idea to have it enabled, at least for the sake of security. in my case i will re-enable it later on. |
|
@gretel - I like the idea of unattended upgrades being enabled—but for various reasons in provisioning, I don't like having it enabled out of the box (I didn't realize it was this way in 16.04)—I always use my Ansible security role to enable and configure it as part of my provisioning process. I'm torn on whether I'd like to disable by default... knowing that my boxes are used (hopefully) only for local development environments (inaccessible outside local private networks), it wouldn't be a major security concern. |
geerlingguy
referenced this issue
in geerlingguy/packer-ubuntu-1604
May 12, 2016
Closed
Apt lock file due to unattended-upgrades causes issues with initial provisioning #3
gretel
commented
May 12, 2016
•
|
@geerlingguy personally, i also prefer unattended-upgrades but not before they get enabled by the automation approach in place. as i usually use |
topikito
commented
May 13, 2016
|
@geerlingguy Sorry for the delay - timezone differences made me unavailable until now. I guess you've already opened an issue so no need for me to do ;) |
This was referenced May 13, 2016
designermonkey
commented
May 19, 2016
|
When is this going to be addressed as a bugfix release into vagrant? We have today just upgraded to I notice there is a |
designermonkey
commented
May 19, 2016
|
Additional: I have tried to install vagrant from git too to get around this, and I must say it ain't as simp,e as This really needs addressing as the fix has been available for ages now. Someone needs to take the lead here and resolve this. |
macchickpro
commented
May 19, 2016
|
Vagrant 1.8.1 I had to do a little bit more work (hope that helps)
I still get the error on provisioning:
and I'm not sure what's that is referring to but I can ping the machine with my private address, so for now I'm good. Thanks for the people that posted their working solution that really helped me getting to that one that worked in my environment! |
cinvoke
commented
May 30, 2016
•
|
i get the same.
it does however seem to be populating interfaces file just fine. |
tersmitten
referenced this issue
in Oefenweb/ansible-mydumper
May 30, 2016
Merged
Added support for Ubuntu 16.04 #5
|
FYI as a workaround you can try not setting the IP. I never use Vagrant to set the IP's... instead use a provisioner and that works just fine for my particular use case but since I work for Cumulus Networks I hit the networking with a lot of other things than just and IP and Vagrant doesn't support them all so for me there is no sense in fragmenting the provisioning between vagrant and another tool. Plus then I can reuse the automation in production with little/no modification. YMMV. |
This was referenced Jun 1, 2016
foxx
commented
Jun 9, 2016
|
Still having this problem; Vagrant 1.8.1
|
ryanmcgrath
commented
Jun 10, 2016
|
This would be really great if it got released and bumped. Affected as well. |
jayywolff
commented
Jun 11, 2016
|
looks like the update was finally released. Thanks guys! |
designermonkey
commented
Jun 11, 2016
•
|
Unfortunately, I now have the following error:
For reference (I can't see this linked here as I scan over the issue): https://bugs.launchpad.net/ubuntu/+source/livecd-rootfs/+bug/1561250 |
flowerett
commented
Jun 14, 2016
|
confirm, same error for me when I try to add |
foxx
commented
Jun 14, 2016
|
@flowerett Have you tried with the latest Vagrant? There was a new release a few days ago, but it's broken other things too |
flowerett
commented
Jun 14, 2016
|
$ vagrant --version |
flowerett
commented
Jun 14, 2016
$ vagrant --version
Vagrant 1.8.4got this error now: Failed to mount folders in Linux guest. This is usually because
the "vboxsf" file system is not available. Please verify that
the guest additions are properly installed in the guest and
can work properly. The command attempted was:
mount -t vboxsf -o uid=`id -u ubuntu`,gid=`getent group ubuntu | cut -d: -f3` code_searchapp /code/searchapp
mount -t vboxsf -o uid=`id -u ubuntu`,gid=`id -g ubuntu` code_searchapp /code/searchapp
The error output from the last command was:
sudo: unable to resolve host ubuntu-xenial
mesg: ttyname failed: Inappropriate ioctl for device
mount: unknown filesystem type 'vboxsf' |
foxx
commented
Jun 14, 2016
•
|
Possibly related to #7433. If you need a quick fix, then the only latest Ubuntu image that will work with Vagrant is Based on historic waiting times, this probably won't get fixed for quite a while. If you need it urgently then don't wait for a fix, roll your own. |
mylons
commented
Jun 14, 2016
•
|
upped to vagrant 1.8.4, and also affected by the same issue as @flowerett and, 26 days later completely agree with @designermonkey |
foxx
commented
Jun 14, 2016
•
virgofx
commented
Jun 14, 2016
|
Agreed. As a windows user, the past year of upgrading has caused problems every time. In the process of going from 1.8.3 to 1.8.4 now to fix the maximum nic issue. |
This was referenced Jun 16, 2016
sebastiaanluca
commented
Jun 18, 2016
|
Thought 1.8.4 would fix this as it fixes a lot of similar issues, but running into the same problem:
I can SSH into the virtual machine, but cannot provision it. |
jnardiello
commented
Jun 25, 2016
|
affected as well. |
|
Hi all, As I said to @foxx on Twitter, the boxes published by canonical under the In general, users have had more success with the boxes under the The bento boxes are open source and they are built using best practices and Packer. Unlike the "ubuntu" boxes, the bento boxes also support more providers such as VMware, Virtualbox, and Parallels. It's my least favorite thing to do, but I'm going to lock this issue. I'm doing this because I don't want this issue to become a black hole of "me too" and potentially mask real bugs. If you do continue to encounter errors, please open a new issue and follow the issue template that appears. This will assist us in providing a timely response and fix. |

kiorky commentedMar 18, 2016
Vagrant version
Vagrant 1.8.1
Host operating system
ubuntu 15.04 (any ubuntu)
Guest operating system
ubuntu 16.04 (15.10+ exhibit the problem)
Vagrantfile
Debug output
Vagrant fails first with
If we create /etc/network/interfaces.d/eth1.cfg like this
And powerdown/vagrant up the vm, the provisionning will work