Hi, I have a postfix-3.5.8 system with amavisd on fedora33. I'm trying to get an idea of how many emails are queued because they can't be delivered in a timely manner by analyzing the logs, instead of just periodically running "mailq" in a script. Is this possible?
This log entry, for example, appears to show this email was queued before being processed: Jan 17 00:00:20 armor postfix/qmgr[1249324]: ABD1C3A3D87: from=<3vMIDYA4KBVcCDI74N-CDG3EAN5DD5A3.1DBPQQQW6DI3A.03HIL3HI3GC.1DB@chime-n otifications.bounces.google.com>, size=34580, nrcpt=2 (queue active) Maybe instead it should be "deferred" messages? Jan 17 07:02:50 cipher postfix/smtp[2027771]: EC93D288102BB: to=<l...@google.com>, orig_to=<sa...@example.com>, relay=none, delay=130746, delays=130716/0.01/30/0, dsn=4.4.1, status=deferred (connect to google.com[91.195.240.117]:25: Connection timed out) I'm trying to get a count of all deferred/queued messages pending delivery over a period of time, such as the last hour, if I can query the logs to find this. I suppose I could also check the number of files in /var/spool/postfix/deferred, but aren't there also times where the "active" queue is some non-zero number?