Revision 5 as of 2015-01-31 02:36:58

Clear message

4.18. How do I backup my lists and their configurations/membership rosters?

See also FAQ 4.6 at 4.06 How can I backup my Mailman lists-membership-etc on a regular basis?

You can use the following scripts in a cronjob:

  #set -x
  # Sends a file to an email address as a MIME attachment.
  # Syntax: mimemail <subject> <file> <address>
  # Note: Requires MH or nmh to be installed (uses MHN)


  echo "To: ${addr}
  From: nobody
  Subject: ${subject}

  #application/octet-stream [${subject}] ${file}

  " | /usr/bin/mh/mhbuild - > /tmp/mimemail.tmp.${$}
  /usr/lib/mh/post -verbose -watch /tmp/mimemail.tmp.${$}
  rm /tmp/mimemail.tmp.${$}

  #Put in a cronjob to archive your lists and email them to you
  #set -x

  datestr=`date +%Y%m%d`
  host=`hostname -f`

  cd /var/lib/mailman
  tar zcf ${filepath} lists
  cd ~/backups
  ~/bin/mimemail ${file} ${filepath} ${sendto}

The result is a tarball emailed to you by the cronjob which contains the entire lists directory hierarchy of your Mailman installation.

Converted from the Mailman FAQ Wizard

This is one of many Frequently Asked Questions.