How To Make d3backup a custom service on CentOS 7

If you are running CentOS7 or RHEL 7 with d3backup. You may want this program to be a service running in the background.

First create the systemd service for d3backup

vi /etc/systemd/system/d3backup.service


[Unit]
Description=d3backup Service
After=network.target

[Service]
Type=simple
User=root
ExecStart=/usr/bin/d3backup -b
Restart=always

[Install]
WantedBy=multi-user.target

Then make systemd to reload and start it

systemctl daemon-reload
systemctl enable d3backup.service
systemctl start d3backup.service