Skip to content
Snippets Groups Projects
Commit 2e9a10ce authored by Alexander Söderqvist's avatar Alexander Söderqvist
Browse files

Updated systemd serivce and README

parent 89adc0ba
No related branches found
No related tags found
No related merge requests found
...@@ -7,8 +7,10 @@ The work around is to run the ioc as root user. A special systemd service has be ...@@ -7,8 +7,10 @@ The work around is to run the ioc as root user. A special systemd service has be
The systemd service specification should be placed in the root file system under /etc/systemd/system/ The systemd service specification should be placed in the root file system under /etc/systemd/system/
To enable the service from boot, specify path to your rootfs e.g.
systemctl --root=/export/nfsroots/ifc1210/rootfs-NEW/ enable emu-lebt
To reload systemd services and start on already running system: systemctl daemon-reload To reload systemd services and start on already running system: systemctl daemon-reload
To start the ioc: systemctl start emu-lebt To start the ioc: systemctl start emu-lebt
To automatically start the service only for the EMU host, place a script containing:
systemctl start emu-lebt
in the {path to startup file hiearchy}/boot/{emu hostname}/
It is important that you name the script so that it is executed the last. The scripts are executed in alphanumerical order.
[Unit] [Unit]
Description=IOC: emu-lebt Description=IOC: emu-lebt
After=rc-local.service After=rc-local.service local-fs.target
RequiresMountsFor=/opt/startup/ioc/VME_EMU-iamspecial/emu /opt/epics/modules
[Install] [Install]
WantedBy=multi-user.target WantedBy=multi-user.target
[Service] [Service]
User=root User=root
# Only execute IOC if st.cmd exists # Only execute IOC if st.cmd exists
AssertPathExists=/opt/startup/ioc/VME_EMU-iamspecial/emu/st.cmd AssertPathExists=/opt/startup/ioc/VME_EMU-iamspecial/emu/st.cmd
...@@ -20,3 +21,4 @@ EnvironmentFile=/opt/startup/ioc/VME_EMU-iamspecial/emu/env.sh ...@@ -20,3 +21,4 @@ EnvironmentFile=/opt/startup/ioc/VME_EMU-iamspecial/emu/env.sh
# Run procServ with user ioc # Run procServ with user ioc
ExecStart=/usr/bin/procServ --allow -f -L /var/log/procServ/out-emu -i ^C^D -c /var/run/procServ/emu ${PROCSERV_PORT} ${EPICS_MODULES_PATH}/environment/${ENVIRONMENT_VERSION}/${BASE}/bin/${EPICS_HOST_ARCH}/iocsh /opt/startup/ioc/VME_EMU-iamspecial/emu/st.cmd -n emu ExecStart=/usr/bin/procServ --allow -f -L /var/log/procServ/out-emu -i ^C^D -c /var/run/procServ/emu ${PROCSERV_PORT} ${EPICS_MODULES_PATH}/environment/${ENVIRONMENT_VERSION}/${BASE}/bin/${EPICS_HOST_ARCH}/iocsh /opt/startup/ioc/VME_EMU-iamspecial/emu/st.cmd -n emu
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment