Archive for the ‘Exim’ Category


Step1:
Check mail service is up or not /etc/init.d/exim status
Step2:
Check by send a test mail from test mail a/c, tail -f /var/log/main_log (For dynamic checking )
Step3:
Check the Ip listed in RBL (Search the key word ‘spam database’ in Google)
Step4:
Check by disabling the firewall , as it may be blocking the port 25
Step5:
Check it by telnet to 25
Step6:
Check the error by sending a test mail from the account,

if you are getting any error regarding   MX priority   check the domain is listed

/etc/localdomains (if the domain is using the server MX) or

/etc/remotedomains(if the domain is using remote server MX)
Advertisements

To find out the Spamming

Posted: February 3, 2013 in Exim

Use the below Script:

grep “cwd=” /var/log/exim_mainlog|awk ‘{for(i=1;i<=10;i++){print $i}}’|sort|uniq -c|grep cwd|sort -n

0r

 

awk ‘{ if ($0 ~ “cwd” && $0 ~ “home”) {print $4} }’ /var/log/exim_mainlog | sort | uniq -c | sort -nk 1

Exim Queue clearing

Posted: February 3, 2013 in Exim

exim -bp | awk ‘/^ *[0-9]+[mhd]/{print “exim -Mrm ” $3}’ | bash


To check the number of messages in the queue:
#exim -bpc

To check the listing of the messages in the queue (time queued, size, message id, sender, recipient):
#exim -bp

To check the summary of messages in the queue (count, volume, oldest, newest, domain, and total):
#exim -bp| exiqsumm

To check the current status of Exim:
#exiwhat

To search the queue for messages from a specific sender:
#exigrep -f user@domainname.com

To search the queue for a specific recipient:
#exigrep -r user@domainname.com

To print the message id of the entire queue:
#exiqgrep -i

To remove a message from the queue:
#exim -Mrm <message id>

To Freeze a message:
#exim -Mf <message id>

To forcefully deliver a message:
#exim -M <message id>

To force a message to Freeze and bounce as “Canceled by Admin” :
#exim -Mg <message id>

To remove all frozen mails:
#exigrep -z -i | xargs exim -Mrm

To freeze all queued mail for a given sender:
#exiqgrep -i -f user@domain.com | xargs exim -Mf

To view a message body:
#exim -Mvb <message id>