auto restart Redis server:
- Edit
/etc/systemd/system/multi-user.target.wants/redis.serviceand add this in the[Service]section, at the bottom:Restart=always
RestartSec=10s
- Run
sudo systemctl daemon-reload - Run
sudo systemctl restart redis
It will now restart after 10 seconds every time it crashes.