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

Add blockCheckSupported() features to Solaris/SmartOS build

    • Type: Icon: Improvement Improvement
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • 2.4.6, 2.5.1
    • Affects Version/s: None
    • Component/s: Build
    • Labels:
      None
    • Environment:
      Solaris/SmartOS build
    • Fully Compatible

      mongod will use the mincore() kernel function (or the similar Windows QueryWorkingSetEx() API) on platforms where we have provided support in a src/mongo/util/processinfo_<platform>.cpp file to enable better runtime decisions about when to throw a PageFaultException.

      We do not provide a processinfo_*.cpp file for Solaris/SmartOS, though Solaris has support for mincore() (according to http://www.opensolarisforum.org/man/man2/mincore.html) and has supported the mincore() function since Solaris 9 (according to http://fossies.org/linux/privat/libsigsegv-2.10.tar.gz:a/libsigsegv-2.10/src/stackvma-mincore.c).

      The missing support results in a warning message being displayed by mongod in the Solaris/SmartOS build, and in the jstests/block_check_supported.js test reporting failure (because Solaris is not being excluded from testing):

      ** NOTE: your operating system version does not support the method that MongoDB
      **       uses to detect impending page faults.
      **       This may result in slower performance for certain use cases
      
      Testing workingSet and indexCounters portions of serverStatus
      Testing db.serverStatus({workingSet:1}).workingSet for expected fields
      assert: Test FAILED: missing "note" field
      Error: Printing Stack Trace
          at printStackTrace (src/mongo/shell/utils.js:37:15)
          at doassert (src/mongo/shell/assert.js:6:5)
          at testExpectedFields (/data/buildslaves/SolarisSmartOS_64bit/mongo/jstests/block_check_supported.js:14:13)
          at doTest (/data/buildslaves/SolarisSmartOS_64bit/mongo/jstests/block_check_supported.js:67:9)
          at /data/buildslaves/SolarisSmartOS_64bit/mongo/jstests/block_check_supported.js:100:1
      Thu Apr 11 10:57:46.942 JavaScript execution failed: Test FAILED: missing "note" field at src/mongo/shell/assert.js:L7
      failed to load: /data/buildslaves/SolarisSmartOS_64bit/mongo/jstests/block_check_supported.js
      

      It would be good to add a src/mongo/util/processinfo_solaris.cpp file (similar to the Linux version) to enable this support. If required, the structure of this support allows this to be a runtime test.

            Assignee:
            tad Tad Marshall
            Reporter:
            tad Tad Marshall
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: