HowTo: MailScanner 4.24 for Exim 4.24

I'm getting this when I start mailscanner

MailScanner: Can't locate Archive/Zip.pm in @INC (@INC contains: /usr/lib/MailScanner /usr/lib64/perl5/5.8.5/x86_64-linux-thread-multi /usr/lib/p erl5/5.8.5 /usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi /usr/lib64 /perl5/site_perl/5.8.4/x86_64-linux-thread-multi /usr/lib64/perl5/site_perl/5.8. 3/x86_64-linux-thread-multi /usr/lib64/perl5/site_perl/5.8.2/x86_64-linux-thread -multi /usr/lib64/perl5/site_perl/5.8.1/x86_64-linux-thread-multi /usr/lib64/per l5/site_perl/5.8.0/x86_64-linux-thread-multi /usr/lib/perl5/site_perl/5.8.5 /usr /lib/perl5/site_perl/5.8.4 /usr/lib/perl5/site_perl/5.8.3 /usr/lib/perl5/site_pe rl/5.8.2 /usr/lib/perl5/site_perl/5.8.1 /usr/lib/perl5/site_perl/5.8.0 /usr/lib/ perl5/site_perl /usr/lib64/perl5/vendor_perl/5.8.5/x86_64-linux-thread-multi /us r/lib64/perl5/vendor_perl/5.8.4/x86_64-linux-thread-multi /usr/lib64/perl5/vendo r_perl/5.8.3/x86_64-linux-thread-multi /usr/lib64/perl5/vendor_perl/5.8.2/x86_64 -linux-thread-multi /usr/lib64/perl5/vendor_perl/5.8.1/x86_64-linux-thread-multi /usr/lib64/perl5/vendor_perl/5.8.0/x86_64-linux-thread-multi /usr/lib/perl5/ven dor_perl/5.8.5 /usr/lib/perl5/vendor_perl/5.8.4 /usr/lib/perl5/vendor_perl/5.8.3 /usr/lib/perl5/vendor_perl/5.8.2 /usr/lib/perl5/vendor_perl/5.8.1 /usr/lib/perl 5/vendor_perl/5.8.0 /usr/lib/perl5/vendor_perl . /usr/lib/MailScanner/5.8.5/x86_ 64-linux-thread-multi /usr/lib/MailScanner/5.8.5 /usr/lib/MailScanner/x86_64-lin ux-thread-multi /usr/lib/MailScanner/5.8.4 /usr/lib/MailScanner/5.8.3 /usr/lib/M ailScanner/5.8.2 /usr/lib/MailScanner/5.8.1 /usr/lib/MailScanner/5.8.0 /usr/lib/ MailScanner) at /usr/lib/MailScanner/MailScanner/Message.pm line 48.
BEGIN failed--compilation aborted at /usr/lib/MailScanner/MailScanner/Message.pm line 48.
Compilation failed in require at /usr/sbin/MailScanner line 78.
BEGIN failed--compilation aborted at /usr/sbin/MailScanner line 78.
 
Your missing the Archive::Zip module for perl by the looks of things.

You can either install it via cpan or using yum.
 
cool thanks, its working

//edit
-.- now i cant recieve and send mail. I've sent a mail an hour ago and its still not arrived at gmail. Also the opposite gmail -> server. Still nothing
Services are running...
 
Last edited:
If you can't send / receive mail check which processes are running:
Code:
ps auxwww|grep exim

If you see a load of exim processes running you may need to kill a few of them and give MS a HUP

Ensure you've got the MailScanner & exim init scripts symlinked..
 
in /etc/init.d

You may have an exim AND a mailscanner script

You should remove the exim one and symlink the mailscanner one to exim otherwise you end up with two sets running which can be extremely messy
 
Still no mails

Exim processes:
mail 10239 0.0 0.1 26872 2380 ? Ss 00:00 0:00 /usr/sbin/exim -C /etc/exim.conf -bd
mail 10242 0.0 0.1 26872 2368 ? Ss 00:00 0:00 /usr/sbin/exim -C /etc/exim_outgoing.conf -q15m

I removed exim and created a symlink by using this command " ln -s MailScanner exim "

What else could be wrong?
 
It's hard to say...

If you restart MailScanner what do your logs say?

More importantly, if you send an email to a domain on the server what do the logs say?
 
