Hi, I looked to the version I in the old installation:
mysql> select * from alembic_version; +--------------+ | version_num | +--------------+ | 4bd95c99b2e7 | +--------------+ 1 row in set (0.00 sec)
I set the same version on the new. Actually I loaded a fresh dump from DB to be sure it was the same.
And now it is starting without errors. I guess that was it.
Thanks a lot!
Best Regards, Helio Loureiro https://helio.loureiro.eng.br https://github.com/helioloureiro https://mastodon.social/@helioloureiro
On Thu, 14 Dec 2023 at 18:47, Mark Sapiro <mark@msapiro.net> wrote:
On 12/14/23 01:48, Helio Loureiro wrote:
But it is failing to start displaying the domain name from the previous machine.
(venv) mailman@new-server ~ (v3.3.9)> mailman start Starting Mailman's master runner Generating MTA alias maps Traceback (most recent call last): File
"/local/mailman/venv/lib/python3.10/site-packages/sqlalchemy/engine/base.py",
line 1969, in _exec_single_context self.dialect.do_execute( File
line 922, in do_execute cursor.execute(statement, parameters) File "/local/mailman/venv/lib/python3.10/site-packages/pymysql/cursors.py",
153, in execute result = self._query(query) File "/local/mailman/venv/lib/python3.10/site-packages/pymysql/cursors.py",
"/local/mailman/venv/lib/python3.10/site-packages/sqlalchemy/engine/default.py", line line
322, in _query conn.query(q) File
"/local/mailman/venv/lib/python3.10/site-packages/pymysql/connections.py",
line 558, in query self._affected_rows = self._read_query_result(unbuffered=unbuffered) File
"/local/mailman/venv/lib/python3.10/site-packages/pymysql/connections.py",
line 822, in _read_query_result result.read() File
"/local/mailman/venv/lib/python3.10/site-packages/pymysql/connections.py",
line 1200, in read first_packet = self.connection._read_packet() File
"/local/mailman/venv/lib/python3.10/site-packages/pymysql/connections.py",
line 772, in _read_packet packet.raise_for_error() File "/local/mailman/venv/lib/python3.10/site-packages/pymysql/protocol.py", line 221, in raise_for_error err.raise_mysql_exception(self._data) File "/local/mailman/venv/lib/python3.10/site-packages/pymysql/err.py", line 143, in raise_mysql_exception raise errorclass(errno, errval) pymysql.err.OperationalError: (1054, "Unknown column 'domain.alias_domain' in 'field list'")
The issue is your domains table and possibly others are not up to the current schema. This should be accomplished by Mailman core running all the necessary migrations in mailman/database/alembic/versions/. For some reason, alembic's MigrationContext thinks the migrations have been run, but they haven't. In the
mailman
database, the alembic_version table has the version_num of the putative current version. The migration that added alias_domain is dfe82cf73702_add_alias_domain.py. If there is no alias_domain column in the domain table, alembic_version.version_num should be a version older than 'dfe82cf73702'.I suggest querying the prior mailman database for the alembic_version.version_num value and setting that in the current database, assuming that that migration exists in mailman/database/alembic/versions/.
This may be sufficient, but there may be other inconsistencies depending on exactly what you did.
-- Mark Sapiro <mark@msapiro.net> The highway is for gamblers, San Francisco Bay Area, California better use your sense - B. Dylan
Mailman-users mailing list -- mailman-users@mailman3.org To unsubscribe send an email to mailman-users-leave@mailman3.org https://lists.mailman3.org/mailman3/lists/mailman-users.mailman3.org/ Archived at: https://lists.mailman3.org/archives/list/mailman-users@mailman3.org/message/...
This message sent to helio@loureiro.eng.br