Score:0

Clients couldn't query DNS server listening on router interface's secondary IP

gt flag
hgl

I have a router where its interface has two IPs

$ ip addr

br-lan: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP qlen 1000
    link/ether <MA> brd ff:ff:ff:ff:ff:ff
    inet 192.168.3.1/24 brd 192.168.3.255 scope global br-lan
       valid_lft forever preferred_lft forever
    inet 192.168.3.2/24 brd 192.168.3.255 scope global secondary br-lan
       valid_lft forever preferred_lft forever

Dnsmasq is listening on both IPs, which I can confirm by querying to either 192.168.3.1 and 192.168.3.2 on the router, and I would get answers back.

However, my client (192.168.3.100) connected to the router with a wire, can query only 192.168.3.1 and get answers back. When querying to 192.168.3.2, the router returns "port unreachable" ICMP error, yet it's able to ping 192.168.3.2 and get responses.

What might be the reason for ICMP error?

A.B avatar
cl flag
A.B
To be sure of how is running `dnsmasq`, can you provide the full options on its command line (eg with `ps -f -p $(pgrep dnsmasq)`) or from its configuration? The way it can use its interface options could matter. Also can you provide the result of `ss -anp sport == 53`?
A.B avatar
cl flag
A.B
Anyway, OP didn't give updates, but I'm quite sure in this case dnsmasq is bound to INADDR_ANY for UDP and doesn't use the IP_PKTINFO option to handle correct UDP replies for a multi-homed server (ok just multi-addresses).
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.