basically tech

114 Debian lenny MailScanner woes

Friday 3rd April, 2009

I fixed this after a week or so, but I forget how I did it. :-( I don't use MailScanner anymore. It's a fine product, but I find it to be overkill.
Rob. April 2015.

I ran a system upgrade (from etch to lenny) on one of my Debian servers today. There seem to be lots of people who have their own ideas about how to go about this, which is fair enough, there's more than one way to climb the mountain. In fact I deviated (very) slightly from the steps kindly provided in the official upgrade instructions.

I double-checked the official issues to be aware of for lenny. Nothing about MailScanner!

This is always a nervous time for me. :) Everything seemed to be going well:

  • I updated /etc/apt/sources.list,
  • ran aptitude update,
  • ran aptitude install apt dpkg aptitude, accepting the solution offered when there were dependency problems,
  • then ran aptitude upgrade,
  • then aptitude dist-upgrade,
  • and finally, after some nervous double-checking, found I had to manually run aptitude install linux-image-2.6-686.

A final aptitude dist-upgrade produced no held packages, apparently confirming that all was well.

A rather long reboot later revealed that MailScanner was not running, so mail was not being checked or delivered. Everything else seemed to be fine though.

It seems that MailScanner has been removed from lenny for security reasons. This particular problem appears to have been fixed in version mailscanner/4.74.16-1. At the time of writing, this is the version currently available in squeeze (testing).

I needed a quick fix. I didn't want to mess about with APT pinning, the idea was just to get this server up to the latest "stable". Luckily, the version of MailScanner offered in squeeze only had one extra dependency, libole-storage-lite-perl. All other deps were already installed at the correct/higher version, so it was a matter of installing libole-storage-lite-perl, then downloading and installing mailscanner_4.74.16-1_all.deb, which was completed with a little grumbling.

Running MailScanner --lint allowed me to clear up a couple of minor configuration issues, and MailScanner -V showed required versions of dependencies were okay. There is still a "problem" - when MailScanner is started, it displays an error message:

# /etc/init.d/mailscanner start
Could not create SpamAssassin temporary directory , No such file or directory at /usr/share/MailScanner//MailScanner/ line 80.

This seems spurious, as /var/spool/MailScanner/incoming/SpamAssassin-Temp is definitely present. Does anyone know why this error comes up?