[SOLVED] systemd service for fancontrol not working

Hi all,
I have configured fancontrol because the fan of my Dell laptop is spinning all the time.
This is working quite well now, and I like to get fancontrol started automatically.
I was reading the man pages and some tutorials, and I thought that I have a tiny "fancontrol.service" file properly created.
However, the service starts, but after a short while, it is stopped for a unknown reason. It seems that systemd tries to restart the broken service, but fails.
Here is my service file. What is wrong with it?
Since /sbin/fancontrol is a shell script, I understood that "forking" is the appropriate type, and that the PID file should be specified as well.
I took the path for the PID file directly from the source code of the fancontrol shell script.
Thanks a lot in advance for your help!
Regards,
Marcus
I have configured fancontrol because the fan of my Dell laptop is spinning all the time.
This is working quite well now, and I like to get fancontrol started automatically.
I was reading the man pages and some tutorials, and I thought that I have a tiny "fancontrol.service" file properly created.
However, the service starts, but after a short while, it is stopped for a unknown reason. It seems that systemd tries to restart the broken service, but fails.
Here is my service file. What is wrong with it?
- Code: Select all
[Unit]
Description=Fancontrol service
[Service]
Type=forking
ExecStart=/sbin/fancontrol
PIDFile=/var/run/fancontrol.pid
[Install]
WantedBy=multi-user.target
Since /sbin/fancontrol is a shell script, I understood that "forking" is the appropriate type, and that the PID file should be specified as well.
I took the path for the PID file directly from the source code of the fancontrol shell script.
Thanks a lot in advance for your help!
Regards,
Marcus