-
Notifications
You must be signed in to change notification settings - Fork 4.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Private network comes up with wrong IP address #2968
Comments
can you paste the output of ifconfig -a for both cases in the guest? On Fri, Feb 14, 2014 at 7:02 AM, Alan Hodgkinson
|
From the first boot (e.g. after 'vagrant destroy' and 'vagrant up'):
After a 'vagrant halt' and 'vagrant up'
|
@ahodgkinson I couldn't reproduce with Vagrant 1.4.3. Could you please run |
Here you are: See: vagrant-20140214-0952-issue-2968.log Let me know if you need any more information. |
Thanks for the log. But no luck so far. The difference between first and second Is the box you're using publicly available? Or even better, the build templates? |
@tmatilai: Here is the copy of
Note the IP address 172.16.2.3, which looks good to me. Meanwhile, ifconfig reports:
..weird! |
Solved!The problem was that eth1 interface was actually being assigned two IP addresses, one IP address was the address specified in the Vagrantfile and the second was an incorrect IP address (it's not completely clear where it came from. We think that the DHCP server on the host machine could be causing this.) The presence of the two IP addresses could be confirmed as follows:
Note that the secondary address, 172.16.2.3, was the address defined in the Vagrantfile. There are two possible fixes:
Many, many thanks go to @tmatilai, who diagnosed the problem and suggest the fixes described here. |
try this: find /etc | grep -i eth sometimes are some weird profiles .. and may end with more than one On Sun, Feb 16, 2014 at 11:38 PM, Alan Hodgkinson
|
For what it's worth, I see this same problem when using the coreos-vagrant Vagrantfile. Starting a cluster of 3 machines (using the vmware_fusion provider) results in the machines getting IPs 172.17.8.130, 172.17.8.131, 172.17.8.132 rather than .100, .101, and .102 as they should. I'm using vagrant version 1.6.5. |
I have this happen to me in 1.7.2 still when using fedora-21 and vmware_fusion. Bouncing the interface still works around it. |
Same problem here with, using 1.7.2 with vmware_fusion and centos 7.1. |
I've also been struggling with this with 1.7.2 with virtualbox and centos 7.1 @pwm, it looks like, for centos 7.1 anyway, this apparently related to #5590; they reference a fix in #5709 that solves the issue for me on centos 7.1 |
I had the same issue, the problem seems to be related to the VirtualBox DHCP. VBoxManage dhcpserver remove --ifname vboxnet1 before running: vagrant up |
My VM comes up with the wrong IP address, the very first time it is started.
I have the following in my Vagrantfile:
This behavior appears to be repeatable.
Curiously, when the incorrect IP address 172.16.2.2 is assigned, it appears that if I ssh to 172.16.2.3, it actually connects to my VM! (and ssh to 172.16.2.2 also works).
Perhaps the IP 172.16.2.3 is somehow not release by the host system when the VM is destroyed?
This issue may be related to #1014
Software versions:
Host machine: Ubuntu 12.04.3 LTS
VMS: Ubuntu 12.04.3 LTS
Vagrant 1.3.5
VirtualBox 4.3.0r89960
The text was updated successfully, but these errors were encountered: