Custom DNS not persistent on reboot


Network is setup as DHCP. My expectation is that if I set a custom DNS on the interface, it persists on reboot. E.g. DHCP for the IP address, but retain my custom DNS entries. Agree?


Possibly related to


Hm, that ticket is not only 8 years old, it seems to be using “DNS” interchangeably with “IP”, while our correspondent here clearly perceives a distinction.

But I sure have no idea, so I’m just going to suggest that it might help to know for sure, what “set a custom DNS” means. Put something in system/settings/network/hosts? Maybe the network router host has a local DNS service?


It’s not the reboot that replaces your custom DNS servers’ IP addresses. It happens any time DHCP is used to update the settings. All custom settings are currently overwritten.


By “Custom DNS”, I meant simply that I was overriding the DHCP assigned DNS from my router. E.g. my router assigns itself as DNS (, and I replaced those with and I did this using by right clicking the network icon and going to network preferences and then changing DNS settings. My expectation is that there would be to permanently override that through GUI. Maybe I’m missed something.


That’s indeed a feature currently missing in our DHCP client code: we don’t keep custom value saved in resolv.conf before (re)writing it after DHCP negociation. And we don’t keep it either if the DHCP server don’t push it again in its DHCP lease renew response.


That strikes me as more of a bug than just a missing feature, but perhaps it’s a fine point - I don’t know how important it would be to anyone.


You’re right, of course: