Sunday, October 7, 2007

Error while creating mbox spool file

Issue: "error while creating mbox spool file"
If exim and spamd both fails constantly on cpanel server:

Resolution:

check the exim panic logs at

# tail -f /var/log/exim_paniclog

Also try out the following scripts :

# /scripts/eximup --force
# /scripts/perlinstaller --force Mail::SpamAssassin
# /scripts/autorepair spamd_dbm_fix
# /scripts/fixspamassassinfailedupdate


Also check the available disk space and available inodes on the partition holding /var

# df -h
# df -hi


If you are receiving the errors like

2007-09-12 12:50:00 1IVPnE-00085R-86 failed to open scan directory /var/spool/exim/scan/scan/1IVPnE-00085R-86: Too many links
2007-09-12 12:50:00 1IVPnE-00085R-86 spam acl condition: error while creating mbox spool file
2007-09-12 12:50:00 1IVPnE-00085R-86 failed to open scan directory /var/spool/exim/scan/scan/1IVPnE-00085R-86: Too many links

2007-10-06 17:01:41 1IeHiN-0005Nf-UI failed to open scan directory /var/spool/exim/scan/scan/1IeHiN-0005Nf-UI: Too many links
2007-10-06 17:01:41 1IeHiN-0005Nf-UI malware acl condition: error while creating mbox spool file
2007-10-06 17:01:41 1IeHiN-0005Nf-UI H=(<5) [] F=<> temporarily rejected after DATA
2007-10-06 17:01:41 1IeHiN-0005Ng-UO failed to open scan directory /var/spool/exim/scan/scan/1IeHiN-0005Ng-UO: Too many links


# cd /var/spool/exim/scan

# ls -alt | wc


If you've got a real high number (like 32000) then that might be a problem - for a few reasons -
(1) filesystem may only support x # of directories,
(2) something else going wrong causing too many directories to remain there even after processing.


The possible fix for this issue:

Following error occurred due to scan directory crossed the size limit

2007-10-06 05:05:50 1Ie6Xe-00042f-9B failed to open scan directory /var/spool/exim/scan/scan/1Ie6Xe-00042f-9B: Too many links
2007-10-06 05:05:50 1Ie6Xe-00042t-5y failed to open scan directory /var/spool/exim/scan/scan/1Ie6Xe-00042t-5y: Too many links


Solution:

Empty the folder /var/spool/exim/scan You can empty the large folder using following command.

# ls -l | xargs rm -rf