[Mailman-Users] Restoring lists on newer version
Ivan Van Laningham
ivanlan at pauahtun.org
Mon Nov 26 21:54:17 CET 2007
Hi All--
(Comments interpolated; new question at end.)
Mark Sapiro wrote:
> Ivan Van Laningham wrote:
>> What's the best procedure to restore my lists? I've got a dozen, but
>> only three have significant traffic. Do I copy the backups to the
>> proper location and then make the lists with Plesk, or do I make the
>> lists first and then copy the data in?
>
>
> Neither. You just copy the lists/<listname>/ and
> archives/private/<listname>*/ directories to the proper locations. If
> there are held messages, you can copy the data/heldmsg* files too, but
> may not want those.
>
Worked like a charm.
> After copying those things, the lists and archives will be functional
> in the web interface. If the MTA uses aliases automatically created by
> Mailman as with Postfix, run bin/genaliases after copying which will
> regenerate aliases including those for the copied lists. If the MTA
> uses some kind of programatic routing for Mailman as with Exim,
> nothing is required.
>
> If Plesk makes aliases in some other way, You may have to do them
> manually.
>
I found a script in the mailman docs, which I modifed to make it useful
for Plesk. I give it here to help other users:
#!/bin/sh
if [ $# = 1 ]; then
i=$1
echo Making links to $i in the current directory...
echo "|/var/qmail/bin/preline /var/qmail/bin/mm_wrapper
/usr/lib/mailman/mail/mailman post $i" > .qmail-$i
echo "|/var/qmail/bin/preline /var/qmail/bin/mm_wrapper
/usr/lib/mailman/mail/mailman admin $i" > .qmail-$i-admin
echo "|/var/qmail/bin/preline /var/qmail/bin/mm_wrapper
/usr/lib/mailman/mail/mailman bounces $i" > .qmail-$i-bounces
# The following line is for VERP
# echo "|/var/qmail/bin/preline /var/qmail/bin/mm_wrapper
/usr/lib/mailman/mail/mailman bounces $i" > .qmail-$i-bounces-default
echo "|/var/qmail/bin/preline /var/qmail/bin/mm_wrapper
/usr/lib/mailman/mail/mailman confirm $i" > .qmail-$i-confirm
echo "|/var/qmail/bin/preline /var/qmail/bin/mm_wrapper
/usr/lib/mailman/mail/mailman join $i" > .qmail-$i-join
echo "|/var/qmail/bin/preline /var/qmail/bin/mm_wrapper
/usr/lib/mailman/mail/mailman leave $i" > .qmail-$i-leave
echo "|/var/qmail/bin/preline /var/qmail/bin/mm_wrapper
/usr/lib/mailman/mail/mailman owner $i" > .qmail-$i-owner
echo "|/var/qmail/bin/preline /var/qmail/bin/mm_wrapper
/usr/lib/mailman/mail/mailman request $i" > .qmail-$i-request
echo "|/var/qmail/bin/preline /var/qmail/bin/mm_wrapper
/usr/lib/mailman/mail/mailman subscribe $i" > .qmail-$i-subscribe
echo "|/var/qmail/bin/preline /var/qmail/bin/mm_wrapper
/usr/lib/mailman/mail/mailman unsubscribe $i" > .qmail-$i-unsubscribe
fi
#===end==============
There should be no returns after mm_wrapper. You need to be in your
qmail alias directory for this to work. For example, to create the
aliases on pumperdink.org for a list named 'test', I would go to
/var/qmail/mailnames/pumperdink.org
and run 'mkal.sh test'
ls -a will show the proper alias files.
>
>> I also have significant customization of the admin and info pages; can I
>> rescue that without too much trouble? Or do I have to transfer all the
>> custom modifications by hand? (It's all appearance, by the way; nothing
>> affects Mailman operation in any way.)
>
>
> Do you mean customization of templates or actual modifications to the
> code in admin.py (or the Mailman/Gui/ modules) and listinfo.py.
>
> If you've modified templates per list, the lists/<listname>/<language>/
> directory has already been copied per the above copy of
> lists/<listname>/, so that is done. If you've modified templates per
> host or the site, just copy the templates/<host_name>/<language>/
> and/or templates/site/<language>/ directories.
>
> If you modified templates in templates/<language>/, that is not good.
> Copy the modified templates to templates/site/<language>/. See
> <http://www.python.org/cgi-bin/faqw-mm.py?req=show&file=faq04.048.htp>
>
> If you've modified admin.py, the Gui/ modules, and/or listinfo.py,
> ideally you kept a patch (diff) of your modifications (or you kept the
> unmodified versions and can make a diff now), and you can apply that
> to the new code. If you didn't do that, and all you have is modified
> code, you could download the base 2.1.5 modules from
> <http://mailman.svn.sourceforge.net/viewvc/mailman/tags/Release_2_1_5/mailman/Mailman/>
> and either diff those against the Plesk 2.1.9 modules to make a patch
> for your modules or diff your modules against the 2.1.5 base to make a
> patch for the Plesk modules.
>
It turned out that my old installation was 2.1.8, so running diffs on
various directories was relatively painless. I did modify the templates
under the en directory only; again, diffs were easy. Most of my mods
are simply to add a meta tag to pick up a style sheet.
The only tricky part was that lists on a system administered by Plesk
are all treated as if they're on a host named lists. For example,
http://lists.pumperdink.org/mailman/admin/test/
So you either have to add the lists.<domain-name> CNAME record to your
DNS records, or create a dummy list through the control panel. If you
create one list called 'test', then subsequent attempts to create the
same listname on other virtual hosts fail, but the CNAME record is still
added.
The disadvantage is that the lists don't show up on the Plesk control
panel, only the newly created dummy lists. Since you don't really do
anything in Plesk except create the lists, this is not, to me, a big
deal. Once they're restored, the aliases are in place, and the
list.<domain> entry is in DNS, you can admin the lists in the standard
Mailman way.
Thanks once again, Mark, for absolutely outstanding advice. Kudoes.
QMAIL QUESTION, not Mailman:
Now my big problem is that my qmail is configured with default, very
conservative, settings. When I initially set the server up back in
March, I ran across a page on the net showing how to increase the limits
and queue sizes (?) to speed up qmail. I failed to write that site
down, and naturally can't find it again.
If anyone can help either track the site down, or fill me in on the
settings, to improve performance, I would greatly appreciate it. I
apologize for the off-topic nature of the problem, but this list has
always been of the greatest help, and if there are any others out there
running Mailman on Plesk, the answers might help them too.
Metta,
Ivan
--
Ivan Van Laningham
God N Locomotive Works
http://www.pauahtun.org/
http://www.python.org/workshops/1998-11/proceedings/papers/laningham/laningham.html
Army Signal Corps: Cu Chi, Class of '70
Author: Teach Yourself Python in 24 Hours
More information about the Mailman-Users
mailing list