Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-6656

Memory Leak - SSL Enabled Build

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 2.4.0-rc0
    • Affects Version/s: 2.2.0-rc0
    • Component/s: Networking, Security
    • Labels:
      None
    • Environment:
      Tested on Ubuntu 11.04, SSL 0.9.8, mongod 2.2.0-rc0

    • ALL

      ./mongod --version
      db version v2.2.0-rc0, pdfile version 4.5
      Tue Jul 31 12:34:53 git version: 33dc8445316479bbaa062db00f179fa5c39bbddb
      
      ldd mongod
      	linux-vdso.so.1 =>  (0x00007fff9ad9d000)
      	libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007fd01c15a000)
      	libssl.so.0.9.8 => /lib/libssl.so.0.9.8 (0x00007fd01bf07000)
      	libcrypto.so.0.9.8 => /lib/libcrypto.so.0.9.8 (0x00007fd01bb77000)
      	librt.so.1 => /lib/x86_64-linux-gnu/librt.so.1 (0x00007fd01b96f000)
      	libstdc++.so.6 => /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007fd01b669000)
      	libm.so.6 => /lib/x86_64-linux-gnu/libm.so.6 (0x00007fd01b3e3000)
      	libgcc_s.so.1 => /lib/x86_64-linux-gnu/libgcc_s.so.1 (0x00007fd01b1cd000)
      	libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007fd01ae39000)
      	/lib64/ld-linux-x86-64.so.2 (0x00007fd01c37e000)
      	libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007fd01ac34000)
      	libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007fd01aa1c000)
      

      To reproduce, just fire up a mongod with SSL enabled and then to create/destroy connections:

      while (true) ; do echo "GET /" | openssl s_client -connect <host>:<port> ; done
      

      Non-Mapped virtual memory will gradually trend up. Attached screenshot from MMS shows the primary trending up while the secondaries stay flat.

        1. memleak-mongos.png
          memleak-mongos.png
          42 kB
        2. memleak-ssl-2.2.0-rc0.png
          memleak-ssl-2.2.0-rc0.png
          31 kB
        3. Screen Shot 2013-03-01 at 14.20.27.png
          Screen Shot 2013-03-01 at 14.20.27.png
          15 kB
        4. Screen Shot 2013-03-01 at 14.20.48.png
          Screen Shot 2013-03-01 at 14.20.48.png
          16 kB

            Assignee:
            milkie@mongodb.com Eric Milkie
            Reporter:
            adam@comerford.net Adam Comerford
            Votes:
            0 Vote for this issue
            Watchers:
            9 Start watching this issue

              Created:
              Updated:
              Resolved: