Check interruptNet during dnsseed lookups #10215

pull TheBlueMatt wants to merge 1 commits into bitcoin:master from TheBlueMatt:2017-04-dnsseed-break changing 1 files +6 −0
  1. TheBlueMatt commented at 8:34 PM on April 14, 2017: contributor

    Since #9229 we no longer can break out of a DNS lookup midway through, and have to wait for libc to time out. In most places we check for interrupt immediately before/after, so this is not a huge deal, except in the dnsseed lookup thread. In that thread, we loop over all dnsseeds and will have to wait for each to timeout. This appears to be the cause of the long wait in #10210.

    Until upstream glibc fixes the issue (https://sourceware.org/bugzilla/show_bug.cgi?id=20874) with getaddrinfo_a or we move to libevent's DNS lookup library, the best we can do is insert more agressive checks between lookups, which we do here.

  2. TheBlueMatt cross-referenced this on Apr 14, 2017 from issue Frozen (for 15 minutes) on shutdown [dnsseed thread] by dooglus
  3. TheBlueMatt commented at 8:36 PM on April 14, 2017: contributor

    Should likely get backported for 0.14.2 (if we do one).

  4. theuni commented at 8:44 PM on April 14, 2017: member

    Hmm, I could've sworn we already did this.

    drop the (), then utACK :)

  5. Check interruptNet during dnsseed lookups b2c9254205
  6. TheBlueMatt force-pushed on Apr 14, 2017
  7. theuni approved
  8. theuni commented at 9:36 PM on April 14, 2017: member

    utACK b2c9254205a59fa685d75470f73ad9397ecba708

  9. MarcoFalke added the label Needs backport on Apr 14, 2017
  10. MarcoFalke added this to the milestone 0.14.2 on Apr 14, 2017
  11. gmaxwell approved
  12. gmaxwell commented at 5:47 AM on April 15, 2017: contributor

    utACK.

  13. MarcoFalke added the label P2P on Apr 15, 2017
  14. laanwj commented at 7:55 AM on April 17, 2017: member

    utACK b2c9254

  15. sipa commented at 11:17 AM on April 17, 2017: member

    utACK b2c9254205a59fa685d75470f73ad9397ecba708

  16. sipa merged this on Apr 17, 2017
  17. sipa closed this on Apr 17, 2017

  18. sipa referenced this in commit a077a90da8 on Apr 17, 2017
  19. jonasschnelli cross-referenced this on May 31, 2017 from issue 0.14 Backports by jonasschnelli
  20. laanwj removed the label Needs backport on May 31, 2017
  21. codablock referenced this in commit ee3ff3552d on Jan 26, 2018
  22. andvgal referenced this in commit 600c5a3869 on Jan 6, 2019
  23. CryptoCentric referenced this in commit df7d94b9f8 on Feb 27, 2019
  24. Nikolay-Po cross-referenced this on Sep 3, 2019 from issue ThreadDNSAddressSeed hangs on sk_wait_data and doesn't stop on exit by Nikolay-Po
  25. furszy cross-referenced this on Jan 11, 2021 from issue [Backport] Check interruptNet during dnsseed lookups by furszy
  26. furszy referenced this in commit ecc46049f8 on Jan 13, 2021
  27. bitcoin locked this on Sep 8, 2021

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-05-20 06:55 UTC