clamdscan: corrupt or unknown clamd scanner error or memory/resource/

Este error me he encontrado en un servidor con qmail + qmail-scanner, el error exactamente era el siguiente:

Sep 23 12:54:05 delta X-Antivirus-xxx.xx-1.25-st-qms:  [xxxxxxxxtx.cxmx22x6x2x5x0x3x2x57] clamdscan: corrupt  or unknown clamd scanner error or memory/resource/perms problem -  exit status 512/

Por otro lado el log de clamd nos daba más pistas sobre como solucionar el error:

ERROR: Socket file /tmp/clamd.socket exists. Either remove it, or configure a different one.

Así de fácil ha sido, eliminamos el socket y reiniciamos clamd:

rm -f  /tmp/clamd.socket && /etc/init.d/clamd restart