Hi, I setup an mail server, I get connection refused in the logs for incoming email and same thing for outgoing emails. I got also lot of connection refused in the mail queue on the port 10024. I would like to post the logs but unfortunately I cannot because it contain links and the forum doesn't want me posting links. Is there a way to get help? I have no email since I do migrated the system and it start causing issues here. I need to get it work. The server is Ubuntu 20.04 LTS very packages up-to-date and ISPConfig is also up-to-date I don't know know what to provide more, please if you need more information just ask. Thanks in advance for some help, Guillaume
Hello, This is what I've got when I'm doing Code: service amavis status : Code: root@mail:~# service amavis status ● amavis.service - LSB: Starts amavisd-new mailfilter Loaded: loaded (/etc/init.d/amavis; generated) Active: active (exited) since Sun 2020-12-06 15:25:14 EST; 16h ago Docs: man:systemd-sysv-generator(8) Process: 1678 ExecStart=/etc/init.d/amavis start (code=exited, status=0/SUCCESS) Dec 06 15:34:25 mail.zawack.net amavis[2921]: (02921-01) (!)connect to /var/run/clamav/clamd.ctl failed, attempt #1: Can't connect to a UNIX socket /var/run/clamav/clamd.ctl: No such file or directory Dec 06 15:34:25 mail.zawack.net amavis[2921]: (02921-01) (!)ClamAV-clamd: All attempts (1) failed connecting to /var/run/clamav/clamd.ctl, retrying (2) Dec 06 15:34:25 mail.zawack.net amavis[2920]: (02920-01) (!)connect to /var/run/clamav/clamd.ctl failed, attempt #1: Can't connect to a UNIX socket /var/run/clamav/clamd.ctl: No such file or directory Dec 06 15:34:25 mail.zawack.net amavis[2920]: (02920-01) (!)ClamAV-clamd: All attempts (1) failed connecting to /var/run/clamav/clamd.ctl, retrying (2) Dec 06 15:34:31 mail.zawack.net amavis[2921]: (02921-01) (!)connect to /var/run/clamav/clamd.ctl failed, attempt #1: Can't connect to a UNIX socket /var/run/clamav/clamd.ctl: No such file or directory Dec 06 15:34:31 mail.zawack.net amavis[2921]: (02921-01) (!)ClamAV-clamd av-scanner FAILED: run_av error: Too many retries to talk to /var/run/clamav/clamd.ctl (All attempts (1) failed connecting to /var/run/clamav/clamd.ctl) at (eval 11> Dec 06 15:34:31 mail.zawack.net amavis[2921]: (02921-01) (!)WARN: all primary virus scanners failed, considering backups Dec 06 15:34:31 mail.zawack.net amavis[2920]: (02920-01) (!)connect to /var/run/clamav/clamd.ctl failed, attempt #1: Can't connect to a UNIX socket /var/run/clamav/clamd.ctl: No such file or directory Dec 06 15:34:31 mail.zawack.net amavis[2920]: (02920-01) (!)ClamAV-clamd av-scanner FAILED: run_av error: Too many retries to talk to /var/run/clamav/clamd.ctl (All attempts (1) failed connecting to /var/run/clamav/clamd.ctl) at (eval 11> Dec 06 15:34:31 mail.zawack.net amavis[2920]: (02920-01) (!)WARN: all primary virus scanners failed, considering backups I just did a Code: service amavis restart and the status is now: Code: root@mail:~# service amavis status ● amavis.service - LSB: Starts amavisd-new mailfilter Loaded: loaded (/etc/init.d/amavis; generated) Active: active (running) since Mon 2020-12-07 07:34:13 EST; 3s ago Docs: man:systemd-sysv-generator(8) Process: 196508 ExecStart=/etc/init.d/amavis start (code=exited, status=0/SUCCESS) Tasks: 3 (limit: 974) CGroup: /system.slice/amavis.service ├─196526 /usr/sbin/amavisd-new (master) ├─196527 /usr/sbin/amavisd-new (virgin child) └─196528 /usr/sbin/amavisd-new (virgin child) Dec 07 07:34:13 mail.zawack.net amavis[196526]: No decoder for .iso Dec 07 07:34:13 mail.zawack.net amavis[196526]: No decoder for .jar Dec 07 07:34:13 mail.zawack.net amavis[196526]: No decoder for .lha Dec 07 07:34:13 mail.zawack.net amavis[196526]: No decoder for .lrz Dec 07 07:34:13 mail.zawack.net amavis[196526]: No decoder for .rar Dec 07 07:34:13 mail.zawack.net amavis[196526]: No decoder for .rpm Dec 07 07:34:13 mail.zawack.net amavis[196526]: No decoder for .swf Dec 07 07:34:13 mail.zawack.net amavis[196526]: No decoder for .zoo Dec 07 07:34:13 mail.zawack.net amavis[196526]: Using primary internal av scanner code for ClamAV-clamd Dec 07 07:34:13 mail.zawack.net amavis[196526]: Found secondary av scanner ClamAV-clamscan at /usr/bin/clamscan But I'd still have the same issue. Guillaume
The same issue meaning mail queued up because nothing is listening on port 10024? Your status shows amavis is running, what log messages do you get when trying to send a new message now?
Hello, There are the postfix.txt and dovecot.txt After having sent an email. to [email protected] Thanks for your help! Guillaume
So now there is a connection probably to port 10026, also amavis. You might reconfigure services with the ispconfig installer again.
Hi, By re-configuring ispconfig, 2 of 3 messages was able to pass through but nothing was able to get in.
And what happens with me messages now? Still a port 10026 issue or something new? Is amavis still running or did it die?
Good morning! I'm still able to send messages out but none of them reach the destination mailbox, still have port 10026 issues and amavis is still running with errors: Code: root@mail:~# service amavis status ● amavis.service - LSB: Starts amavisd-new mailfilter Loaded: loaded (/etc/init.d/amavis; generated) Active: active (exited) since Tue 2020-12-08 05:30:22 EST; 42min ago Docs: man:systemd-sysv-generator(8) Process: 413183 ExecStart=/etc/init.d/amavis start (code=exited, status=0/SUCCESS) Dec 08 05:30:38 mail.zawack.net amavis[413203]: (413203-01) (!)connect to /var/run/clamav/clamd.ctl failed, attempt #1: Can't connect to a UNIX socket /var/run/clamav/clamd.ctl: No such file or directory Dec 08 05:30:38 mail.zawack.net amavis[413203]: (413203-01) (!)ClamAV-clamd: All attempts (1) failed connecting to /var/run/clamav/clamd.ctl, retrying (2) Dec 08 05:30:38 mail.zawack.net amavis[413202]: (413202-01) (!)connect to /var/run/clamav/clamd.ctl failed, attempt #1: Can't connect to a UNIX socket /var/run/clamav/clamd.ctl: No such file or directory Dec 08 05:30:38 mail.zawack.net amavis[413202]: (413202-01) (!)ClamAV-clamd: All attempts (1) failed connecting to /var/run/clamav/clamd.ctl, retrying (2) Dec 08 05:30:44 mail.zawack.net amavis[413203]: (413203-01) (!)connect to /var/run/clamav/clamd.ctl failed, attempt #1: Can't connect to a UNIX socket /var/run/clamav/clamd.ctl: No such file or directory Dec 08 05:30:44 mail.zawack.net amavis[413203]: (413203-01) (!)ClamAV-clamd av-scanner FAILED: run_av error: Too many retries to talk to /var/run/clamav/clamd.ctl (All attempts (1) failed connecting to /var/run/clamav/clamd.ctl) at (eval> Dec 08 05:30:44 mail.zawack.net amavis[413203]: (413203-01) (!)WARN: all primary virus scanners failed, considering backups Dec 08 05:30:44 mail.zawack.net amavis[413202]: (413202-01) (!)connect to /var/run/clamav/clamd.ctl failed, attempt #1: Can't connect to a UNIX socket /var/run/clamav/clamd.ctl: No such file or directory Dec 08 05:30:44 mail.zawack.net amavis[413202]: (413202-01) (!)ClamAV-clamd av-scanner FAILED: run_av error: Too many retries to talk to /var/run/clamav/clamd.ctl (All attempts (1) failed connecting to /var/run/clamav/clamd.ctl) at (eval> Dec 08 05:30:44 mail.zawack.net amavis[413202]: (413202-01) (!)WARN: all primary virus scanners failed, considering backups Thanks, Guillaume Edit: Also I notice that clamav-daemon was down, I'd start it but it fail after about one minute. Is the issue might be caused because clamav-daemon isn't running?
Is amavis listening on port 10026? Or only on 10024? Amavis should fall back to the perl clamav interface, so when clam daemong is down the behavior I see is merely much slower mail processing. But maybe the secondary scanner isn't working for you? Try fixing clamd and flush the mail queue - problem solved?
I'd think to something, the machine has only 1GB of RAM, and when doing Code: free -m since couples of hours, I've got this: root@mail:~# free -m total used free shared buff/cache available Mem: 908 515 40 18 352 353 Swap: 0 0 0 root@mail:~# free -m total used free shared buff/cache available Mem: 908 519 33 18 354 349 Swap: 0 0 0 root@mail:~# free -m total used free shared buff/cache available Mem: 908 529 19 18 359 339 Swap: 0 0 0 root@mail:~# free -m total used free shared buff/cache available Mem: 908 511 118 18 278 357 Swap: 0 0 0 root@mail:~# free -m total used free shared buff/cache available Mem: 908 511 118 18 278 357 Swap: 0 0 0 root@mail:~# free -m total used free shared buff/cache available Mem: 908 511 118 18 278 357 Swap: 0 0 0 root@mail:~# free -m total used free shared buff/cache available Mem: 908 511 118 18 278 357 Swap: 0 0 0 root@mail:~# free -m total used free shared buff/cache available Mem: 908 512 116 18 278 356 Swap: 0 0 0 root@mail:~# free -m total used free shared buff/cache available Mem: 908 516 107 18 283 352 Swap: 0 0 0 root@mail:~# free -m total used free shared buff/cache available Mem: 908 516 106 18 284 352 Swap: 0 0 0 root@mail:~# free -m total used free shared buff/cache available Mem: 908 516 101 18 290 352 Swap: 0 0 0 root@mail:~# free -m total used free shared buff/cache available Mem: 908 516 86 18 304 352 Swap: 0 0 0 root@mail:~# Is the lack of free memory could be the potential cause of the issue? Thanks, Guillaume
Yes. The problem is the virus scanning. To scan a mail, amavis loads all the signatures into memory to compare with your mail. When you are out of memory, the systems will kill processes and will probably terminate your amavis. We had this several times in this forum. Options: 1. Increase your memory 2. Increase swap (will slow down your server, but applications are not killed due to low memory) 3. Reduce memory usage of amavis (https://serverfault.com/a/283963) 4. Deactivate virus scanning (https://www.howtoforge.com/communit...amassassin-check-in-amavis.52114/#post-290537) 5. Deactivate amavis
IT WORK! Finally! I did the option 4 but will add more memory this weekend, that will be a must. Hej Thanks to all for help. No emails for something like almost 3 weeks, not easy at all Thanks again!!!