Skip to content

Run SCION and SCION-viz automatically on boot

Prerequisites

It is necessary to have SCION successfully installed on your system before proceeding with this tutorial. Necessary steps for installing SCION can be found on following pages:

Tip

If you are using SCION VM, SCION is already running on system boot so following steps are not required to be done manually.

Installation

We will create systemd service that will be configured to run SCION infrastructure on system boot.

Step One - Get template service files

To avoid creating service files from scratch, we can download templates from SCION Lab repository and customize them for current system. Downloaded template files have value _USER_ instead of real system user so we will have to adjust it. Complete process can be finished with following commands:

mkdir -p /tmp/scion_services
cd /tmp/scion_services

wget https://raw.githubusercontent.com/netsec-ethz/scion-coord/master/vagrant/scion.service
wget https://raw.githubusercontent.com/netsec-ethz/scion-coord/master/vagrant/scion-viz.service

sed -i "s/_USER_/$USER/g" *.service

Step Two - Register services with systemd

We need to copy newly created services to systemd directory and enable them. This can be done with following commands:

sudo cp *.service /etc/systemd/system/

sudo systemctl enable scion.service
sudo systemctl enable scion-viz.service

Conclusion

These steps should be sufficient to make SCION run on your system boot. Reboot the system and verify that everything works as expected.