[Mailman-Users] Backing up list settings

Matthew Newton mcn4 at leicester.ac.uk
Fri Jun 3 15:50:21 CEST 2005


Hi,

In my system scripts, before I remove a list, I would like to backup the
list including all settings and the mail archives.

The machine is backed up every night, so this is "just in-case".

Would the following be the right sort of thing? (To restore I guess I
would create a list with the same name, stop Mailman, and then untar.)

---8<---
#! /bin/sh

LIST=$1

BACKUP="/var/lib/mailman/lists/$LIST"
BACKUP="$BACKUP /var/lib/mailman/archives/private/$LIST"
BACKUP="$BACKUP /var/lib/mailman/archives/private/$LIST.mbox"
if [ -e "/var/lib/mailman/archives/public/$LIST" ]; then
  BACKUP="$BACKUP /var/lib/mailman/archives/public/$LIST"
fi

tar zcvf - $BACKUP
---8<---

Usage something like:

  ./backup-script listname > list-backup.tar.gz

Thanks

Matthew


-- 
Matthew Newton <mcn4 at le.ac.uk>

UNIX and e-mail Systems Administrator, Network Support Section,
Computer Centre, University of Leicester,
Leicester LE1 7RH, United Kingdom



More information about the Mailman-Users mailing list