I want dnsmasq to use all `server=`s rotate or randomly, to distribute
many clients requests instead of hitting one server continuously.
So I asked AI about it and it gave me this.
Is this true that “@0” is a thing? It does not mention in current man
pages?

What do you think?

=-----------------



To configure dnsmasq to use multiple DNS servers in a rotating or random
manner, you can use the `server` option with the `0` flag in your
dnsmasq.conf file. Here's how to set it up:

1. Open your dnsmasq.conf file.

2. Add multiple `server` lines with the `0` flag, like this:

```
server=8.8.8.8#53@0
server=8.8.4.4#53@0
server=1.1.1.1#53@0
server=1.0.0.1#53@0
```

The `#53` specifies the port (usually 53 for DNS), and the `@0` flag
tells dnsmasq to use these servers in a rotating fashion[1].

3. Save the file and restart dnsmasq.

With this configuration, dnsmasq will rotate through the specified DNS
servers, helping to distribute the load and provide fallback options if
one server is unresponsive[1].

Note that while this setup will rotate through the servers, it doesn't
guarantee perfect randomness. If you need truly random selection, you
might need to explore more advanced configurations or alternative DNS
server software.

Citations:
[1]
https://stackoverflow.com/questions/20631885/dnsmasq-config-being-bypassed
[2]
https://forum.manjaro.org/t/dns-rotating-while-on-vpn-without-using-dnsmasq/34778
[3]
https://www.reddit.com/r/pihole/comments/s3ugbu/help_this_keep_taking_down_my_internet_randomly/
[4] https://www.linksysinfo.org/index.php
[5] https://forum.dd-wrt.com/phpBB2/viewtopic.php?p=1158035
[6]
https://www.reddit.com/r/PFSENSE/comments/bpdyty/dnsmasq_resolution_randomly_slow/

_______________________________________________
Dnsmasq-discuss mailing list
Dnsmasq-discuss@lists.thekelleys.org.uk
https://lists.thekelleys.org.uk/cgi-bin/mailman/listinfo/dnsmasq-discuss

Reply via email to