Using --debug and --debug-sa with Postfix

Glenn Steen glenn.steen at gmail.com
Thu May 14 06:07:18 IST 2009


2009/5/14 Julian Field <MailScanner at ecs.soton.ac.uk>:
>
>
> On 13/05/2009 15:02, Steve Barnes wrote:
>>
>> Hi
>>
>> I'm trying to understand how to use --debug and --debug-sa with
>> Postfix as the MTA to observe the processing of a single message.
>>
>> Having stoppped all MailScanner processes, I run:
>>
>> /opt/MailScanner/bin/MailScanner --debug --debug-sa
>>
>> I get lots of debug output on screen, with no discernable errors,
>> which eventually stops at:
>>
>> "Building a message batch to scan..."
>>
>> Now at this point, I thought I could get away with doing:
>>
>> cp -p /var/spool/MailScanner/quarantine/20090512/spam/A8B5F1168A.A78ED
>> /var/spool/postfix/hold
>>
>
> For starters the filename MailScanner is expecting doesn't have the ".A78ED"
> on the end.
>>
>> And MS would come back to life and begin processing the message, but
>> it doesn't. It just remains sat at "Building a message batch to
>> scan..."
>>
>> MS runs as user Postfix, and the permissions on the file before and
>> after cp are:
>>
>> -rw-rw----  1 postfix  mail
chmod 0700 /path/to/queue/file
All this (should be) in the wiki article on how to release quarantined messages.
>>
>> What am I missing here?
>
> You may well be hitting the "processing-messages" database. If you let it
> pick up the message in a batch once and then kill it before it processes the
> message, it will eventually stop collecting that message file. Delete
> /var/spool/MailScanner/incoming/*db before running MailScanner each time,
> and make sure the filename is correct as above. Then it will pick up the
> message.
>>
>>  Does "Quarantine Whole Messages As Queue
>> Files" have any bearing on what I'm trying to do?
>>
>
> No, you want that. Just remove the dot and everything after that, as what
Well... if it is set to "no", then you don't have a queue file;-)...
Then the spam quarantine is just the RFC822 message file named as the
queuef file (with entropy), and he would need use a sendmail-command
method of reintroducing the message... But you knew that Jules;-):-).

> you have now is not a valid Postfix queue filename, but one with extra
> entropy added by MailScanner to ensure the filenames are distinct. Without
> Postfix can use the same filename twice within a relatively short time
> period on some systems.
Quite true.

>> Thank you
>>
>> Steve
>>
>> PS, I'm using:
>>
>> MS 4.76.24,
>> Perl 5.10.0,
>> SA 3.2.5,
>> FreeBSD 7.2,
>> Postfix 2.5.6 and
>> MailWatch 1.0.4.
>>
>
> Jules
>

Cheers
-- 
-- Glenn
email: glenn < dot > steen < at > gmail < dot > com
work: glenn < dot > steen < at > ap1 < dot > se


More information about the MailScanner mailing list