pmg-smtp-filter keeps crashing with segfault

May 20, 2017
172
18
58
Netherlands
cyberfusion.nl
pmg-smtp-filter keeps crashing every so often. I cannot figure out why. Email gets stuck in the mail queue because pmg-smtp-filter is turned off and thus mail cannot be relayed. Starting the service and flushing the mail queue fixes the problem temporarily.

I cannot figure out why pmg-smtp-filter keeps crashing. The crash happens out of nowhere:

Code:
root@proxmox-mg0:~# cat /var/log/messages|grep "Jul  3 09:2"
Jul  3 09:21:31 proxmox-mg0 kernel: [945761.931203] pmg-smtp-filter[20376]: segfault at 7f8ca60d8000 ip 00007f8cacdb278a sp 00007ffcc693b968 error 4 in libc-2.24.so[7f8cacd2f000+195000]
Jul  3 09:25:11 proxmox-mg0 freshclam[759]: Received signal: wake up
Jul  3 09:25:11 proxmox-mg0 freshclam[759]: ClamAV update process started at Tue Jul  3 09:25:11 2018
Jul  3 09:25:11 proxmox-mg0 freshclam[759]: Your ClamAV installation is OUTDATED!
Jul  3 09:25:11 proxmox-mg0 freshclam[759]: Local version: 0.99.4 Recommended version: 0.100.0
Jul  3 09:25:11 proxmox-mg0 freshclam[759]: DON'T PANIC! Read http://www.clamav.net/documents/upgrading-clamav
Jul  3 09:25:11 proxmox-mg0 freshclam[759]: main.cvd is up to date (version: 58, sigs: 4566249, f-level: 60, builder: sigmgr)
Jul  3 09:25:11 proxmox-mg0 freshclam[759]: Can't download daily.cvd from database.clamav.net
Jul  3 09:25:11 proxmox-mg0 freshclam[759]: Trying again in 5 secs...
Jul  3 09:25:16 proxmox-mg0 freshclam[759]: ClamAV update process started at Tue Jul  3 09:25:16 2018
Jul  3 09:25:16 proxmox-mg0 freshclam[759]: Your ClamAV installation is OUTDATED!
Jul  3 09:25:16 proxmox-mg0 freshclam[759]: Local version: 0.99.4 Recommended version: 0.100.0
Jul  3 09:25:16 proxmox-mg0 freshclam[759]: DON'T PANIC! Read http://www.clamav.net/documents/upgrading-clamav
Jul  3 09:25:16 proxmox-mg0 freshclam[759]: main.cvd is up to date (version: 58, sigs: 4566249, f-level: 60, builder: sigmgr)
Jul  3 09:25:16 proxmox-mg0 freshclam[759]: Can't download daily.cvd from database.clamav.net
Jul  3 09:25:16 proxmox-mg0 freshclam[759]: Trying again in 5 secs...
Jul  3 09:25:21 proxmox-mg0 freshclam[759]: ClamAV update process started at Tue Jul  3 09:25:21 2018
Jul  3 09:25:21 proxmox-mg0 freshclam[759]: Your ClamAV installation is OUTDATED!
Jul  3 09:25:21 proxmox-mg0 freshclam[759]: Local version: 0.99.4 Recommended version: 0.100.0
Jul  3 09:25:21 proxmox-mg0 freshclam[759]: DON'T PANIC! Read http://www.clamav.net/documents/upgrading-clamav
Jul  3 09:25:21 proxmox-mg0 freshclam[759]: main.cvd is up to date (version: 58, sigs: 4566249, f-level: 60, builder: sigmgr)
Jul  3 09:25:21 proxmox-mg0 freshclam[759]: Can't download daily.cvd from database.clamav.net
Jul  3 09:25:21 proxmox-mg0 freshclam[759]: Trying again in 5 secs...
Jul  3 09:25:26 proxmox-mg0 freshclam[759]: ClamAV update process started at Tue Jul  3 09:25:26 2018
Jul  3 09:25:26 proxmox-mg0 freshclam[759]: Your ClamAV installation is OUTDATED!
Jul  3 09:25:26 proxmox-mg0 freshclam[759]: Local version: 0.99.4 Recommended version: 0.100.0
Jul  3 09:25:26 proxmox-mg0 freshclam[759]: DON'T PANIC! Read http://www.clamav.net/documents/upgrading-clamav
Jul  3 09:25:26 proxmox-mg0 freshclam[759]: main.cvd is up to date (version: 58, sigs: 4566249, f-level: 60, builder: sigmgr)
Jul  3 09:25:26 proxmox-mg0 freshclam[759]: Can't download daily.cvd from database.clamav.net
Jul  3 09:25:26 proxmox-mg0 freshclam[759]: Trying again in 5 secs...
Jul  3 09:25:31 proxmox-mg0 freshclam[759]: ClamAV update process started at Tue Jul  3 09:25:31 2018
Jul  3 09:25:31 proxmox-mg0 freshclam[759]: Your ClamAV installation is OUTDATED!
Jul  3 09:25:31 proxmox-mg0 freshclam[759]: Local version: 0.99.4 Recommended version: 0.100.0
Jul  3 09:25:31 proxmox-mg0 freshclam[759]: DON'T PANIC! Read http://www.clamav.net/documents/upgrading-clamav
Jul  3 09:25:31 proxmox-mg0 freshclam[759]: main.cvd is up to date (version: 58, sigs: 4566249, f-level: 60, builder: sigmgr)
Jul  3 09:25:31 proxmox-mg0 freshclam[759]: Giving up on database.clamav.net...
Jul  3 09:25:31 proxmox-mg0 freshclam[759]: Update failed. Your network may be down or none of the mirrors listed in /etc/clamav/freshclam.conf is working. Check http://www.clamav.net/doc/mirrors-faq.html for possible reasons.
Jul  3 09:25:31 proxmox-mg0 freshclam[759]: --------------------------------------

