<html><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">Hi All,<div class=""><br class=""></div><div class="">I realise this is fairly low level stuff, and I have spent a fair bit of time on search engines and forums, but my specific question isn’t being addressed</div><div class=""><br class=""></div><div class=""><br class=""><div class="">I have been running sickgear as a PVR (I know about torrents and copyright breach..don’t @me, I’m a big boy) however it starts by running the following from a command line</div><div class=""><br class=""></div><div class=""><span style="font-style: normal;" class=""><font face="Trebuchet MS" class="">Cd /opt/sickgear</font></span></div><div class=""><span style="font-style: normal;" class=""><font face="Trebuchet MS" class="">Sudo -u python3 ./sickgear.py</font></span></div><div class=""><span style="font-style: normal;" class=""><font face="Trebuchet MS" class=""><br class=""></font></span></div><div class=""><font face="Trebuchet MS" class="">And that works nicely</font></div><div class=""><br class=""></div><div class="">So being a good soldier,(i.e Lazy) I combined these into a bash script (called runsickgear.sh)</div><div class=""><br class=""></div><div class=""><font face="Trebuchet MS" class=""><span style="font-style: normal;" class="">#!/bin/bash</span></font></div><div class=""><font face="Trebuchet MS" class=""><span style="font-style: normal;" class="">Cd /opt/sickgear</span></font></div><div class=""><font face="Trebuchet MS" class=""><span style="font-style: normal;" class="">Sudo -u python3 ./sickgear.py</span></font></div><div class=""><br class=""></div><div class="">Which can be run from CL and works beautifully..</div><div class=""><br class=""></div><div class=""><font face="Trebuchet MS" class="">bash runsickgear.sh</font></div><div class=""><br class=""></div><div class="">Now me, being me, I don’t want the hassle of running no lousy scripts, and I don’t want any untidy terminals left open either (OCD? No not me)</div><div class="">I would like this to run as a service at boot time, and Be stopped, started and messed around with using</div><div class=""><br class=""></div><div class=""><font face="Trebuchet MS" class=""><span style="font-style: normal;" class="">Sudo systemctl sickgear {stop/start/enable/halt & catchfire}</span></font></div><div class=""><br class=""></div><div class="">SO I copy the runsickgear.sh script to</div><div class=""><br class=""></div><div class="">/usr/bin/sickgear/runsickgear.sh</div><div class=""><br class=""></div><div class="">Generate a file /etc/systemd/system/sickgear.service</div><div class=""> Which looks like</div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><font face="Trebuchet MS" class=""><span style="font-style: normal;" class="">[Unit]</span></font></div><div class=""><font face="Trebuchet MS" class=""><span style="font-style: normal;" class="">Description=sickgear service</span></font></div><div class=""><font face="Trebuchet MS" class=""><span style="font-style: normal;" class=""><br class=""></span></font></div><div class=""><font face="Trebuchet MS" class=""><span style="font-style: normal;" class="">[Service]</span></font></div><div class=""><font face="Trebuchet MS" class=""><span style="font-style: normal;" class=""> ExecStart=/usr/bin/sickgear/runsickgear.sh</span></font></div><div class=""><font face="Trebuchet MS" class=""><span style="font-style: normal;" class=""><br class=""></span></font></div><div class=""><font face="Trebuchet MS" class=""><span style="font-style: normal;" class="">[Install]</span></font></div><div class=""><font face="Trebuchet MS" class=""><span style="font-style: normal;" class="">WantedBy=Multi-User.Target</span></font></div><div class=""><br class=""></div><div class="">Now according to Google, etc after I run </div><div class="">Sudo systemctl daemon-reload</div><div class="">Then I should be able to do systemctl enable etc</div><div class=""><br class=""></div><div class="">But I can’t, </div><div class=""><br class=""></div><div class="">And the logs seem to give me no insight, and the Ubuntu forums seem more interested in angels dancing on heads of pins or whether </div><div class="">I am fairly sure this is a syntax error somewhere, but what ever I do, it doesn’t seem to work.. Given my desk and keyboard now have forehead shaped dents in need help. Google has loads o examples, and I have worked through many of them (Mostly look the same as the ones I’ve shown)</div><div class=""><br class=""></div><div class="">Any bright ideas?</div><div class=""><br class=""></div><div class="">Cheers</div><div class="">Richard</div><div class=""><br class=""></div></div></body></html>