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

Segmentation Fault at startup on NUMA-Architecture

    • Type: Icon: Bug Bug
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 1.8.2, 1.9.0
    • Component/s: None
    • Labels:
      None
    • Environment:
      Red Hat Enterprise Linux Server release 5.6 (Tikanga), Intel Xeon E5540
    • Linux

      The release candidate of 1.8.2 and 1.9.0 do not start on my machine. I get the following message:
      Sun Jun 5 17:29:12 [initandlisten] MongoDB starting : pid=18471 port=27017 dbpath=db 64-bit host=lnxp-3740

        • NOTE: This is a development version (1.9.0) of MongoDB.
        • Not recommended for production.
          Sun Jun 5 17:29:12 Invalid access at address: 0x1

      Sun Jun 5 17:29:12 Got signal: 11 (Segmentation fault).

      Sun Jun 5 17:29:12 Backtrace:
      0x92d809 0x92de50 0x34c980eb10 0x34c8c79b60 0x57e785 0x931855 0x9326da 0x93a691 0x34c8c1d994 0x4e6f89
      /server/mongodb-1.9/bin/mongod(_ZN5mongo10abruptQuitEi+0x399) [0x92d809]
      /server/mongodb-1.9/bin/mongod(_ZN5mongo24abruptQuitWithAddrSignalEiP7siginfoPv+0x220) [0x92de50]
      /lib64/libpthread.so.0 [0x34c980eb10]
      /lib64/libc.so.6(strlen+0x10) [0x34c8c79b60]
      /server/mongodb-1.9/bin/mongod(_ZN5mongo13show_warningsEv+0x3e5) [0x57e785]
      /server/mongodb-1.9/bin/mongod(_ZN5mongo14_initAndListenEi+0x115) [0x931855]
      /server/mongodb-1.9/bin/mongod(_ZN5mongo13initAndListenEi+0x2a) [0x9326da]
      /server/mongodb-1.9/bin/mongod(main+0x7731) [0x93a691]
      /lib64/libc.so.6(__libc_start_main+0xf4) [0x34c8c1d994]
      /server/mongodb-1.9/bin/mongod(__gxx_personality_v0+0x399) [0x4e6f89]

      Sun Jun 5 17:29:12 ERROR: Client::shutdown not called: initandlisten

      if I start the server with strace, I see the following:
      [...]
      stat("/proc/vz", 0x7fff69cb5e10) = -1 ENOENT (No such file or directory)
      stat("/sys/devices/system/node/node1",

      {st_mode=S_IFDIR|0755, st_size=0, ...}

      ) = 0
      open("/proc/self/numa_maps", O_RDONLY|O_CREAT, 0600) = 4
      pread(4, 0x7fff69cb5f90, 100, 0) = -1 ESPIPE (Illegal seek)
      — SIGSEGV (Segmentation fault) @ 0 (0) —
      write(1, "Sun Jun 5 17:29:53 ", 20Sun Jun 5 17:29:53 ) = 20
      write(1, "Invalid access at address: 0x1\n", 31Invalid access at address: 0x1
      [...]

      So it seems reading /proc/self/numa_maps with pread fails for some reason. I can cat /proc/self/numa_maps with no problem, but in this case, strace shows that read() is used, not pread():

      fstat(1,

      {st_mode=S_IFCHR|0620, st_rdev=makedev(136, 2), ...}

      ) = 0
      open("/proc/self/numa_maps", O_RDONLY) = 3
      fstat(3,

      {st_mode=S_IFREG|0444, st_size=0, ...}

      ) = 0
      read(3, "00400000 default file=/bin/cat m"..., 4096) = 872
      write(1, "00400000 default file=/bin/cat m"..., 87200400000 default file=/bin/cat mapped=3 N1=3

      Hope this helps.

      --Swen

            Assignee:
            mathias@mongodb.com Mathias Stearn
            Reporter:
            grmblfrz Swen Thümmler
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: