InfluxDb Systemd Configuration

Yazdan Musa
Jan 26, 2021

--

Here is a guide on how to make a Systemd Service for InfluxDb. Copyable commands can be found at the bottom.

Create a new user (if not already done)

useradd -rs /bin/false influx

Make a new Systemd Unit File at /lib/systemd/system

nano /lib/systemd/system/influxdb.service

Paste the following code into the File

scroll down for the copyable code

Reload the Systemctl daemon and enable / check the status with the following commands:

Commands

useradd -rs /bin/false influxnano /lib/systemd/system/influxdb.service-----------------------------Unit File------------------------------[Unit]
Description=InfluxDB 2.0 service file.
Documentation=https://v2.docs.influxdata.com/v2.0/get-started/
After=network-online.target
[Service]
User=influx
Group=influx
ExecStart=/usr/local/bin/influxd
Restart=on-failure
[Install]
WantedBy=multi-user.target
--------------------------------------------------------------------systemctl daemon-reload
systemctl enable influxdb.service
systemctl start influxdb.service
systemctl status influxdb.service

--

--

Yazdan Musa
Yazdan Musa

No responses yet