Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-9468

Client hangs in my_addr_resolve

    XMLWordPrintable

    Details

      Description

      Several buildbot tests in fulltest2 builder fail due to timeout when run with embedded server:
      http://buildbot.askmonty.org/buildbot/builders/kvm-fulltest2/builds/4780/steps/test_5/logs/stdio

      I can reproduce it locally, e.g. with main.func_rollback although I have to clean caches after every run (and even then, it does not happen any time, but frequently enough). When it does happen, it keeps eating CPU with this stack trace:

      Thread 1 (Thread 0x7f9cb1ddd740 (LWP 32048)):
      #0  0x00007f9cafd922b3 in select () from /lib64/libc.so.6
      #1  0x00005617779b910f in my_addr_resolve (ptr=0x561777d5242f <handle_select(THD*, LEX*, select_result*, unsigned long)+399>, loc=0x7ffcc68a1310) at /src/10.1/mysys/my_addr_resolve.c:172
      #2  0x00005617779b6ef2 in print_stack (frame=0x7f9c8407ae18) at /src/10.1/mysys/safemalloc.c:236
      #3  0x00005617779b7503 in sf_report_leaked_memory (id=0) at /src/10.1/mysys/safemalloc.c:380
      #4  0x00005617779b7572 in sf_terminate () at /src/10.1/mysys/safemalloc.c:393
      #5  0x00007f9cafcebbf9 in __run_exit_handlers () from /lib64/libc.so.6
      #6  0x00007f9cafcebc45 in exit () from /lib64/libc.so.6
      #7  0x0000561777986edf in cleanup_and_exit (exit_code=0) at /src/10.1/client/mysqltest.cc:1527
      #8  0x0000561777998644 in main (argc=29, argv=0x7ffcc68a1788) at /src/10.1/client/mysqltest.cc:9563

      The problem appeared in 10.1 tree after these two revisions:

      commit b2bd10d4d614924ff22746ce3a49b4e5f755ddc9
      Author: Vicențiu Ciorbaru <vicentiu@mariadb.org>
      Date:   Sun Jan 17 22:23:21 2016 +0200
       
          [MDEV-9427] Server does not build on OpenSUSE 42.1
          
          Changed code to comply to C90 standard.
       
      commit 6d3ffd2e3a76873acb4f232f52ccca6a75bf737d
      Author: Vicențiu Ciorbaru <cvicentiu@gmail.com>
      Date:   Fri Dec 11 09:16:42 2015 +0200
       
          Fixed a crash during stacktrace printing if addr2line failed to start.
          
          In order to get all the input from addr2line we must read in a loop,
          until the response is complete. Also, in case that the response is
          malformed, we must not end up reading invalid memory.

        Attachments

          Activity

            People

            Assignee:
            cvicentiu Vicențiu Ciorbaru
            Reporter:
            elenst Elena Stepanova
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved:

                Git Integration