spamassassin-update can't open '/etc/conf.d/spamd': No such file or directory ```
The package spamassassin-3.4.4-r2 contains the file etc/periodic/daily/spamassassin-update
which contains the following:
#!/bin/sh
set -e
. /etc/conf.d/spamd
pidfile="${pidfile:-/run/spamd.pid}"
if [ -f "$pidfile" ]; then
_pid="$(cat "$pidfile")"
fi
/usr/bin/sa-update
if [ -n "$_pid" ]; then
kill -SIGHUP "$_pid"
fi
But since there is no file /etc/conf.d/spamd
the following error is generated once a day:
/etc/periodic/daily/spamassassin-update: .: line 5: can't open '/etc/conf.d/spamd': No such file or directory
It is likely that the intended purpose is to run sa-update
once a day, but that now fails.
Two remedies are suggested, either one of them would be sufficient:
- Change the
etc/periodic/daily/spamassassin-update
file so that it checks that/etc/conf.d/spamd
exists before trying to source it. - Make sure that the file
/etc/conf.d/spamd
is created (can be empty) during package installation.