"private_network" set on wrong interface on centos7 vagrant 1.9.7

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

"private_network" set on wrong interface on centos7 vagrant 1.9.7

IL Dave
Hi, 

I'm using vagrant 1.9.7 with virtualbox 5.1.24 on Linux ( both Ubuntu 16.04 and RHEL 5 )

My problem is that when I adding new a "private_network" ip (hostonly) vagrant configure the wrong interface.

After creating vm vagrant add a new Adapter2 (hostonly) added after Adapter1 (NAT with portforward 2222 -> 22)
When the VM coming up I have two interfaces :

enp0s8 and enp0s17

Vagrant configure the private_network ip on enp0s17 that refers to the Adapter1 (NAT) (viewing MAC-ADDRESS)  instead enp0s8 that refers to Adapter2.

After that vagrant can't comunicate with the VM and hang at:
==> default: Configuring and enabling network interfaces...

I'm using my own centos7 template.
I think the problem is my centos invert the order of the interface but I don't know why this happen and how to avoid this behaviour.

Vagrant should knows what is the NAT interface because run the following command :
"/usr/bin/VBoxManage", "modifyvm", "415a19e2-6e61-4ae0-ba78-b8fd0a733b81", "--macaddress1", "08002720707C"

but when it creates configuration file use the interface order instead verify the mac on the interface

Do you know a way how to solve this issue ?

Thank you



--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/d1c451c9-46cb-4c63-a71c-3cd4730aa591%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: "private_network" set on wrong interface on centos7 vagrant 1.9.7

Alvaro Miranda Aguilera
Hello

Does happen with other boxes?

Please try

bento/centos7 (please check name)
alvaro/wouter7

If happens with those boxes too, please share your vagrantfile and the output from your VM on what you see and what you think should be

On Tue, Jul 25, 2017 at 6:28 PM, IL Dave <[hidden email]> wrote:
Hi, 

I'm using vagrant 1.9.7 with virtualbox 5.1.24 on Linux ( both Ubuntu 16.04 and RHEL 5 )

My problem is that when I adding new a "private_network" ip (hostonly) vagrant configure the wrong interface.

After creating vm vagrant add a new Adapter2 (hostonly) added after Adapter1 (NAT with portforward 2222 -> 22)
When the VM coming up I have two interfaces :

enp0s8 and enp0s17

Vagrant configure the private_network ip on enp0s17 that refers to the Adapter1 (NAT) (viewing MAC-ADDRESS)  instead enp0s8 that refers to Adapter2.

After that vagrant can't comunicate with the VM and hang at:
==> default: Configuring and enabling network interfaces...

I'm using my own centos7 template.
I think the problem is my centos invert the order of the interface but I don't know why this happen and how to avoid this behaviour.

Vagrant should knows what is the NAT interface because run the following command :
"/usr/bin/VBoxManage", "modifyvm", "415a19e2-6e61-4ae0-ba78-b8fd0a733b81", "--macaddress1", "08002720707C"

but when it creates configuration file use the interface order instead verify the mac on the interface

Do you know a way how to solve this issue ?

Thank you



--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/d1c451c9-46cb-4c63-a71c-3cd4730aa591%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Alvaro

--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/CAHqq0ezqXV4z3zSr61Woih875t72crTFP77BpkX5S7-hTE0bpA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: "private_network" set on wrong interface on centos7 vagrant 1.9.7

pixel fairy
In reply to this post by IL Dave
ive had a similar problem on libvirt when extra disks were added. disabling "predictable" network interfaces fixed the issue, going back to ethN 

when building the base box, add "net.ifnames=0" to GRUB_CMDLINE_LINUX in that distros grub.conf, for example, /etc/default/grub in ubuntu, and dont forget to update-grub.

On Tuesday, July 25, 2017 at 9:28:18 AM UTC-7, IL Dave wrote:
Hi, 

I'm using vagrant 1.9.7 with virtualbox 5.1.24 on Linux ( both Ubuntu 16.04 and RHEL 5 )

My problem is that when I adding new a "private_network" ip (hostonly) vagrant configure the wrong interface.

After creating vm vagrant add a new Adapter2 (hostonly) added after Adapter1 (NAT with portforward 2222 -> 22)
When the VM coming up I have two interfaces :

enp0s8 and enp0s17

Vagrant configure the private_network ip on enp0s17 that refers to the Adapter1 (NAT) (viewing MAC-ADDRESS)  instead enp0s8 that refers to Adapter2.

After that vagrant can't comunicate with the VM and hang at:
==> default: Configuring and enabling network interfaces...

I'm using my own centos7 template.
I think the problem is my centos invert the order of the interface but I don't know why this happen and how to avoid this behaviour.

Vagrant should knows what is the NAT interface because run the following command :
"/usr/bin/VBoxManage", "modifyvm", "415a19e2-6e61-4ae0-ba78-b8fd0a733b81", "--macaddress1", "08002720707C"

but when it creates configuration file use the interface order instead verify the mac on the interface

Do you know a way how to solve this issue ?

Thank you



--
This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list.
 
GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
---
You received this message because you are subscribed to the Google Groups "Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/e304b13a-d561-48db-aaf9-ba381a9989c6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.