- Joined
- Dec 18, 2018
- Messages
- 87
- Reaction score
- 107
- Points
- 33
I wanted to leverage a bit of functionality within systemd, the ability to automatically restart a crashed process
Simply create a new systemd script;
…and add the following content…
you might need to alter the paths
Once you’ve created the service, you need to reload the systemd daemons by issuing;
…then you can simply start the Multics by issuing;
One final thing is to ensure Multics starts on boot, to do that, issue the following command;
You can check Multics is running by visiting the web interface or by running;
If multics crashes it will start again automatically.
And that’s it!
Happy viewing!
Simply create a new systemd script;
Code:
sudo nano /etc/systemd/system/multics.service
…and add the following content…
Code:
[Unit]
Description=Multics daemon
After=network.target
Requires=network.target
[Service]
Type=forking
ExecStart=/var/bin/multics -b -C /var/etc/multics.cfg
ExecStop=/bin/kill -9 $MAINPID
TimeoutStopSec=1
Restart=always
RestartSec=5
StartLimitInterval=0
[Install]
WantedBy=multi-user.target
you might need to alter the paths
Once you’ve created the service, you need to reload the systemd daemons by issuing;
Code:
sudo systemctl daemon-reload
…then you can simply start the Multics by issuing;
Code:
sudo systemctl start multics
One final thing is to ensure Multics starts on boot, to do that, issue the following command;
Code:
sudo systemctl enable multics.service
Code:
sudo systemctl status multics
If multics crashes it will start again automatically.
And that’s it!
Happy viewing!