see https://www.digitalocean.com/community/tutorials/how-to-use-systemctl-to-manage-systemd-services-and-units
sudo vi /etc/systemd/system/ms.service
sudo chmod 744 /etc/systemd/system/ms.service
sudo systemctl enable ms.service
(this should give you "Created symlink from /etc/systemd/system/multi-user.target.wants/ms.service to /etc/systemd/system/ms.service." )
How to troubleshoot? https://www.certdepot.net/systemd-service-debugging-tips/
systemctl start ms
systemctl status ms
journalctl -u ms
sudo vi /etc/systemd/system/ms.service
[Unit]
Description=myservice
[Service]
User=myuser
ExecStart=/bin/bash /path/to/script/ms.sh
[Install]
WantedBy=multi-user.target
sudo chmod 744 /etc/systemd/system/ms.service
sudo systemctl enable ms.service
(this should give you "Created symlink from /etc/systemd/system/multi-user.target.wants/ms.service to /etc/systemd/system/ms.service." )
How to troubleshoot? https://www.certdepot.net/systemd-service-debugging-tips/
systemctl start ms
systemctl status ms
journalctl -u ms