On 1/7/23 14:14, Mike Wertheim wrote:
I'm on Debian 11, trying to troubleshoot an installation of Mailman 3.3.3 that was done by someone else.
Mailman is running as a non-privileged (non-root) user called 'xyz'. On the day that Mailman was installed, that non-privileged 'xyz' user was able to execute mailman commands successfully to create, view and modify lists.
The Debian package uses 'list' as the Mailman User. Whoever did the installation apparently tried to change that to 'xyz' and did an incomplete job.
A couple of days later, when the 'xyz' user tried running those same mailman commands, they failed with this error: PermissionError: [Errno 13] Permission denied: '/var/log/mailman3/mailman.log'
Doing "ls -l" on the file /var/log/mailman3/mailman.log showed this: -rw-r----- 1 list list 0 Jan 6 00:00 /var/log/mailman3/mailman.log
When I did a 'ps' command, I saw that all of the mailman processes are running as user 'xyz'. No processes were running as the user 'list'.
It seems that some process is rotating the mailman.log file at midnight, and the newly-created mailman.log is being owned by user 'list'.
Can anyone explain why this is happening, and how to fix it?
It is happening because the logrotate script (maybe /etc/logrotate.d/mailman3) sets the user to 'list'. change that to 'xyz'.
Also
sudo chown -R xyz:xyz /var/log/mailman3/
and wait for the next issue to arise.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan