Cyrus - can't create user mailbox

Stephen Liu satimis at yahoo.com
Mon Jun 9 21:55:56 EDT 2008


--- Jens Hoffrichter <jens.hoffrichter at gmail.com> wrote:

> > $ cat /etc/postfix/master.cf | grep smtp
> > smtp      inet  n       -       -       -       -       smtpd
> >
> > smtp      unix  -       -       -       -       -       smtp
> > relay     unix  -       -       -       -       -       smtp
> > #       -o smtp_helo_timeout=5 -o smtp_connect_timeout=5
> > bsmtp     unix  -       n       n       -       -       pipe
> >  flags=Fq. user=bsmtp argv=/usr/lib/bsmtp/bsmtp -t$nexthop
> -f$sender
> > $recipient
> > * end *
> >
> > There are only 2 lines there with smtp in the beginning.
> From this snippet you don't see if chroot is enabled by default - the
> default is denoted by the -, and documented in the line directly
> before the beginning of the transports. But as I know Debian and
> Ubuntu, they have probably activated chroot.
> 
> > $ sudo nano /etc/cyrus.conf
> >
> > change both lines.
> >
> > changing;
> > lmtpunix        cmd="lmtpd" listen="/var/run/cyrus/socket/lmtp"
> > prefork=0 maxchild=20
> >
> > as;
> > lmtpunix        cmd="lmtpd"
> > listen="/var/spool/postfix/var/run/cyrus/socket/lmtp" prefork=0
> > maxchild=20
> >
> >
> > changing;
> > notify          cmd="notifyd" listen="/var/run/cyrus/socket/notify"
> > proto="udp" prefork=1
> >
> > as;
> > notify          cmd="notifyd"
> > listen="/var/spool/postfix/var/run/cyrus/socket/notify" proto="udp"
> > prefork=1
> I guess you won't need to change this line, as this is independent
> from postfix.
> 
> > Jun 10 00:36:30 lampserver postfix/smtpd[4955]: D21EA87820E:
> > client=ti-out-0910.google.com[209.85.142.187]
> > Jun 10 00:36:30 lampserver postfix/cleanup[4956]: D21EA87820E:
> >
>
message-id=<ca46cd50806090936n8e4c831yc70288dbe5bc865b at mail.gmail.com>
> > Jun 10 00:36:30 lampserver postfix/qmgr[4188]: D21EA87820E:
> > from=<satimisliu at gmail.com>, size=1842, nrcpt=1 (queue active)
> > Jun 10 00:36:30 lampserver postfix/lmtp[4958]: D21EA87820E:
> > to=<satimiscyrus at satimis.com>, relay=none, delay=0, status=deferred
> > (connect to /var/run/lmtp[/var/run/lmtp]: No such file or
> directory)
> As you see here, it tries to connect to the socket "/var/run/lmtp",
> but the cyrus default was /var/run/cyrus/socket/lmtp, or the postfix
> chroot equivalent.
> 
> So EITHER you change the delivery socket in postfix (which I
> currently
> don't know how to do, as I use a different delivery approach on my
> postfix server - and a different IMAP server ;) ), or you try either
> /var/run/postfix/var/run/lmtp or /var/run/lmtp in the lmtpunix line
> in
> cyrus.conf
> 
> I hope that helps :)
> 
> Regards,
> Jens


Hi Jens, 


Perform another test according to your advice.  But it still fails. 
Mail can't be delivered to the Server.


$ tail /var/log/mail.log 
Jun 10 09:09:14 lampserver cyrus/ctl_cyrusdb[4896]: done checkpointing
cyrus databases
Jun 10 09:09:14 lampserver cyrus/master[4892]: process 4896 exited,
status 0
Jun 10 09:10:16 lampserver postfix/master[4733]: terminating on signal
15
Jun 10 09:10:16 lampserver postfix/master[4978]: daemon started --
version 2.2.10, configuration /etc/postfix
Jun 10 09:14:10 lampserver postfix/smtpd[4982]: connect from
ti-out-0910.google.com[209.85.142.184]
Jun 10 09:14:10 lampserver postfix/smtpd[4982]: 40275878215:
client=ti-out-0910.google.com[209.85.142.184]
Jun 10 09:14:10 lampserver postfix/cleanup[4987]: 40275878215:
message-id=<ca46cd50806091814x11e3525fu4850ebad8819222c at mail.gmail.com>
Jun 10 09:14:10 lampserver postfix/qmgr[4981]: 40275878215:
from=<satimisliu at gmail.com>, size=1842, nrcpt=1 (queue active)
Jun 10 09:14:10 lampserver postfix/lmtp[4989]: 40275878215:
to=<satimiscyrus at satimis.com>, relay=none, delay=0, status=deferred
(connect to
/var/run/cyrus/socket/lmtp[/var/run/cyrus/socket/lmtp]: Permission
denied)
Jun 10 09:14:40 lampserver postfix/smtpd[4982]: disconnect from
ti-out-0910.google.com[209.85.142.184]
* end *


However based on following complaint;
Jun 10 09:14:10 lampserver postfix/lmtp[4989]: 40275878215:
to=<satimiscyrus at satimis.com>, relay=none, delay=0, status=deferred
(connect to
/var/run/cyrus/socket/lmtp[/var/run/cyrus/socket/lmtp]: Permission
denied)


I found following thread on googling;

postfix+cyrus21
http://unixadmintalk.com/f11/postfix-cyrus21-89421/


According to their suggest I found follows;

$ sudo ls -l /var/run/cyrus/socket
total 0
srwxrwxrwx 1 root root 0 2008-06-10 06:55 lmtp
srwxrwxrwx 1 root root 0 2008-06-10 09:09 notify


$ sudo ls -ld /var/run/cyrus/socket
drwxr-x--- 2 cyrus mail 80 2008-06-10 09:09 /var/run/cyrus/socket


$ id postfix
uid=107(postfix) gid=111(postfix) groups=111(postfix)


$ sudo adduser postfix lmtp
adduser: The group `lmtp' does not exist.


What shall I do?  

Creating the group 'lmtp' ?


If YES, what specific command I have to run not to jeopardize other
settings.


If still fails how to revert back to its original state?  TIA


B.R.
Stephen L

Send instant messages to your online friends http://uk.messenger.yahoo.com 


More information about the Info-cyrus mailing list