#1570 All S2S connections fail DNS lookup

Reporter Dan Chokola
Owner MattJ
Created
Updated
Stars ★ (1)
Tags
  • Status-Fixed
  • Priority-Medium
  • Type-Defect
  1. Dan Chokola on

    Using Debian prosody-0.11 package. (Same issue on old prosody-trunk package.) S2S requests fail DNS lookup, but can ping the remote servers from the same machine: $ ping conference.prosody.im PING snikket2.prosody.im (46.43.15.35) 56(84) bytes of data. 64 bytes from snikket2.prosody.im (46.43.15.35): icmp_seq=1 ttl=53 time=82.4 ms Log output: Jul 02 14:05:47 c2s5561c7852ff0 debug Received[c2s]: <iq type='get' to='prosody@conference.prosody.im' id='b640e345-ebd3-4faa-b85d-ea9f0810687f'> Jul 02 14:05:47 mod_s2s debug opening a new outgoing connection for this stanza Jul 02 14:05:47 mod_s2s debug stanza [iq] queued until connection complete Jul 02 14:05:47 s2sout5561c6d052e0 debug First attempt to connect to conference.prosody.im, starting with SRV lookup... Jul 02 14:05:47 adns debug Records for _xmpp-server._tcp.conference.prosody.im. not in cache, sending query (thread: 0x5561c7bf5520)... Jul 02 14:05:47 adns debug Sending DNS query to 75.75.75.75 Jul 02 14:05:47 c2s5561c7852ff0 debug Handled 115 incoming stanzas Jul 02 14:05:47 c2s5561c7852ff0 debug Received[c2s]: <presence to='prosody@conference.prosody.im/<redacted>' id='25d182ef-4321-49fe-88ab-b6287c946905'> Jul 02 14:05:47 <redacted>:pep debug get_pep_service("<redacted>") Jul 02 14:05:47 sql debug SQL transaction begin [function(mod_storage_sql.lua:328)] Jul 02 14:05:47 sql debug SQL transaction success [function(mod_storage_sql.lua:328)] Jul 02 14:05:47 <redacted>:pep debug Get item 2d0f82b1d0a8edd9294cd8f8d471145bed5e3021 (published at 1593712608 by ) Jul 02 14:05:47 s2sout5561c6d052e0 debug trying to send over unauthed s2sout to conference.prosody.im Jul 02 14:05:47 s2sout5561c6d052e0 debug stanza [presence] queued Jul 02 14:05:47 socket debug server.lua: closed client handler and removed socket from list Jul 02 14:05:47 adns debug Reply for _xmpp-server._tcp.conference.prosody.im. (thread: 0x5561c7bf5520) Jul 02 14:05:47 s2sout5561c6d052e0 debug conference.prosody.im has no SRV records, falling back to A/AAAA Jul 02 14:05:47 adns debug Records for conference.prosody.im not in cache, sending query (thread: 0x5561c7521200)... Jul 02 14:05:47 adns debug Sending DNS query to 75.75.75.75 Jul 02 14:05:47 adns debug Records for conference.prosody.im not in cache, sending query (thread: 0x5561c7cb0e20)... Jul 02 14:05:47 adns debug Sending DNS query to 75.75.75.75 Jul 02 14:05:47 adns debug Reply for conference.prosody.im (thread: 0x5561c7521200) Jul 02 14:05:47 socket debug server.lua: closed client handler and removed socket from list Jul 02 14:05:47 adns debug Reply for conference.prosody.im (thread: 0x5561c7cb0e20) Jul 02 14:05:47 s2sout5561c6d052e0 debug DNS lookup failed to get a response for conference.prosody.im Jul 02 14:05:47 s2sout5561c6d052e0 info Failed in all attempts to connect to conference.prosody.im Jul 02 14:05:47 s2sout5561c6d052e0 debug No other records to try for conference.prosody.im - destroying Jul 02 14:05:47 s2sout5561c6d052e0 debug Destroying outgoing session <redacted>->conference.prosody.im: DNS resolution failed Jul 02 14:05:47 s2sout5561c6d052e0 info Sending error replies for 2 queued stanzas because of failed outgoing connection to conference.prosody.im Jul 02 14:05:47 stanzarouter debug Received[s2sin]: <iq type='error' to='<redacted>@<redacted>/dino.6921ef01' id='b640e345-ebd3-4faa-b85d-ea9f0810687f' from='prosody@conference.prosody.im'> Jul 02 14:05:47 c2s5561c7852ff0 debug Sending[c2s]: <iq type='error' to='<redacted>@<redacted>/dino.6921ef01' id='b640e345-ebd3-4faa-b85d-ea9f0810687f' from='prosody@conference.prosody.im'> Jul 02 14:05:47 c2s5561c7852ff0 debug Queuing <r> (in a moment) from outgoing_stanza_filter - #queue=1 Jul 02 14:05:47 stanzarouter debug Received[s2sin]: <presence type='error' to='<redacted>@<redacted>/dino.6921ef01' id='25d182ef-4321-49fe-88ab-b6287c946905' from='prosody@conference.prosody.im/<redacted>'> Jul 02 14:05:47 c2s5561c7852ff0 debug Sending[c2s]: <presence type='error' to='<redacted>@<redacted>/dino.6921ef01' id='25d182ef-4321-49fe-88ab-b6287c946905' from='prosody@conference.prosody.im/<redacted>'> Jul 02 14:05:47 c2s5561c7852ff0 debug Sending <r> (inside timer, before send) from outgoing_stanza_filter - #queue=2 Jul 02 14:05:47 c2s5561c7852ff0 debug Sending[c2s]: <r xmlns='urn:xmpp:sm:3'> Jul 02 14:05:47 c2s5561c7852ff0 debug Sending <r> (inside timer, after send) from outgoing_stanza_filter - #queue=2 Jul 02 14:05:48 c2s5561c7852ff0 debug Received[c2s]: <a h='216' xmlns='urn:xmpp:sm:3'> Jul 02 14:05:48 c2s5561c7852ff0 debug #queue = 0 Jul 02 14:06:46 c2s5561c7bfd400 debug Received[c2s]: <r xmlns='urn:xmpp:sm:3'>

  2. Dan Chokola on

    Please let me know if there is any additional information you need to help debug. I am hoping this is a configuration issue on my part.

  3. MattJ on

    Hi Dan, It looks like your DNS server is returning an error for some reason. A packet capture would be required for more details. Although it generally works, the DNS code in Prosody 0.11 is not wonderful, and I can imagine it having issues with certain DNS servers. In Prosody trunk we recently replaced it with an external library, libunbound. Sticking with Prosody 0.11, one thing you could try is running a local resolver. On Debian/Ubuntu this should be as simple as `sudo apt install unbound resolvconf` and then putting `nameserver 127.0.0.1` in /etc/resolv.conf. There are also other DNS services you could try, such as those run by Cloudflare (1.1.1.1), Google (8.8.8.8) and OpenDNS (208.67.222.222). If using another service fixes the issue, we'll assume it's a problem with the 0.11 code and/or the server you are using (looks like Comcast?) and we'll probably close this issue, as this code will be deprecated in future Prosody versions. However if the issue persists, do let us know!

    Changes
    • tags Status-NeedInfo
  4. Dan Chokola on

    Hi Matt, Thanks for the response. I'm hoping to give these options a try this week.

  5. Dan Chokola on

    Looks like the prosody-trunk package does not have this issue. Thank you for pointing me in the right direction.

  6. MattJ on

    Thanks for testing! As I mentioned, the new DNS code is expected to be much more robust, so we'll consider this issue fixed and look forward to the next major release :)

    Changes
    • owner MattJ
    • tags Status-Fixed

New comment

Not published. Used for spam prevention and optional update notifications.