View Single Post
Old September 20th, 2013, 09:46 AM   #956 (permalink)
jonbanjo
Member
 
Join Date: May 2013
Location: UK
Posts: 209
 
Device(s): Samsung Galaxy Ace 2 sim free, Acer Iconia A200
Carrier: Not Provided

Thanks: 13
Thanked 50 Times in 45 Posts
Default

Quote:
Originally Posted by jonbanjo View Post
I had a "fun" with an init scripts for my Raspberry Pi and in the end resorted to killall to terminate the program. The XPL Hub I'm using starts a couple of new processes and then exits so the pid you grab is for a process that has already closed.
I've been setting up a new (OpenSuse) PC to handle my various network tasks. It also needs the XPL hub. I thought I'd try a systemd service file . I've not used one before but I was pleasantly surprised. All I needed was:

Code:
[Unit]
Description=XPL Hub
After=network.target

[Service]
Type=forking
ExecStart=/home/jon/jfhome/xPLLib/examples/xPL_Hub
[Install]
WantedBy=multi-user.target
jonbanjo is offline  
Reply With Quote