[Mailman-Users] bulk deletion of pending requests

Jerry Feldman gaf at blu.org
Mon Jul 7 20:08:42 CEST 2003


On Mon, 7 Jul 2003 10:31:35 -0700 (PDT)
Dan Busarow <dan at dpcsys.com> wrote:

> This is no longer working for me.  No idea when it stopped working
> since it is not used very often. When I run it I get
I use the following script. I think I found it on the mailman faq or
posted to this list. Note that I use a pre-made empty request.db. I was
getting over 100 requests a day on one of my lists. 
------------------------
#!/bin/bash
# usage remove_held <list>
# removes held messages
RM=/bin/rm
if [ $# != 1 ]
then
        echo "usage: $0 <listname>"
        exit -1
fi
LISTNAME=$1
EMPTY=~mailman/data/request.db.empty
HELD=~mailman/data/heldmsg-$LISTNAME
TARGET=~mailman/lists/$LISTNAME
if [ ! -e $EMPTY ]
then
        echo "$EMPTY not found"
        exit -1
fi
if [ ! -d $TARGET ]
then
        echo "$TARGET not found"
        exit -1
fi
$RM -fv $HELD*
cp $EMPTY $TARGET/request.db
exit 0
----------------------------------

-- 
Jerry Feldman <gaf at blu.org>
Boston Linux and Unix user group
http://www.blu.org PGP key id:C5061EA9
PGP Key fingerprint:053C 73EC 3AC1 5C44 3E14 9245 FB00 3ED5 C506 1EA9
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://mail.python.org/pipermail/mailman-users/attachments/20030707/9c01db65/attachment.pgp 


More information about the Mailman-Users mailing list