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

Add numactl to upstart scripts

    • Fully Compatible
    • Linux

      Changes in SERVER-3574 have added numactl to init.d scripts, but those changes do not appear to be reflected in upstart scripts for ubuntu. Checked both the package and github.

      Prior google groups thread on the subject have resulted in the following code to replace start_server() in /etc/init.d/mongodb

      start_server() {
      # check for numactl
      NUMACTL=$(which numactl)
      if [ -n "$NUMACTL" ]; then
          DAEMON_OPTS="--interleave=all ${DAEMON} ${DAEMON_OPTS}"
          DAEMON="$NUMACTL"
      fi
      
      # Start the process using the wrapper
                  /usr/bin/numactl --interleave=all -- \
                  start-stop-daemon --background --start --quiet --pidfile $PIDFILE \
                              --make-pidfile --chuid $DAEMONUSER \
                              --exec $DAEMON -- $DAEMON_OPTS
                  errcode=$?
              return $errcode
      }
      

            Assignee:
            ernie.hershey@mongodb.com Ernie Hershey (Inactive)
            Reporter:
            andre.defrere@mongodb.com Andre de Frere
            Votes:
            3 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: