DNSMASQ to cause failure for lookup after few days or hours

Post new topic   Reply to topic    DD-WRT Forum Forum Index -> Broadcom SoC based Hardware
Goto page 1, 2, 3, 4, 5, 6  Next
Author Message
mbze430
DD-WRT User


Joined: 14 May 2012
Posts: 239

PostPosted: Wed Feb 20, 2019 21:34    Post subject: DNSMASQ to cause failure for lookup after few days or hours Reply with quote
So I am having an issue where DNSMASQ is causing an issue where it would cause failure on look-up on certain sites ... sometimes in a few days sometimes within a few hours

I know it is DNSMASQ because if I do a stopservice dnsmasq && startservice dnsmasq it then works perfectly fine. Until a few hours or days later.

most of the time it fails to look up gmail.com. sometimes facebook.com. But it could be anything at any time. Anyone know what might cause this issue with dnsmasq just suddenly unable to look up certain sites?

_________________
ASUS RT-AC3200 - Deployed Client's site
ASUS RT-AC5200 - Merlin
ASUS RT-AX88U - Merlin
Sponsor
bripab007
DD-WRT User


Joined: 14 Jun 2006
Posts: 147

PostPosted: Thu Feb 21, 2019 1:18    Post subject: Reply with quote
I don't have the answer for you, but I know some folks have complained about DNSMasq dying in more recent build in the Atheros SOC sub-forum as well.

Maybe peruse that forum to see if you find any answers?

_________________
Netgear R7500v2, DD-WRT v3.0-r37845M kongat
Netgear R7000, DD-WRT v3.0-r37715M kongac
kernel-panic69
DD-WRT Guru


Joined: 08 May 2018
Posts: 7274
Location: Texas, USA

PostPosted: Thu Feb 21, 2019 2:22    Post subject: Reply with quote
Is this on wired or wi-fi? I still have random issues over wi-fi with dnsmasq last I checked, and I suspect it's related to the AP isolation always being active issue. I haven't checked the current build yet to see if it's still flaky.
Redback813
DD-WRT Novice


Joined: 10 Nov 2015
Posts: 38

PostPosted: Fri Feb 22, 2019 9:31    Post subject: Reply with quote
I have the same issue and I founded that by adding in Additional DNSMasq Options - "min-cache-ttl=800" helps mitigate the issue, I do find if the internet speed drop below a threshold the failure rate jumps.
kernel-panic69
DD-WRT Guru


Joined: 08 May 2018
Posts: 7274
Location: Texas, USA

PostPosted: Fri Feb 22, 2019 15:07    Post subject: Reply with quote
@Redback813, thanks for that, will test that as things still seem flaky for me, mainly over wi-fi in r38840M. Pretty sure there's some other additional configs I could probably try as well, but I kind of gave up a while back. If it works, it works, if not, ho-hum. I have other APs working just fine. I'm sure if the latest git were merged and a few other things happened, maybe the issues would disappear...
Redback813
DD-WRT Novice


Joined: 10 Nov 2015
Posts: 38

PostPosted: Fri Mar 01, 2019 13:45    Post subject: Reply with quote
min-cache-ttl=800 is set too high as this can cause Can not resolve issue, lower it to 600 more stable however still get Can not resolve issue from time to time, something else is causing the issue, too bad pi-hole not available.
Alozaros
DD-WRT Guru


Joined: 16 Nov 2015
Posts: 3890
Location: UK, London, just across the river..

PostPosted: Fri Mar 01, 2019 16:11    Post subject: Reply with quote
i guess it could be down to your DNS servers used...
i use 9.9.9.9 or 1.1.1.1 and never had any complains so far so good...
also to avoid any ISP DNS leak i use...

no-resolv
server=9.9.9.9
server=1.1.1.1

min-cache-ttl=800 this command is regarding for how long local DNS will keep those cached routes so in case
ov you sat it too high as a value as well cache size then this could be an issue too...
personally i used to set it up to 5000 min-cache-ttl=600 but after few builds i realised on BS builds cache size is fixed to 1500 lines and min-cache-ttl does nothing so i stopped use any settings regarding it..

finally there is a chance DNSmasq to be broken too but i haven't noticed anything yet...

