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

Valgrind warnings on shutdown on a build with openSSL

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Minor
    • Resolution: Fixed
    • 10.0.4, 5.5.32, 5.1.67, 5.3.12
    • 10.0.5, 5.5.34, 5.1.73, 5.3.13
    • None
    • Ubuntu 12.04 x86_64

    Description

      I built the server with openSSL (WITH_SSL=system instead of bundled) and started getting valgrind warnings on server shutdown:

      perl ./mtr alias --valgrind-mysqld

      ==29019== 24 bytes in 1 blocks are still reachable in loss record 1 of 600
      ==29019==    at 0x4C2B6CD: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
      ==29019==    by 0x5DCE7F3: CRYPTO_malloc (in /lib/x86_64-linux-gnu/libcrypto.so.1.0.0)
      ==29019==    by 0x5E4928A: lh_insert (in /lib/x86_64-linux-gnu/libcrypto.so.1.0.0)
      ==29019==    by 0x5DD149B: OBJ_NAME_add (in /lib/x86_64-linux-gnu/libcrypto.so.1.0.0)
      ==29019==    by 0x5E53714: EVP_add_cipher (in /lib/x86_64-linux-gnu/libcrypto.so.1.0.0)
      ==29019==    by 0x5B54690: SSL_library_init (in /lib/x86_64-linux-gnu/libssl.so.1.0.0)
      ==29019==    by 0xEBE487: check_ssl_init (viosslfactories.c:155)
      ==29019==    by 0xEBE5AA: new_VioSSLFd (viosslfactories.c:189)
      ==29019==    by 0xEBEB66: new_VioSSLAcceptorFd (viosslfactories.c:336)
      ==29019==    by 0x5841CF: init_ssl() (mysqld.cc:4412)
      ==29019==    by 0x585888: mysqld_main(int, char**) (mysqld.cc:5224)
      ==29019==    by 0x57C4C3: main (main.cc:25)
      ==29019== 
      ==29019== 24 bytes in 1 blocks are still reachable in loss record 2 of 600
      ==29019==    at 0x4C2B6CD: malloc (in /usr/lib/valgrind/vgpreload_memcheck-amd64-linux.so)
      ==29019==    by 0x5DCE7F3: CRYPTO_malloc (in /lib/x86_64-linux-gnu/libcrypto.so.1.0.0)
      ==29019==    by 0x5E4928A: lh_insert (in /lib/x86_64-linux-gnu/libcrypto.so.1.0.0)
      ==29019==    by 0x5DD149B: OBJ_NAME_add (in /lib/x86_64-linux-gnu/libcrypto.so.1.0.0)
      ==29019==    by 0x5B54690: SSL_library_init (in /lib/x86_64-linux-gnu/libssl.so.1.0.0)
      ==29019==    by 0xEBE487: check_ssl_init (viosslfactories.c:155)
      ==29019==    by 0xEBE5AA: new_VioSSLFd (viosslfactories.c:189)
      ==29019==    by 0xEBEB66: new_VioSSLAcceptorFd (viosslfactories.c:336)
      ==29019==    by 0x5841CF: init_ssl() (mysqld.cc:4412)
      ==29019==    by 0x585888: mysqld_main(int, char**) (mysqld.cc:5224)
      ==29019==    by 0x57C4C3: main (main.cc:25)
      ==29019== 
      ...

      I'm not sure whether they're essential or not, and if they are, whether it's our fault, maybe it's a bad valgrind version or a 3rd-party library bug.

      ldd ../sql/mysqld
      	linux-vdso.so.1 =>  (0x00007fff7578d000)
      	libodbc.so.1 => /usr/lib/x86_64-linux-gnu/libodbc.so.1 (0x00007f1731474000)
      	libaio.so.1 => /lib/x86_64-linux-gnu/libaio.so.1 (0x00007f1731272000)
      	libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007f173105a000)
      	librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007f1730e52000)
      	libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f1730c35000)
      	libcrypt.so.1 => /lib/x86_64-linux-gnu/libcrypt.so.1 (0x00007f17309fb000)
      	libssl.so.1.0.0 => /lib/x86_64-linux-gnu/libssl.so.1.0.0 (0x00007f173079d000)
      	libcrypto.so.1.0.0 => /lib/x86_64-linux-gnu/libcrypto.so.1.0.0 (0x00007f17303d5000)
      	libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f17301d0000)
      	libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007f172fed0000)
      	libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007f172fbd4000)
      	libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007f172f9bd000)
      	libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f172f5fe000)
      	libltdl.so.7 => /usr/lib/x86_64-linux-gnu/libltdl.so.7 (0x00007f172f3f4000)
      	/lib64/ld-linux-x86-64.so.2 (0x00007f17316ed000)

      valgrind --version
      valgrind-3.7.0

      Attachments

        Activity

          People

            bar Alexander Barkov
            elenst Elena Stepanova
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Git Integration

                Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.