|
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
|
}
|
|