I used dnsstuffs to check my domain

I get this
WARNING: One or more of your mailservers does not accept mail in the domain literal format (user@[0.0.0.0]). Mailservers are technically required RFC1123 5.2.17 to accept mail to domain literals for any of its IP addresses. Not accepting domain literals can make it more difficult to test your mailserver, and can prevent you from receiving E-mail from people reporting problems with your mailserver. However, it is unlikely that any problems will occur if the domain literals are not accepted (mailservers at many common large domains have this problem).


mail.domain.com's postmaster@[111.111.111.111] response:
>>> RCPT TO:<postmaster@[111.111.111.111]>
<<< 501 <postmaster@[111.111.111.111]>: domain literals not allowed

Maillog:
Jun 22 00:16:59 testing MailScanner[11524]: Connected to SpamAssassin cache database
Jun 22 00:16:59 testing MailScanner[11524]: Enabling SpamAssassin auto-whitelist functionality...
Jun 22 00:17:00 testing MailScanner[11524]: Using locktype = posix
Jun 22 00:17:00 testing MailScanner[11524]: Creating hardcoded struct_flock subroutine for linux (Linux-type)
Jun 22 00:17:06 testing MailScanner[11521]: MailScanner child caught a SIGHUP
Jun 22 00:17:06 testing MailScanner[11524]: MailScanner child caught a SIGHUP
Jun 22 00:17:06 testing MailScanner[11520]: MailScanner child caught a SIGHUP
Jun 22 00:17:06 testing MailScanner[11519]: MailScanner child caught a SIGHUP
Jun 22 00:17:06 testing MailScanner[11514]: MailScanner child caught a SIGHUP
Jun 22 00:17:17 testing MailScanner[11600]: MailScanner E-Mail Virus Scanner version 4.54.6 starting...
Jun 22 00:17:17 testing MailScanner[11600]: Read 746 hostnames from the phishing whitelist
Jun 22 00:17:18 testing MailScanner[11600]: Using SpamAssassin results cache
Jun 22 00:17:18 testing MailScanner[11600]: Connected to SpamAssassin cache database
Jun 22 00:17:18 testing MailScanner[11600]: Enabling SpamAssassin auto-whitelist functionality...
Jun 22 00:17:18 testing MailScanner[11600]: Using locktype = posix
Jun 22 00:17:18 testing MailScanner[11600]: Creating hardcoded struct_flock subroutine for linux (Linux-type)
Jun 22 00:17:28 testing MailScanner[11608]: MailScanner E-Mail Virus Scanner version 4.54.6 starting...
Jun 22 00:17:28 testing MailScanner[11608]: Read 746 hostnames from the phishing whitelist
Jun 22 00:17:29 testing MailScanner[11608]: Using SpamAssassin results cache
Jun 22 00:17:29 testing MailScanner[11608]: Connected to SpamAssassin cache database
Jun 22 00:17:29 testing MailScanner[11608]: Enabling SpamAssassin auto-whitelist functionality...
Jun 22 00:17:29 testing MailScanner[11608]: Using locktype = posix
Jun 22 00:17:29 testing MailScanner[11608]: Creating hardcoded struct_flock subroutine for linux (Linux-type)
Jun 22 00:17:39 testing MailScanner[11609]: MailScanner E-Mail Virus Scanner version 4.54.6 starting...
Jun 22 00:17:39 testing MailScanner[11609]: Read 746 hostnames from the phishing whitelist
Jun 22 00:17:40 testing MailScanner[11609]: Using SpamAssassin results cache
Jun 22 00:17:40 testing MailScanner[11609]: Connected to SpamAssassin cache database
Jun 22 00:17:40 testing MailScanner[11609]: Enabling SpamAssassin auto-whitelist functionality...
Jun 22 00:17:40 testing MailScanner[11609]: Using locktype = posix
Jun 22 00:17:40 testing MailScanner[11609]: Creating hardcoded struct_flock subroutine for linux (Linux-type)
Jun 22 00:17:50 testing MailScanner[11610]: MailScanner E-Mail Virus Scanner version 4.54.6 starting...
 
Last edited:
Put MailScanner into debug mode and when you are running it check to see if there are any other mail processes running..

I don't know how you set this up, so I can't be of that much help
 
How do I run in debug mode?