_________________
Atheros
TP-Link WR740Nv1 -----DD-WRT 44538 BS AP,NAT
TP-Link WR740Nv4 -----DD-WRT 44251 BS WAP/Switch
TP-Link WR1043NDv2 ---DD-WRT 44627 BS AP,NAT,AP Isolation,Firewall,Local DNS,Forced DNS,DoT,VPN,VLAN
TP-Link WR1043NDv2 ---DD-WRT 44538 BS AP,NAT,AD Block,Firewall,Local DNS,Forced DNS,DoT,VPN,VLAN
TP-Link WR1043NDv2 ---Gargoyle OS 1.12.0 AP,NAT,QoS,Quotas
Qualcomm/IPQ8065
Netgear R7800 -----DD-WRT 44538 BS AP,NAT,AD-Block,AP&Net Isolation,VLAN's,Firewall,Local DNS,DoT
Broadcom
Netgear R7000 -----DD-WRT 44538 BS AP,Wi-Fi OFF,NAT,AD-Block,Firewall,Local DNS,Forced DNS,DoT,VPN
-----------------------------------------------------------------------------------------------
Stubby for DNS over TLS I DNSCrypt v2 by mac913
parco
DD-WRT User


Joined: 10 Sep 2017
Posts: 100

PostPosted: Fri Mar 01, 2019 16:55    Post subject: Reply with quote
eeem....... excuse me... but.... what would be the best config for EA2700? Shocked
kernel-panic69
DD-WRT Guru


Joined: 08 May 2018
Posts: 7274
Location: Texas, USA

PostPosted: Fri Mar 01, 2019 17:50    Post subject: Reply with quote
Redback813 wrote:
min-cache-ttl=800 is set too high as this can cause Can not resolve issue, lower it to 600 more stable however still get Can not resolve issue from time to time, something else is causing the issue, too bad pi-hole not available.


I wasn't sure if I needed to go higher or lower, had tested 3600 and was at around 13-15 hours between lookup failures. Will test 600 and see if that makes it better or worse. Again, thank you for that little bit of info!
Redback813
DD-WRT Novice


Joined: 10 Nov 2015
Posts: 38

PostPosted: Sat Mar 02, 2019 11:48    Post subject: Reply with quote
Trying the min-cache-ttl for the last 24hrs, pages load faster, however still get the Can not resolve issue which is less than previous, added an extra dns-forward-max to see if help and it seems to have helped but will watch.

min-cache-ttl=3600
dns-forward-max=250
kernel-panic69
DD-WRT Guru


Joined: 08 May 2018
Posts: 7274
Location: Texas, USA

PostPosted: Sat Mar 02, 2019 15:44    Post subject: Reply with quote
Redback813 wrote:
Trying the min-cache-ttl for the last 24hrs, pages load faster, however still get the Can not resolve issue which is less than previous, added an extra dns-forward-max to see if help and it seems to have helped but will watch.

min-cache-ttl=3600
dns-forward-max=250


This will probably make no sense, but I also filled in ALL THREE static DNS server IPs on the main setup page as well -- which has helped A LOT. The 600 setting seems to have been working fine yesterday when I changed it and rebooted. Will keep monitoring it and see if I need to change back and add the dns-forward-max config.
Redback813
DD-WRT Novice


Joined: 10 Nov 2015
Posts: 38

PostPosted: Sat Mar 02, 2019 18:50    Post subject: Reply with quote
Something I should have add early which will help speed up the DNS Cache and DNS request.

# use all DNS servers, use the first returned.
all-servers
# don't forward non-routable (local) addresses
bogus-priv
# don't forward incomplete hostnames (names without dots)
domain-needed
Alozaros
DD-WRT Guru


Joined: 16 Nov 2015
Posts: 3890
Location: UK, London, just across the river..

PostPosted: Sat Mar 02, 2019 20:21    Post subject: Reply with quote
in case you use
all-servers
than it will refer to those 3 on the basic settings tab + ISP dns

to see all-servers in use type
cat /tmp/resolv.dnsmasq

and you will see the ISP DNS at the end after those 3 you sat
in that case
no-resolv will not work if you use all-servers as well

in general there was a discussion that if you use the 3 DNS
set on the basic tab there ware DNS leaks to ISP
so when no-resolv is used instead and DNSmasq takes over with what is set there as a DNS, no ISP leaks...
server=1.1.1.1 or 9.9.9.9 and ect.

