Amavisd-new init script problem

Carl on jan 4th 2012 08:43 am | Tags: ,

Recently I had to reinstall my mailserver, due to the usual f…-up one tends to make as root. After several hours of configuring packages (debian testing) I finally had it up and running. Unfortunately, one of my cronjobs failed. An error restarting amavis after the update of spamassassin. Luckilly, someone already had the solution for the failing init-script.
If you get the following error restarting/stopping amavis:

Stopping amavisd: (not running).
Starting amavisd: The amavisd daemon is already running, PID: [10966] (failed).

Check your /etc/init.d/amavis for the following line:
STOP="--stop --quiet --pidfile $PIDFILE --name ${DAEMONNAME}"
Comment it out like:
# STOP="--stop --quiet --pidfile $PIDFILE --name ${DAEMONNAME}"
and put the next line in:
STOP="--stop --quiet --pidfile $PIDFILE"

Short and sweet: your system is probably running amavisd-new as user amavis or amavisd instead of amavisd-new, as defined in the top of the file. What’s in a DAEMONNAME …
If that doesn’t work … you’ll be in for a nice google-session

Filed in Mail server

Comments are closed.