1

Topic: Can't send or receive - Problem with clamav?

==== Required information ====
- iRedMail version:
- Store mail accounts in which backend (LDAP/MySQL/PGSQL):
- Linux/BSD distribution name and version:
- Related log if you're reporting an issue:
==== ==== Required information ====
- iRedMail version: 0.8.3
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): MySQL
- Linux/BSD distribution name and version: Ubuntu 12.04
- Related log if you're reporting an issue: mail.log
====
Hi.  I just tried a fresh install of iRedMail on a brand new Ubuntu 12.04 install in a VPS.  I didn't see any errors during the install.  I can log into Roundcube and IRedAdmin.  I can create new email accounts in IRedAdmin.

BUT, when I send an email it never makes to its destination.  Roundcube says the message was sent, but it wasn't.  Likewise, I can't receive emails either.  I'm not sure how to begin, but here's the output of /var/log/mail.log since I restarted my server, tried sending one message and tried receiving one message.

Dec 13 19:50:24 mx amavis[802]: starting.  /usr/sbin/amavisd-new at mx.backsaba.com amavisd-new-2.6.5 (20110407), Unicode aware
Dec 13 19:50:24 mx amavis[802]: Perl version               5.014002
Dec 13 19:50:25 mx amavis[1007]: Net::Server: Group Not Defined.  Defaulting to EGID '119 119'
Dec 13 19:50:25 mx amavis[1007]: Net::Server: User Not Defined.  Defaulting to EUID '112'
Dec 13 19:50:25 mx amavis[1007]: Module Amavis::Conf        2.208
Dec 13 19:50:25 mx amavis[1007]: Module Archive::Zip        1.30
Dec 13 19:50:25 mx amavis[1007]: Module BerkeleyDB          0.49
Dec 13 19:50:25 mx amavis[1007]: Module Compress::Zlib      2.033
Dec 13 19:50:25 mx amavis[1007]: Module Convert::TNEF       0.17
Dec 13 19:50:25 mx amavis[1007]: Module Convert::UUlib      1.4
Dec 13 19:50:25 mx amavis[1007]: Module Crypt::OpenSSL::RSA 0.27
Dec 13 19:50:25 mx amavis[1007]: Module DBD::mysql          4.020
Dec 13 19:50:25 mx amavis[1007]: Module DBI                 1.616
Dec 13 19:50:25 mx amavis[1007]: Module DB_File             1.821
Dec 13 19:50:25 mx amavis[1007]: Module Digest::MD5         2.51
Dec 13 19:50:25 mx amavis[1007]: Module Digest::SHA         5.61
Dec 13 19:50:25 mx amavis[1007]: Module IO::Socket::INET6   2.69
Dec 13 19:50:25 mx amavis[1007]: Module MIME::Entity        5.502
Dec 13 19:50:25 mx amavis[1007]: Module MIME::Parser        5.502
Dec 13 19:50:25 mx amavis[1007]: Module MIME::Tools         5.502
Dec 13 19:50:25 mx amavis[1007]: Module Mail::DKIM::Signer  0.39
Dec 13 19:50:25 mx amavis[1007]: Module Mail::DKIM::Verifier 0.39
Dec 13 19:50:25 mx amavis[1007]: Module Mail::Header        2.08
Dec 13 19:50:25 mx amavis[1007]: Module Mail::Internet      2.08
Dec 13 19:50:25 mx amavis[1007]: Module Mail::SPF           v2.008
Dec 13 19:50:25 mx amavis[1007]: Module Mail::SpamAssassin  3.003002
Dec 13 19:50:25 mx amavis[1007]: Module Net::DNS            0.66
Dec 13 19:50:25 mx amavis[1007]: Module Net::Server         0.99
Dec 13 19:50:25 mx amavis[1007]: Module NetAddr::IP         4.058
Dec 13 19:50:25 mx amavis[1007]: Module Socket6             0.23
Dec 13 19:50:25 mx amavis[1007]: Module Time::HiRes         1.972101
Dec 13 19:50:25 mx amavis[1007]: Module URI                 1.59
Dec 13 19:50:25 mx amavis[1007]: Module Unix::Syslog        1.1
Dec 13 19:50:25 mx amavis[1007]: Amavis::DB code      loaded
Dec 13 19:50:25 mx amavis[1007]: Amavis::Cache code   loaded
Dec 13 19:50:25 mx amavis[1007]: SQL base code        loaded
Dec 13 19:50:25 mx amavis[1007]: SQL::Log code        loaded
Dec 13 19:50:25 mx amavis[1007]: SQL::Quarantine      NOT loaded
Dec 13 19:50:25 mx amavis[1007]: Lookup::SQL code     NOT loaded
Dec 13 19:50:25 mx amavis[1007]: Lookup::LDAP code    NOT loaded
Dec 13 19:50:25 mx amavis[1007]: AM.PDP-in proto code loaded
Dec 13 19:50:25 mx amavis[1007]: SMTP-in proto code   loaded
Dec 13 19:50:25 mx amavis[1007]: Courier proto code   NOT loaded
Dec 13 19:50:25 mx amavis[1007]: SMTP-out proto code  loaded
Dec 13 19:50:25 mx amavis[1007]: Pipe-out proto code  NOT loaded
Dec 13 19:50:25 mx amavis[1007]: BSMTP-out proto code NOT loaded
Dec 13 19:50:25 mx amavis[1007]: Local-out proto code loaded
Dec 13 19:50:25 mx amavis[1007]: OS_Fingerprint code  NOT loaded
Dec 13 19:50:25 mx amavis[1007]: ANTI-VIRUS code      loaded
Dec 13 19:50:25 mx amavis[1007]: ANTI-SPAM code       loaded
Dec 13 19:50:25 mx amavis[1007]: ANTI-SPAM-EXT code   NOT loaded
Dec 13 19:50:25 mx amavis[1007]: ANTI-SPAM-C code     NOT loaded
Dec 13 19:50:25 mx amavis[1007]: ANTI-SPAM-SA code    loaded
Dec 13 19:50:25 mx amavis[1007]: Unpackers code       loaded
Dec 13 19:50:25 mx amavis[1007]: DKIM code            loaded
Dec 13 19:50:25 mx amavis[1007]: Tools code           NOT loaded
Dec 13 19:50:25 mx amavis[1007]: Found $file            at /usr/bin/file
Dec 13 19:50:25 mx amavis[1007]: Found $altermime       at /usr/bin/altermime
Dec 13 19:50:25 mx amavis[1007]: Internal decoder for .mail
Dec 13 19:50:25 mx amavis[1007]: No decoder for       .F   
Dec 13 19:50:25 mx amavis[1007]: Found decoder for    .Z    at /bin/uncompress
Dec 13 19:50:25 mx amavis[1007]: Internal decoder for .gz  
Dec 13 19:50:25 mx amavis[1007]: Found decoder for    .bz2  at /bin/bzip2 -d
Dec 13 19:50:25 mx amavis[1007]: Found decoder for    .lzo  at /usr/bin/lzop -d
Dec 13 19:50:25 mx amavis[1007]: Found decoder for    .rpm  at /usr/bin/rpm2cpio
Dec 13 19:50:25 mx amavis[1007]: Found decoder for    .cpio at /bin/pax
Dec 13 19:50:25 mx amavis[1007]: Found decoder for    .tar  at /bin/pax
Dec 13 19:50:25 mx amavis[1007]: Found decoder for    .deb  at /usr/bin/ar
Dec 13 19:50:25 mx amavis[1007]: Internal decoder for .zip 
Dec 13 19:50:25 mx amavis[1007]: Found decoder for    .7z   at /usr/bin/7zr
Dec 13 19:50:25 mx amavis[1007]: Found decoder for    .rar  at /usr/bin/unrar-free
Dec 13 19:50:25 mx amavis[1007]: Found decoder for    .arj  at /usr/bin/arj
Dec 13 19:50:25 mx amavis[1007]: Found decoder for    .arc  at /usr/bin/nomarch
Dec 13 19:50:25 mx amavis[1007]: Found decoder for    .zoo  at /usr/bin/zoo
Dec 13 19:50:25 mx amavis[1007]: No decoder for       .lha 
Dec 13 19:50:25 mx amavis[1007]: Found decoder for    .doc  at /usr/bin/ripole
Dec 13 19:50:25 mx amavis[1007]: Found decoder for    .cab  at /usr/bin/cabextract
Dec 13 19:50:25 mx amavis[1007]: No decoder for       .tnef
Dec 13 19:50:25 mx amavis[1007]: Internal decoder for .tnef
Dec 13 19:50:25 mx amavis[1007]: Found decoder for    .exe  at /usr/bin/unrar-free; /usr/bin/arj
Dec 13 19:50:25 mx amavis[1007]: Using primary internal av scanner code for ClamAV-clamd
Dec 13 19:50:25 mx amavis[1007]: Found secondary av scanner ClamAV-clamscan at /usr/bin/clamscan
Dec 13 19:50:25 mx amavis[1007]: Creating db in /var/lib/amavis/db/; BerkeleyDB 0.49, libdb 5.1
Dec 13 19:50:33 mx postfix/master[1558]: daemon started -- version 2.9.3, configuration /etc/postfix
Dec 13 19:52:15 mx postfix/smtpd[1923]: connect from mx.backsaba.com[127.0.0.1]
Dec 13 19:52:24 mx postfix/smtpd[1923]: 6F9DC41040: client=mx.backsaba.com[127.0.0.1], sasl_method=LOGIN, sasl_username=chrispag@backsaba.com
Dec 13 19:52:25 mx postfix/cleanup[1936]: 6F9DC41040: message-id=<e9cffcef45534b4918410f56de4aacf0@backsaba.com>
Dec 13 19:52:25 mx postfix/qmgr[1563]: 6F9DC41040: from=<chrispag@backsaba.com>, size=552, nrcpt=1 (queue active)
Dec 13 19:52:25 mx roundcube: User chris@backsaba.com [99.236.220.75]; Message for chris.pag@gmail.com; 250: 2.0.0 Ok: queued as 6F9DC41040
Dec 13 19:52:26 mx postfix/smtpd[1923]: disconnect from mx.backsaba.com[127.0.0.1]
Dec 13 19:52:27 mx amavis[1267]: (01267-01) (!)ClamAV-clamd: Can't connect to UNIX socket /tmp/clamd.socket: Connection refused, retrying (2)
Dec 13 19:52:33 mx amavis[1267]: (01267-01) (!)ClamAV-clamd av-scanner FAILED: run_av error: Too many retries to talk to /tmp/clamd.socket (Can't connect to UNIX socket /tmp/clamd.socket: Connection refused) at (eval 102) line 375.\n
Dec 13 19:52:33 mx amavis[1267]: (01267-01) (!!)WARN: all primary virus scanners failed, considering backups
Dec 13 19:52:39 mx amavis[1267]: (01267-01) (!)ClamAV-clamscan av-scanner FAILED: /usr/bin/clamscan KILLED, signal 9 (0009) at (eval 102) line 596.
Dec 13 19:52:39 mx amavis[1267]: (01267-01) (!!)TROUBLE in check_mail: virus_scan FAILED: AV: ALL VIRUS SCANNERS FAILED
Dec 13 19:52:39 mx amavis[1267]: (01267-01) (!)PRESERVING EVIDENCE in /var/lib/amavis/tmp/amavis-20121213T195225-01267
Dec 13 19:52:40 mx postfix/smtp[1942]: 6F9DC41040: to=<chris.pag@gmail.com>, relay=127.0.0.1[127.0.0.1]:10024, delay=23, delays=8.8/0.05/0.12/14, dsn=4.5.0, status=deferred (host 127.0.0.1[127.0.0.1] said: 451 4.5.0 Error in processing, id=01267-01, virus_scan FAILED: AV: ALL VIRUS SCANNERS FAILED (in reply to end of DATA command))

I noticed that clam-daemon is NOT running but clam-freshclam IS running.  I can't get clam-daemon to start, it fails to start.

Now here's something else.  I restarted my server a whole bunch of times.  Every now and then, upon a reboot, some of the messages I sent are getting through.  So it seems to work sometimes for a second or two after a reboot.

Any help would be really great.

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: Can't send or receive - Problem with clamav?

The root cause is ClamAV daemon (not freshclam) was not running. Please try to update virus database manually with command "freshclam":

# freshclam

Then try to start clamav-daemon and Amavisd service.