Any idea why this keeps happening?
 
  1. Do you run latest version? Post the output of "pmgversion -v"
  2. How much RAM do you have?
 
Do you run latest version?

Yes.

Post the output of "pmgversion -v"

Code:
root@proxmox-mg0:~# pmgversion -v
proxmox-mailgateway: 5.0-7 (API: 5.0-61/71d9a758, running kernel: 4.13.13-5-pve)
pmg-api: 5.0-61
pmg-gui: 1.0-31
proxmox-spamassassin: 3.4.1-54
proxmox-widget-toolkit: 1.0-10
pve-kernel-4.13.13-5-pve: 4.13.13-38
libpve-http-server-perl: 2.0-8
lvm2: 2.02.168-2
pve-firmware: 2.0-3
libpve-common-perl: 5.0-27
pmg-docs: 5.0-13
pve-xtermjs: 1.0-2
libarchive-perl: 3.2.1-1
libxdgmime-perl: 0.01-3
zfsutils-linux: 0.7.3-pve1~bpo9
libpve-apiclient-perl: 2.0-2


How much RAM do you have?

1 GB
It is not getting exhausted.
 
Please update your PMG to latest version (includes a fix for your issue). seems you do not have a subscription key or the pmg-no-subscription repo. See docs for details.
 
Unfortunately, pmg-smtp-filter crashed with a segfault again. The segfault issue has not been fixed with the update.

System log:

Code:
Jul  9 20:34:58 proxmox-mg0 freshclam[826]: --------------------------------------
Jul  9 20:37:53 proxmox-mg0 clamd[837]: SelfCheck: Database status OK.
Jul  9 21:04:58 proxmox-mg0 freshclam[826]: Received signal: wake up
Jul  9 21:04:58 proxmox-mg0 freshclam[826]: ClamAV update process started at Mon Jul  9 21:04:58 2018
Jul  9 21:04:59 proxmox-mg0 freshclam[826]: Your ClamAV installation is OUTDATED!
Jul  9 21:04:59 proxmox-mg0 freshclam[826]: Local version: 0.99.4 Recommended version: 0.100.1
Jul  9 21:04:59 proxmox-mg0 freshclam[826]: DON'T PANIC! Read http://www.clamav.net/documents/upgrading-clamav
Jul  9 21:04:59 proxmox-mg0 freshclam[826]: main.cvd is up to date (version: 58, sigs: 4566249, f-level: 60, builder: sigmgr)
Jul  9 21:04:59 proxmox-mg0 freshclam[826]: daily.cvd is up to date (version: 24737, sigs: 2008285, f-level: 63, builder: neo)
Jul  9 21:04:59 proxmox-mg0 freshclam[826]: safebrowsing.cvd is up to date (version: 47602, sigs: 2976207, f-level: 63, builder: google)
Jul  9 21:04:59 proxmox-mg0 freshclam[826]: bytecode.cvd is up to date (version: 322, sigs: 90, f-level: 63, builder: neo)
Jul  9 21:04:59 proxmox-mg0 freshclam[826]: --------------------------------------
Jul  9 21:21:58 proxmox-mg0 kernel: [542859.457746] pmg-smtp-filter[28397]: segfault at 7f8163905000 ip 00007f816a5df78a sp 00007ffebaec1828 error 4 in libc-2.24.so[7f816a55c000+195000]
 
No, it seems to happen at random. I monitor the box with Graphite, SNMP and Sensu and there is no indication or reason the crash occurs so to see. But they do occur, so something is up.

Aleary checked/tested the RAM on that host?
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!