Uhm I followed this guide, using latest mailscanner.
I did not had to install spamassassin, because it was already installed.
Then I installed clamav, (./configure / make / make install )
After that I began to install MailScanner.
( ./install.sh / chown / edited the files etc etc )
 
I just found this

Jun 22 00:35:30 testing MailScanner[23385]: New Batch: Scanning 1 messages, 1637 bytes
Jun 22 00:35:30 testing MailScanner[23385]: Virus and Content Scanning: Starting
Jun 22 00:35:31 testing MailScanner[23385]: Uninfected: Delivered 1 messages
Jun 22 00:35:31 testing MailScanner[23385]: Batch (1 message) processed in 1.16 seconds


but i didnt get it in my inbox


arghhh this is giving me an headache :mad:


//edit 1
--debug
In Debugging mode, not forking...
config: could not find userprefs file

--lint
Read 746 hostnames from the phishing whitelist
MailScanner setting GID to (12)
MailScanner setting UID to (8)
Checking for SpamAssassin errors (if you use it)...
Using SpamAssassin results cache
Connected to SpamAssassin cache database
config: could not find userprefs file
config: SpamAssassin failed to parse line, "/usr/bin/pyzor" is not valid for "pyzor_path", skipping: pyzor_path /usr/bin/pyzor
config: failed to parse line, skipping: dcc_path /usr/local/bin/dccproc
SpamAssassin reported an error.

MailScanner.conf says "Virus Scanners = clamav"
Found these virus scanners installed: clamav


//edit 2
Outgoing mail is fixed, but incoming doesnt work -.-
 
Last edited:
Hello All!!!

I am having Centos 4.3 box. Exim 4.60 is not listening after i install MailScanner-4.54. I can see MailScanner works fine no error while stoping and starting :-

[root@host~]# service MailScanner restart
Shutting down MailScanner daemons:
MailScanner: [ OK ]
[ OK ] incoming exim: [ OK ]
outgoing exim: [ OK ]
Starting MailScanner daemons:
incoming exim: [ OK ]
outgoing exim: [ OK ]
MailScanner: [ OK ]

And i f check the log for /var/log/exim/mainlog its states as below:-
-----------------
[root@host~]# tail -f /var/log/exim/mainlog
2006-06-22 09:23:45 1FtAkv-0003Wa-Tv Spool file 1FtAkv-0003Wa-Tv-D not found
0004Xc-1o-D not found
2006-06-22 10:03:13 1FtK9a-0004aZ-9q Spool file 1FtK9a-0004aZ-9q-D not found
2006-06-22 11:03:00 exim 4.60 daemon started: pid=17825, -q15m, not listening for SMTP
2006-06-22 11:03:16 exim 4.60 daemon started: pid=17900, -q15m, not listening for SMTP
2006-06-22 11:11:38 exim 4.60 daemon started: pid=18159, -q15m, not listening for SMTP
2006-06-22 11:12:46 1FtLEp-0004jM-Je Spool file 1FtLEp-0004jM-Je-D not found
-----------------

Here is maillog (var/log/maillog)
======================
[root@host~]# tail -f /var/log/maillog
Jun 22 11:12:24 host MailScanner[18187]: Creating hardcoded struct_flock subroutine for linux (Linux-type)
Jun 22 11:12:36 host MailScanner[18187]: New Batch: Scanning 1 messages, 1787 bytes
Jun 22 11:12:45 host MailScanner[18187]: Virus and Content Scanning: Starting
Jun 22 11:12:46 host MailScanner[18187]: Uninfected: Delivered 1 messages
Jun 22 11:12:46 host MailScanner[18187]: Batch (1 message) processed in 10.45 seconds
Jun 22 11:23:39 host MailScanner[18182]: New Batch: Scanning 1 messages, 4391 bytes
Jun 22 11:23:40 host MailScanner[18182]: Spam Checks: Found 1 spam messages
Jun 22 11:23:40 host MailScanner[18182]: Virus and Content Scanning: Starting
Jun 22 11:23:41 host MailScanner[18182]: Uninfected: Delivered 1 messages
Jun 22 11:23:41 host MailScanner[18182]: Batch (1 message) processed in 1.58 seconds
======================

could any 1 assist me what's wrong? why is it not listening for SMTP???
 
What do you get when you enter (in the shell):

ps waux | grep "exim -bd"

???

Jeff
 
Back
Top