I forgot to mention that the above solution works within our LXC guest
environments, but it is not sufficient when running on physical
It seems, that the clamav startup scripts are executed a bit too early.
When they are started, the folder /run or /var/run is not yet a tmpfs.
So the PID files will be written to the harddisk instead of the tmpfs.
When the system is now putting the tmpfs over /run the PIDs are
virtually gone and the monitoring service is unable to see them.
The systemd scripts clamav-daemon.service and clamav-freshclam.service
both require clamav-daemon.socket, so it is necessary to postpone the
execution of it a little bit. I have added the following line to
Honestly I don't know which service is the best one to wait for here. I
just chose network.target, because I knew it is going to be late enough.
Maybe someone has a better idea here.
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
clamav unable to create pid file using systemd
To manage notifications about this bug go to:
ubuntu-bugs mailing list