My system has 6 interfaces, a loopback, a Xen Bridge, and then 4 ethernet interfaces eth0-3. In this system, my DNS server assigned by DHCP on xenbr0 is

Initially eth1 is disabled and DNS assigned (checked via /etc/resolv.conf) is When I enable eth1, internet on this system stops working, I checked with /etc/resolv.conf and now DNS is (why?). Anyway DNS resolution doesn't work now.

Question is How can I make internet work while keeping all interfaces active? Why DNS server changes, and how to stop that?

About Environment: This is a Ubuntu 12.04 VM running in Xen in VirtualBox. eth1 is connected to a VBox host-only network eth2 and eth3 are connected to VBox internal networks, there is no config on these two interfaces. xenbr0 is xen bridge and eth0 is added as its one port. In Vbox eth0 is sharing IP with host machine via NAT (currently getting IP of host machine is 192.168.1.x and router IP is which is default gateway for host and DNS too. This is hown DNS is propagated upto guest machine via xenbr0.

  • The information you supplied has nothing to do with DNS. The DNS entries are normally found in /etc/resolv.conf. BTW, you should tell us what is your network topology, what are the hops, your client is a virtual machine, etc.
    – Braiam
    May 14, 2014 at 1:37
  • I added /etc/resolv.conf result. Also explained why routing table is added, so to avoid another question. My first guess was that packets to might be taking another interface out, but as I can still ping it so it shouldn't be the case. May 14, 2014 at 1:40
  • @Braiam Sorry, there was some mistake at my end. /etc/resolv.conf does reflect a change, I updated that in my question now. May 14, 2014 at 2:05

1 Answer 1


Sounds like your system uses the same init script on all(?) interfaces, thus the most-recent DHCPconfigured connection will overwrite /etc/resolv.conf with whatever that DHCP defined

  • which script is that? anyway to avoid it (other than manually adding dns servers to /etc/network/interfaces)? May 15, 2014 at 10:13
  • 1
    So it turned out that I need to keep only one DHCP enabled interface at a time. Multiple DHCP enabled interfaces create confusions like this one. Aug 11, 2014 at 20:04

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .