[SOLVED] DNS settings in Proxmox changing on reboot

Jay L

Active Member
Jan 27, 2018
19
3
43
53
Hi,

I am running into a weird DNS issue and am hoping that people here can help. I have two Proxmox servers and they are each configure with two network interfaces as follows:

Net 1: x.x.0.15 fixed IP with DNS servers of .37 and .51
Net2: x.x.10.45 DHCP with DNS servers provided by DHCP of 10.46 and 10.48

Now, I want Proxmox to always have x.x.37 and x.x.51 as DNS servers. However, every time I reboot, Promox reverts to the DNS servers in the .10.x domain. This is problematic because .10.x is only used a couple of VMs and every other VM then fails because they get the .10.x DNS from Proxmox and they have no access to that network. This brings me to my questions:

  1. Is there a way to force Proxmox to always use .37 and .51? I manually update resolv.conf and the gui, but the setting seems to be overwritten on reboot.
  2. I guess I could change each VM to have a manually assigned DNS versus choosing the "same as server" option, but this is a bit annoying because I have to change many systems. Is there a simple batch way to do this?
  3. Would this situation be different if I switched the Net2 IP configuration to a fixed IP vs DHCP?
Thank you in advance
 
Solution 3, you should _never_ run a virtualisation host with DHCP, always use fixed IP as possible,

BTW. it is not necessary to give the virtualisation host an IP in a network, as long as there is not a special reachability requirement. Just the VM's need to have access to the lan.
 
Hi,

I used DHCP on the solution host because I thought that it had to have an IP address to work on the VMhosts. It is a throwaway address as nothing can reach it and so I would prefer to implement what you describe in the second paragraph. Below is my interfaces for the add-on interface. How would I change this to keep it active while removing the IP?

auto vmbr1
iface vmbr1 inet dhcp
bridge_ports enp2s0
bridge_stp off
bridge_fd 0

Thank you!
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!