Hi!
I've created a mathics.service file, to run mathicsserver script as a system service. Here is the code (and explanations):
## Mathics start/stop/restart service script
## Author: Isaias José Amaral Soares
## Note: You can redistribute and alter this as your needs
## Steps to be followed to use this script:
## 1. Copy mathics.service to /usr/lib/systemd/system/
## 2. Reload the daemons of systemctl: systemctl daemon-reload
## 3. Start the script: systemctl start mathics.service
## or: systemctl restart mathics.service
[Unit]
Description=Mathics Server Service
[Service]
Type=simple
User=root
Group=root
ExecStart=nohup /usr/local/bin/mathicsserver&
Restart=
WorkingDirectory=/tmp
Nice=19
LimitNOFILE=16384
[Install]
WantedBy=multi-user.target