When the init.d script is invoked without an existing /var/run/mongodb/, mongod fails to start. The variable PIDDIR is missing from the file. A fix is attached as a diff for /etc/init.d/mongod.
This is specially problematic in distros where /var/run is mounted as a tempfs where it's empty on every boot.
- duplicates
-
SERVER-7285 Support systemd in future compatible distributions
- Closed
- is duplicated by
-
SERVER-22024 Mongod crash after restart (missing systemd-tempfile configuration)
- Closed