Sometimes when I reboot the machine, I experience that mailman doesn't
start because the files /opt/mailman3/mm/var/locks/master.lck* isn't
deleted during shutdown. Maybe one way to solve this could be to use
ExecStartPre directive in the systemd service to remove the lock files.
What's the best practice to solve this problem? BTW I've noticed that
doing systemctl stop mailman3 takes a very long time, 45 secs. or
something like that.
Mailman 3.3.10
Python 3.12.13
[Unit]
Description=GNU Mailing List Manager
After=syslog.target network.target postgresql.service
[Service]
Type=forking
PIDFile=/opt/mailman3/mm/var/master.pid
User=mailman3
Group=mailman3
Environment="MAILMAN_CONFIG_FILE=/etc/mailman3/mailman.cfg"
ExecStart=/opt/mailman3/venv/bin/mailman start
ExecReload=/opt/mailman3/venv/bin/mailman restart
ExecStop=/opt/mailman3/venv/bin/mailman stop
# Tested, but have no effect on deletion of the lock file.
#Restart=on-failure
#RestartSec=15
[Install]
WantedBy=multi-user.target
Lars
On 6/21/26 4:16 AM, Lars Bjørndal wrote:
Sometimes when I reboot the machine, I experience that mailman doesn't start because the files /opt/mailman3/mm/var/locks/master.lck* isn't deleted during shutdown. Maybe one way to solve this could be to use ExecStartPre directive in the systemd service to remove the lock files. What's the best practice to solve this problem?
You can add --force to the ExecStart command in your service file.
BTW I've noticed that doing
systemctl stop mailman3takes a very long time, 45 secs. or something like that.
This is because it waits for all the runners to exit and bounce runner in particular sleeps for (default) 15 seconds.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
On 6/21/26 8:50 AM, Mark Sapiro wrote:
This is because it waits for all the runners to exit and bounce runner in particular sleeps for (default) 15 seconds.
Actually, the default sleep time for the bounce runner is 2 minutes, and the retry runner sleeps even longer <https://gitlab.com/mailman/mailman/-/blob/master/src/mailman/config/mailman....>.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
participants (2)
-
Lars Bjørndal -
Mark Sapiro