View Single Post
Old 10th April 2013, 06:39
markc markc is offline
Join Date: Dec 2012
Posts: 57
Thanks: 6
Thanked 9 Times in 9 Posts
Default Converting a server from dovecot to courier-imap

Ubuntu 64bit 13.04 with ISPConfig

I am attempting to convert and already setup server from dovecot to courier-imap so I can use maildrop for delivery. I've removed dovecot and /etc/dovecot and re-run update.php a few times and some messages have been delivered but now I am bumping into this one... note the/var/vmail path is completely wrong, this users real path is /var/vmail/ where I have moved the original Maildir/{cur,new,tmp} up a level.

Apr 10 13:08:14 hp postfix/pipe[5838]: DA29D10065D: to=<>, relay=maildrop, delay=0.05, delays=0.01/0.01/0/0.03, dsn=4.3.0, status=deferred (temporary failure. Command output: /usr/bin/maildrop.orig: Unable to create a dot-lock at /var/vmail/ )

For some reason the SENDERS email address is being inserted into the path. The /usr/bin/maildrop is currently a shell script for debugging, it is...

~ cat /usr/bin/maildrop
(echo $*; id ; env) | logger -p
/usr/bin/maildrop.orig $*

~ ll /usr/bin/maildrop*
-rwxr-xr-x 1 root root       78 Apr 10 13:07 /usr/bin/maildrop
-rwsr-xr-x 1 root daemon 196000 Jan 23 23:32 /usr/bin/maildrop.orig

Apr 10 13:15:05 hp logger: -d vmail markc
Apr 10 13:15:05 hp logger: uid=5000(vmail) gid=5000(vmail) groups=5000(vmail)
Apr 10 13:15:05 hp logger: MAIL_CONFIG=/etc/postfix
Apr 10 13:15:05 hp logger: PATH=/usr/bin:/bin
Apr 10 13:15:05 hp logger: PWD=/var/spool/postfix
Apr 10 13:15:05 hp logger: LANG=C
Apr 10 13:15:05 hp logger: SHLVL=1
Apr 10 13:15:05 hp logger: _=/usr/bin/env
Apr 10 13:15:05 hp maildrop[6015]: Unable to create a dot-lock at /var/vmail/
Anyone have a suggestion what going on here and how to remove the senders address from the path?

I did discover I cannot use /etc/courier/maildroprc as a global filter because postfix does not provide the env variables it would normally need so I will have to use a .filter or .mailfilter in each users /var/vmail virtural maildir.

My objective it to enable Dspam filtering (via maildrop) because the default Spamassassin rules just suck, barely 80% effective. Perhaps I should investigate how to improve amavis/spamassassin but I figure there may be less pain installing Dspam which I know can work 99% effectively once trained.

Also FWIW, /etc/postfix/ still has a reference to dovecot even after it's removed and I've run the update.php script...

maildrop  unix  -       n       n       -       -       pipe
  flags=DRhu user=vmail argv=/usr/bin/maildrop -d vmail ${extension} ${recipient} ${user} ${nexthop} ${sender}
[... further down ...]
dovecot   unix  -       n       n       -       -       pipe
  flags=DROhu user=vmail:vmail argv=/usr/lib/dovecot/deliver -f ${sender} -d ${user}@${nexthop}
Reply With Quote
Sponsored Links