Problem when shut/start sendmail and mailscanner
mailscanner at ecs.soton.ac.uk
Mon Aug 19 18:49:00 IST 2002
At 18:44 19/08/2002, you wrote:
> > >The filenames are start with "df" and "xf", e.g. dfg7DBSLt13069 and
> > >xfg7DBSLt13069.
> > >
> > >Do you think what I can to delete this files ?
> > The last thing sendmail does with a message is rename the xf to qf, so you
> > could do that. On www.sendmail.org there is a really good script to start
> > sendmail that cleans up the queue really well.
>And when there is only "df" files in the mqueue.in directory ?
If there are only df files, you might as well delete them, as you certainly
don't have enough info to be able to deliver them.
>I don't found the script in www.sendmail.org.
Here's the relevant bit:
# Install everything if necessary (needed after careless Sun patching)
[ -x $SENDMAIL/bin/install.sendmail ] && $SENDMAIL/bin/install.sendmail
# Make placeholders for status files
[ -d $SENDMAIL/var/status ] || mkdir $SENDMAIL/var/status
[ -f $SENDMAIL/var/sendmail.st ] || touch $SENDMAIL/var/sendmail.st
echo "Starting sendmail:\c"
echo " clean up queue\c"
for queuedir in $QUEUE $INQUEUE
# remove zero length qf files
for qffile in qf*
if [ -r $qffile ]; then
if [ ! -s $qffile ]; then
rm -f $qffile
# rename tf files to be qf if the qf does not exist
for tffile in tf*
qffile=`echo $tffile | sed 's/t/q/'`
# JKF 15/7/98 Put $qffile in quotes in case tffile = 'tf*'
if [ -r $tffile -a ! -f "$qffile" ]; then
mv $tffile $qffile
if [ -f $tffile ]; then
rm -f $tffile
# remove df files with no corresponding qf files
for dffile in df*
qffile=`echo $dffile | sed 's/d/q/'`
if [ -r $dffile -a ! -f $qffile ]; then
mv $dffile `echo $dffile | sed 's/d/D/'`
# announce files that have been saved during disaster recovery
for xffile in [A-Z]f*
if [ -f $xffile ]; then
echo " <saved mail spool $xffile>\c"
# Now actually start the damn thing...
#$SENDMAIL/bin/sendmail -bd -ODeliveryMode=queueonly
Julian Field Teaching Systems Manager
jkf at ecs.soton.ac.uk Dept. of Electronics & Computer Science
Tel. 023 8059 2817 University of Southampton
Southampton SO17 1BJ
More information about the MailScanner