Hello, Sorry if this question is a bit basic for a devel list, I tried asking it in a ubuntu forum but didn't get any views, let alone replies.
I have a PC running Mythbuntu which has an LCD which I had a bit of a struggle getting going under systemd. However using Type=forking it is now working fine. However reading the man page for systemd.service is says that it is recommended to use PIDFile. I have tried adding PIDFile=/run/LCDd.pid but this causes an error message:- LCDd.service - LCDd Loaded: loaded (/etc/systemd/system/LCDd.service; enabled; vendor preset: enabled) Active: activating (start) since Tue 2018-02-13 09:49:03 GMT; 1min 8s ago Process: 2485 ExecStart=/usr/sbin/LCDd -c /home/steve/lcd/LCDd.conf (code=exited, status=0/SUCCESS) CGroup: /system.slice/LCDd.service └─2487 /usr/sbin/LCDd -c /home/steve/lcd/LCDd.conf Feb 13 09:49:03 mythbuntu systemd[1]: Starting LCDd... Feb 13 09:49:03 mythbuntu systemd[1]: LCDd.service: PID file /run/LCDd.pid not readable (yet?) after start: No such file or directory steve@mythbuntu:~$ Removing the line PIDFile=/run/LCDd.pid in LCDd.service and all is good. I have tried creating LCDd.pid in /run with root:root but get the same. How is the pid file generated? Am I right in thinking that LCDd is so old that it hasn't been written with systemd in mind so does not support PIDFile? LCDd.service [Unit] Description=LCDd After=multi-user.target [Service] Type=forking PIDFile=/run/LCDd.pid ExecStart=/usr/sbin/LCDd -c /home/steve/lcd/LCDd.conf TimeoutStopSec=1s Restart=on-failure RestartSec=5 StartLimitInterval=30 StartLimitBurst=5 [Install] WantedBy=multi-user.target LCDd.conf ## This file was written by cme command. ## You can run 'cme edit lcdproc' to modify this file. ## You may also modify the content of this file with your favorite editor. [server] DriverPath=/home/steve/lcd/ Driver=vlsys_m428 NextScreenKey=Right PrevScreenKey=Left ReportToSyslog=yes ToggleRotateKey=Enter ServerScreen=no Bind=127.0.0.1 Port=13666 User=nobody Hello="Mythbuntu" WaitTime=5 [menu] DownKey=Down EnterKey=Enter MenuKey=Escape UpKey=Up [vlsys_m428] Device=/dev/ttyUSB0 LCDd.conf (END) -- Regards, Steve Goodey Colchester, England mailto://st...@goodey.org Registered Linux User #372670 http://counter.li.org [1] Hello to Jason Isaacs -------- [1] 372670.png
_______________________________________________ systemd-devel mailing list systemd-devel@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/systemd-devel