Clamd fails on reboot

Arthur Dent misc.lists at
Thu Jul 21 18:15:56 UTC 2011

On Wed, 2011-07-20 at 16:11 +0100, Arthur Dent wrote:

> For the benefit of the archives this is what now works for me:
> #============8<===================================================
> # In the definitions section:
> CLAMD_PIDDIR=/var/run/clamd.${CLAMD_SERVICE}
> # and in the "start" stanza:
>  if [ ! -d $CLAMD_PIDDIR ] ; then
>          mkdir $CLAMD_PIDDIR && chown clamd:clamd $CLAMD_PIDDIR
>       fi
> #============8<===================================================

For those who aren't following the bug Apparently the
correct solution to the problem of /var/run now being tempfs (and
therefore wiped clean with each reboot) is to create a /etc/tmpfiles.d
file with instructions on how to create the directory with the
appropriate permissions. This simply involves (for me) creating
a /etc/tmpfiles.d/clamd.conf file with the following line in it:

d /var/run/clamd.clamd 0700 clamd clamd -

At reboot the directory /var/run/clamd.clamd/ is then created with 0700
permissions and clamd:clamd ownership. The clamd package will then start

I hope that helps anyone else suffering the same problem.


-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part
Url : 

More information about the users mailing list