[Dnsmasq-discuss] Further thoughts/questions on failover

Michael michael at kmaclub.com
Thu Sep 2 17:38:05 UTC 2021


On 9/2/21 5:45 AM, Chris Green wrote:
> I'm still ruminating on this problem! :-)
>
> A number of people are using docker containers to manage this, one
> live dnsmasq in a container is the default DNS/DHCP for the system and
> another dnsmasq container is maintained to keep its files in sync with
> the running one.
>
> So far so good.
>
> What I don't follow is what happens if/when failure occurs as I don't
> see how the replacement dnsmasq instance can appear at the same
> address on the LAN.  So, unless all systems are rebooted they will
> lose DNS won't they?


Hi Chris,


In my other response, I just highlighted how I work around this.


My infrastructure server runs on some other IP.   Then, my dnsmasq runs 
on 192.168.1.2 as a separate IP from the hosting server.   That way it 
can always have the same ip regardless of what server it runs on.   That 
IP is reserved just for DNS/DHCP service.   Then no clients have to 
change when a failover happens.

> E.g. My default dnsmasq instance runs on a system at 192.168.1.2, if I
> had a 'clone' docker container on my desktop machine it would be at
> address 192.168.1.3.  So, if 192.168.1.2 dies and I start the dnsmasq
> container on my desktop machine it's at 192.168.1.3 but all machines
> on the network are configured (until reboot or DHCP reload time) to
> use 192.168.1.2.
>
> Am I missing something very obvious here (probably!).
>
> Just maintaining a Rasberry Pi image and updating the dnsmasq files
> on it would actually work better (for me anyway) as I could copy it
> out to an actual SD card regularly and all I'd need to do to recover
> after a failure would be to plug the SD card into a non-dead Pi and
> turn it on.
>

Yes, in my other thread, you can see that all of the key files for the 
system are located under a single directory ( with a directory structure 
under that ).   So you don't have to have a script that copies a bunch 
of locations, just the one making it straight forward.



Michael





More information about the Dnsmasq-discuss mailing list