maillog日志报错无法打开clamd.sock

ClamAV-clamd+av-scanner+FAILED:+run_av+error:+Too+many+retries+to+talk+to+/tmp/clamd.sock

在maillog里面查看到

maillog

Dec  5 16:01:44 mail amavis[3342]: (03342-03) (!)connect to /tmp/clamd.sock failed, attempt #1: Can’t connect to UNIX socket /tmp/clamd.sock

Dec  5 16:01:49 mail amavis[3344]: (03344-02) (!)ClamAV-clamd av-scanner FAILED: run_av error: Too many retries to talk to /tmp/clamd.sock (All attempts (1) failed connecting to /tmp/clamd.sock) at (eval 102) line 600.\n
Dec  5 16:01:49 mail amavis[3344]: (03344-02) (!)WARN: all primary virus scanners failed, considering backups
Dec  5 16:01:49 mail amavis[3344]: (03344-02) (!!)AV: ALL VIRUS SCANNERS FAILED

此处的问题参考2个配置文件

/etc/amavisd.conf

#LocalSocket /tmp/clamd.socket修改为LocalSocket /var/run/clamav/clamd.sock

/usr/local/clamav/etc/clamd.conf

#LocalSocket /tmp/clamd.socket 修改为LocalSocket /var/run/clamav/clamd.sock

注意/var/run/clamav的权限,用户是amavis.amavis 755

此条目发表在Mail分类目录。将固定链接加入收藏夹。