On my fresh install I am running into problems with the alembic number.
root@darni ~ # systemctl restart mailman3 ; systemctl restart mailmanwebq Job for mailman3.service failed because the control process exited with error code. See "systemctl status mailman3.service" and "journalctl -xeu mailman3.service" for details. Failed to restart mailmanwebq.service: Unit mailmanwebq.service not found. root@darni ~ # systemctl status mailman3.service × mailman3.service - GNU Mailing List Manager Loaded: loaded (/etc/systemd/system/mailman3.service; enabled; preset: enabled) Active: failed (Result: exit-code) since Sat 2026-03-07 07:01:03 UTC; 2s ago Duration: 23h 33min 7.258s Invocation: dde1db5581914d96b1da564d537df84a Process: 1209747 ExecStart=/usr/local/mailman/venv/bin/mailman start (code=exited, status=1/FAILURE) Mem peak: 64.8M CPU: 681ms
Mar 07 07:01:03 darni mailman[1209747]: File "/usr/lib/python3.13/contextlib.py", line 162, in __exit__ Mar 07 07:01:03 darni mailman[1209747]: self.gen.throw(value) Mar 07 07:01:03 darni mailman[1209747]: ~~~~~~~~~~~~~~^^^^^^^ Mar 07 07:01:03 darni mailman[1209747]: File "/usr/local/mailman/venv/lib/python3.13/site-packages/alembic/script/base.py", line 245, in _catch_revision_errors Mar 07 07:01:03 darni mailman[1209747]: raise util.CommandError(resolution) from re Mar 07 07:01:03 darni mailman[1209747]: alembic.util.exc.CommandError: Can't locate revision identified by '8cc1f79f4459' Mar 07 07:01:03 darni systemd[1]: mailman3.service: Control process exited, code=exited, status=1/FAILURE Mar 07 07:01:03 darni systemd[1]: mailman3.service: Failed with result 'exit-code'. Mar 07 07:01:03 darni systemd[1]: Failed to start mailman3.service - GNU Mailing List Manager. Mar 07 07:01:03 darni systemd[1]: mailman3.service: Consumed 681ms CPU time over 727ms wall clock time, 64.8M memory peak.
Indeed:
root@darni ~ # sudo -u postgres psql -d mailman3 psql (18.2 (Debian 18.2-1)) Type "help" for help.
mailman3=# SELECT version_num FROM alembic_version; version_num
8cc1f79f4459 (1 row)
Setting the number to say 0
mailman3=# update alembic_version set version_num=0; UPDATE 1
and repeating the restart yields the same problem.
-- Written by Thomas Krichel http://openlib.org/home/krichel on his 22191st day.
Thomas Krichel writes:
On my fresh install I am running into problems with the alembic number.
I failed to reproduce with Debian stable, Python 3.11.2-1+b1.
Did you reuse the virtual environment? Did you reinitialize the PostgreSQL 'mailman3' database?
In any case, I suggest activating the virtual environment, then
python -m pip install --upgrade alembic==1.18.4, reinitializing the
'mailman3' database in PostgreSQL, and then starting Mailman.
If you did any work on your Mailman instance (like creating domains and lists, or migrating lists from another list manager), you should back up the 'mailman3' database first. I can't really help you with that, but there's a good chance here somebody knows how to save you some work if you have a backup of the database.
-- GNU Mailman consultant (installation, migration, customization) Sirius Open Source https://www.siriusopensource.com/ Software systems consulting in Europe, North America, and Japan
On 3/6/26 23:22, Thomas Krichel wrote:
...
Mar 07 07:01:03 darni mailman[1209747]: alembic.util.exc.CommandError: Can't locate revision identified by '8cc1f79f4459' ... root@darni ~ # sudo -u postgres psql -d mailman3 psql (18.2 (Debian 18.2-1)) Type "help" for help.
mailman3=# SELECT version_num FROM alembic_version; version_num
8cc1f79f4459 (1 row)
That's not what it's complaining about. You have to look at /usr/local/mailman/venv/lib/python3.13/mailman/database/alembic/versions. Those are all the alembic migrations. Each one has a Revision ID: and a Revises: making a chain. There are tools to display that chain. With your venv active do
alembic -c
/usr/local/mailman/venv/lib/python3.13/mailman/config/alembic.cfg history
What does that show?
I suspect there is some issue between the database and the code. The
version_num in the alembic_version table and the migrations. The
version_num is the current migration so that mailman-web migrate knows
which additional migrations to apply.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
participants (3)
-
Mark Sapiro -
Stephen J. Turnbull -
Thomas Krichel