<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hello,<div><br><div><div>Le 15 mai 08 à 09:33, Raimo Niskanen a écrit :</div><br class="Apple-interchange-newline"><blockquote type="cite">On Wed, May 14, 2008 at 05:48:28PM +0200, Mickaël Rémond wrote:<br><blockquote type="cite">Hello,<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">I suspect a bug in inet_res. When using this resolver it seems we get  <br></blockquote><blockquote type="cite">somewhat unpredictable results:<br></blockquote><blockquote type="cite">- gethostbyname can fails sometime (nxdomain error)<br></blockquote><blockquote type="cite">- connect sometimes fails with nxdomain error<br></blockquote><br>You mean gen_tcp:connect when using inet_res as resolver?</blockquote><div><br></div><div>Yes.</div><br><blockquote type="cite"><blockquote type="cite">If retry immediately the query / connect most of the time succeed.<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">I know that this module is not documented, but to my knowledge it is  <br></blockquote><blockquote type="cite">the only way to do DNS lookup on some specific type of records (mx or  <br></blockquote><blockquote type="cite">srv records).<br></blockquote><blockquote type="cite"><br></blockquote><blockquote type="cite">I can provide details if you need to.<br></blockquote><br>Yes please!<br></blockquote></div><div><br></div><div>What would you need ?</div><div>Should I put the resolver in debug mode and do many connects until I reproduce the problem ?</div><div>It happens on live system. Error seems to happens when a lot of different resolution are done at the same time.</div><div>The result is that tcp_connect seems sometime to fail with nxdomain, and the retry one second later works.</div><br><div apple-content-edited="true"> <span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: Helvetica; font-size: 13px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-border-horizontal-spacing: 0px; -webkit-border-vertical-spacing: 0px; -webkit-text-decorations-in-effect: none; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span class="Apple-style-span" style="font-size: 12px; "><div style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><div>-- </div><div>Mickaël Rémond</div><div> <a href="http://www.process-one.net/">http://www.process-one.net/</a></div><div><br class="webkit-block-placeholder"></div></div></span></div></div></div></span><br class="Apple-interchange-newline"> </div><br></div></body></html>