<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title></title>
</head>
<body>
<div name="messageBodySection">
<div dir="auto"><span style="font-family:Helvetica Neue">So far we've had instances with dnsdist 1.8.0 having a thread in a tight loop. OS versions seem to vary widely, so I don't believe it's a glibc bug.</span><br />
<br />
<span style="font-family:Helvetica Neue">Config on both is the same plain config:</span><br />
<br />
setLocal("127.0.0.1:53", {reusePort=true})<br />
addLocal("127.0.0.1:53", {reusePort=true})<br />
addLocal("127.0.0.1:53", {reusePort=true})<br />
addLocal("127.0.0.1:53", {reusePort=true})<br />
addACL('10.0.0.0/8')<br />
newServer({address="10.112.104.116", checkType="A", checkClass=DNSClass.IN, checkName="hc.xxx.local", mustResolve=true, checkInterval=30})<br />
newServer({address="10.112.106.177", checkType="A", checkClass=DNSClass.IN, checkName="hc.xxx.local", mustResolve=true, checkInterval=30})<br />
newServer({address="10.9.41.68", checkType="A", checkClass=DNSClass.IN, checkName="hc.xxx.local", mustResolve=true, checkInterval=30})<br />
setServerPolicy(firstAvailable)<br />
<br />
-- Tuning<br />
setRingBuffersSize(1000000, 100)<br />
setMaxTCPClientThreads(20)<br />
<br />
-- Caching<br />
-- We should make these tunables configurable<br />
pc = newPacketCache(100000, {maxTTL=86400, minTTL=0, temporaryFailureTTL=60, staleTTL=60, dontAge=false})<br />
getPool(""):setCache(pc)<br />
<br />
-- Don't try and hit the internet<br />
setSecurityPollSuffix("")<br />
<br />
<span style="color:#d1d2d3;background-color:#222529;font-family:Slack-Lato, Slack-Fractions, appleLogo, sans-serif;font-size: 15px">[pid  2990] recvfrom(-1, 0x7f3d9c0008c0, 4368, 0, NULL, NULL) = -1 EBADF (Bad file descriptor)</span><span style="font-size: 15px"><br /></span><span style="color:#d1d2d3;background-color:#222529;font-family:Slack-Lato, Slack-Fractions, appleLogo, sans-serif;font-size: 15px">[pid  2990] recvfrom(-1, 0x7f3d9c0008c0, 4368, 0, NULL, NULL) = -1 EBADF (Bad file descriptor)</span><span style="font-size: 15px"><br /></span><span style="color:#d1d2d3;background-color:#222529;font-family:Slack-Lato, Slack-Fractions, appleLogo, sans-serif;font-size: 15px">[pid  2990] recvfrom(-1, 0x7f3d9c0008c0, 4368, 0, NULL, NULL) = -1 EBADF (Bad file descriptor)</span><span style="font-size: 15px"><br /></span><span style="color:#d1d2d3;background-color:#222529;font-family:Slack-Lato, Slack-Fractions, appleLogo, sans-serif;font-size: 15px">[pid  2990] recvfrom(-1, 0x7f3d9c0008c0, 4368, 0, NULL, NULL) = -1 EBADF (Bad file descriptor)</span><span style="font-size: 15px"><br /></span><span style="font-size: 15px"><br /></span>In each case, a strace shows a bad recvfrom() call in a tight loop:<br />
<br />
Obviously -1 is a bad fd! Restarting dnsdist seems to resolve it. The only idea I can come up with is that when dnsdist first starts, it's unable to contact the upstream DNS servers and that somehow causes the issue. When we restart it, it IS able to contact them, and so works fine.<br />
<br />
Any ideas?<br />
<br />
Thanks!<br />
-Dustin<br /></div>
</div>
</body>
</html>