On Wed, Jun 7, 2023 at 10:36 PM {16/7} <acc@hexadecagram.org> wrote:
Hello,
I have both the mailman and mailman3-full packages installed on my machine and I'm following the migration guide located here: https://docs.mailman3.org/en/latest/migration.html
Running the command { mailman import21 mylist@mysite.com /var/lib/mailman/lists/mylist/config.pck } completes once I create the list but states that it cannot convert the msg_footer and digest_footer mailing list attributes. (I might also point out that the { mailman create mylist@mysite.com } command isn't actually documented on that webpage.)
I can't seem to find the manage.py script in my $PATH and after searching, I find it as part of the mailman3-web package. When I run { sudo -H -u list python manage.py hyperkitty_import mylist@mysite.com /var/lib/mailman/archives/private/mylist.mbox/mylist.mbox }, it fails with "ImportError: No module named django.core.management".
If I run the script directly as { sudo -H -u list /usr/share/mailman3-web/manage.py ... }, I get "PermissionError: [Errno 13] Permission denied: '/usr/share/mailman3-web/settings_local.py'".
By default, settings_local.py's group is www-data, and not knowing where to go next, I decided to try changing that file's group to list. When I re-ran the command (as user list), I got a Python traceback that gives "PermissionError: [Errno 13] Permission denied: '/var/log/mailman3/web/mailman-web.log'".
Next, I changed the file's group back to list and decided to try running the manage.py script as the www-data user. This results in "/usr/lib/python3/dist-packages/django_q/conf.py:139: UserWarning: Retry and timeout are misconfigured." and "System check identified some issues:" followed by a list of "Auto-created primary key used when not defining a primary key type, by default 'django.db.models.AutoField'" warnings for a number of Django tables. At the end of this list is "CommandError: The list address must be given on the command-line". But it *was* given.
Without using the recommended installation method, helping you is gonna be some effort! That recommended method is detailed at: https://docs.mailman3.org/en/latest/install/virtualenv.html#virtualenv-insta...
My questions are:
- How do I undo any damage (if any) my efforts may have caused?
You should not be worried so much because the Mailman3 confusion does not mess up your Mailman2.x install at all. If anything, I suppose just changing ownership of Mailman2.x files back to list:list should get Mailman2.x running.
- What's the correct way to run manage.py?
Use the recommended installation method: https://docs.mailman3.org/en/latest/install/virtualenv.html#virtualenv-insta... . Then from the virtualenv, you can migrate lists as follows:
- Create the list: mailman create listname@domain
- Import settings: mailman import21 listname@domains /path/to/lists/listname/config.pck
- Import archives: mailman-web hyperkitty_import -l listname@domain /path/to/archives/private/listname.mbox/listname.mbox # This can take long, if your archives are big
- Reindex the archives: mailman-web update_index_one_list listname@domain
This too can take long!
PS: You are right about migration. I have looked at https://docs.mailman3.org/en/latest/migration.html and it really does not to be updated to conform with the latest recommended documentation. Don't worry, we all went through that difficult process. You will make it.
-- Best regards, Odhiambo WASHINGTON, Nairobi,KE +254 7 3200 0004/+254 7 2274 3223 "Oh, the cruft.", egrep -v '^$|^.*#' ¯\_(ツ)_/¯ :-) [How to ask smart questions: http://www.catb.org/~esr/faqs/smart-questions.html]