_________________
Atheros
TP-Link WR740Nv1 -----DD-WRT 44538 BS AP,NAT
TP-Link WR740Nv4 -----DD-WRT 44251 BS WAP/Switch
TP-Link WR1043NDv2 ---DD-WRT 44627 BS AP,NAT,AP Isolation,Firewall,Local DNS,Forced DNS,DoT,VPN,VLAN
TP-Link WR1043NDv2 ---DD-WRT 44538 BS AP,NAT,AD Block,Firewall,Local DNS,Forced DNS,DoT,VPN,VLAN
TP-Link WR1043NDv2 ---Gargoyle OS 1.12.0 AP,NAT,QoS,Quotas
Qualcomm/IPQ8065
Netgear R7800 -----DD-WRT 44538 BS AP,NAT,AD-Block,AP&Net Isolation,VLAN's,Firewall,Local DNS,DoT
Broadcom
Netgear R7000 -----DD-WRT 44538 BS AP,Wi-Fi OFF,NAT,AD-Block,Firewall,Local DNS,Forced DNS,DoT,VPN
-----------------------------------------------------------------------------------------------
Stubby for DNS over TLS I DNSCrypt v2 by mac913
dTX
DD-WRT User


Joined: 28 Dec 2018
Posts: 64

PostPosted: Sat Mar 02, 2019 21:07    Post subject: Reply with quote
@Alozaros you half right and half wrong on this one.

If you use:
all-servers
no-resolv
server=....
server=....
There will be no DNS leak as dnsmasq will not use anything from /tmp/resolv.dnsmasq but it will still rotate the server=... entries.

If you use:
all-servers
server=...
server=...
Then there will be DNS leak as dnsmasq will use whatever is in /tmp/resolv.dnsmasq along with the server=... entries.And will rotate them all the time(i tested this one)

The thing is that i was playing with it in the past week and to be honest using strict-order instead of all-servers every page opens much faster and also strict-order will prevent any DNS leaks no matter the combination you using due to the ISP servers are always placed at the bottom and possibility to start using them is tiny to zero.

_________________
Router: ASUS AC1900(RT-AC68U)
Dr_K
DD-WRT User


Joined: 23 Mar 2018
Posts: 442

PostPosted: Sat Mar 02, 2019 21:21    Post subject: Reply with quote
I use dnscrypt from startup script with 4 servers

Those 4 servers are also specified in dnsmasq options

I have no-resolve set in dnsmasq options so it does not use the ones from setup page or the isp's

I also have all-servers set so that it queries all my servers and uses the first reply

It works & dns tests show no leaks

_________________
Location 1
R6300V2- DD-WRT v3.0-r39345M kongac (04-03-19) Gateway
WNDR3400v1 DD-WRT v3.0-r35531_mega-nv64k (03/26/18 ) Access Point
WRT160Nv3 DD-WRT ?v3?.0-r35531 mini (03/26/18 ) Access Point
WRT54GSv5 DD-WRT v24-r33555_micro_generic (10/20/17) Repeater
Location 2
R6300V2- DD-WRT v3.0-r39345M kongac (04/03/19) Gateway
R6300V2- DD-WRT v3.0-r39345M kongac (04/03/19) Access Point
WNDR3700v2 DD-WRT v3.0-r35531 std (03/26/18 ) Access Point
E1200 v2 DD-WRT v3.0-r35531 mega-nv64k (03/26/18 ) Gateway(for trivial reasons)
RBWAPG-5HACT2HND-BE RouterOS-v6.46.4 (2/21/20) Outdoor Access Point
2 devices: RBSXTG-5HPACD RouterOS-v6.46.4 (2/21/20) PTP Bridge (0.8km/0.5mi)tx/rx 866.6Mbps-1GbpsLAN
Location 3
R7000 DD-WRT undecided Access Point
2 devices: RBWAPG-60AD RouterOS-v6.47.6 (10/21/20) PTP Bridge tx/rx 1Gbps-1GbpsLAN


Thank You BrainSlayer & <Kong> for ALL that you do & have done, also to "most" everyone here that shares their knowledge
Goto page 1, 2, 3, 4, 5, 6  Next Display posts from previous:    Page 1 of 6
Post new topic   Reply to topic    DD-WRT Forum Forum Index -> Broadcom SoC based Hardware All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum