checkpath is missing in init script, so if you configure spamd to use another directory for the pidfile. eg. if you want to run it with another user it fails. Reproducible: Always
Created attachment 338012 [details, diff] add checkpath and userdetection fix the problem: * add checkpath * detect and set permission/directory * chown if user specified
Comment on attachment 338012 [details, diff] add checkpath and userdetection It shouldn't use /var/run at all, but /run instead.
(In reply to comment #2) > Comment on attachment 338012 [details, diff] [details, diff] > add checkpath and userdetection > > It shouldn't use /var/run at all, but /run instead. agree it should not use /var/run but the patch still fixes the path creation and user chown. So in the file /etc/conf.d/spamd the PIDFILE should also be moved to /run/spamd.pid
I also stumbled across this when upgrading several production systems to use tmpfs for /run. I don't quite understand why the working patch got removed, nothing said about /var/run in that. Definitely there should be an updated init script in portage, because it can stop spamassassin from working at all which is really a bad thing in webhosting environments.
See also bug #523960, "-u" doesn't change running user of master process. I don't see reason to move pidfile elsewhere. Is a good reason to have option to set PIDFILE in conf.d/spamd? I think it can be removed.
I just fixed this in yet-another-revision: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=19ff5b04b9db6b1319b35e9a6da3d26972bf04b5 I reworked the spamd init/config -- now the PID file is hard-coded, and all that is needed is one simple call to `checkpath --directory`.