txj 2020-06-12
$ vi /lib/systemd/system/redis6379.service
[Unit]
Description=redis
After=network.target
[Service]
Type=forking
PIDFile=/var/run/redis/redis_6379.pid
ExecStart=/usr/local/redis/bin/redis-server /usr/local/redis/etc/redis_6379.conf
ExecReload=/bin/kill -s HUP $MAINPID
ExecStop=/bin/kill -s QUIT $MAINPID
PrivateTmp=true
[Install]
WantedBy=multi-user.target
:wq
$ systemctl enable redis6379.service
$ systemctl start redis6379
$ systemctl status redis6379