Files
trove/integration/scripts/files/elements/ubuntu-xenial-mongodb/install.d/42-mongos-systemd
Riccardo Pittau 72c4ba04c8 Adding mongodb support to xenial
Changes to add support for mongodb for xenial to trove/integration.
The schema is the same proposed by Doug Shelley in the initial
work, splitting trusty and xenial.

- bumped version to 3.2.11
- conversion of upstart files in systemd unit files for mongod and
mongos
- added oneshot systemd unit file for Transparent Huge Pages
- added script to check if numactl is used by the system and oneshot
systemd unit file that will generate an environment file for mongod
systemd service

Change-Id: Ie6492b24f6803b35d929b499cfb7716e28bebfaa
Depends-On: I8e1de6ef31f969ccee88c334a0d5ed03aabd1b51
2017-09-28 09:45:33 +00:00

30 lines
560 B
Bash
Executable File

#!/bin/sh
set -e
set -o xtrace
cat > /lib/systemd/system/mongos.service << '_EOF_'
[Unit]
Description=High-performance, schema-free document-oriented database
After=network.target
Documentation=https://docs.mongodb.org/manual
[Service]
User=mongodb
Group=mongodb
RuntimeDirectory=mongodb
ExecStart=/usr/bin/mongos --quiet --config /etc/mongos.conf
LimitFSIZE=infinity
LimitCPU=infinity
LimitAS=infinity
LimitNOFILE=64000
LimitRSS=infinity
LimitNPROC=64000
[Install]
WantedBy=multi-user.target
_EOF_
systemctl daemon-reload
systemctl enable mongos.service