I wanted to test something (else) and installed virtualmin from scratch on a fresh Ubuntu this morning. I sent a mail to a test account and I did get the mail, but I couldn’t find the mail log. I felt like I was missing something right in front of my face but /var/log/mail.log is not there.
I found another thread about this (No Mail log on fresh install) which says that virtualmin has been changed to use journalctl.
How can I get useful mail logs (dovecot and smtp mostly) out of the journal? That thread’s recommendation (journalctl -fu postfix) does not give smtp results for example
vs:
(which has the logs you’d expect from postfix in /var/log/mail.log)
What was the reason for the change?
Is there a way to revert/convert this to using /var/log/mail.log?
How long (and where) is journal archived and how easy is it to separate mail logs that I care about from the endless spinning system stuff that I don’t for storage purposes?
We keep mail logs for as long as possible. Occasionally we get a request like “so and so says they haven’t used the mail for 6 months and don’t want to pay, when is the last time they used mail?”. Or “so and so has a subpoena for mail logs for x-person for the last two years” etc… Since mail logs are ordinarily plain text (and contain all and only mail logs) we just zip them nightly, send them to storage, and generally forget them.
How would I emulate that with journal?
Ron
SYSTEM INFORMATION | |
---|---|
OS type and version | Ubuntu 24.04 |
Virtualmin version | 7.20.2 |