Discussion:
postfix and lmtp: how to make aliases work
(too old to reply)
Erik Steffl
2004-08-06 06:57:52 UTC
Permalink
what do I need to do to make the aliases work with postfix when lmtp
is used?

do I need virtual aliases or aliases or? I'd appreciate some pointers
to docs, I have search this list and read some posts that seemed similar
(and followed the links to docs) but can't figure out what's what.

I tried "www-data: erik" in /etc/aliases and "www-data erik" in
/etc/postfix/virtual (and updating *.db and restarting postfix) but
looks like postfix is still trying to deliver to www-data and cyrus
complains:

Aug 2 13:00:01 jojda postfix/lmtp[6880]: 224D2C80D0:
to=<www-***@zasran.com>,
relay=/var/run/cyrus/socket/lmtp[/var/run/cyrus/socket/lmtp], delay=0,
status=bounced (host /var/run/cyrus/socket/lmtp
[/var/run/cyrus/socket/lmtp] said: 550-Mailbox unknown. Either there is
no mailbox associated with this 550-name or you do not have
authorization to see it. 550 5.1.1 User unknown (in reply to RCPT
TO command))

Here are the details of my setup:

debian unstable
postfix 2.1.4 (debian package)
cyrus 2.1.16 (debian package

relevant (as far as I can tell) config lines:

/etc/postfix/main.cf:
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
mailbox_transport = lmtp

/etc/postfix/transport:
localhost lmtp:unix:/var/run/cyrus/socket/lmtp
zasran.com lmtp:unix:/var/run/cyrus/socket/lmtp
jojda.zasran.com lmtp:unix:/var/run/cyrus/socket/lmtp
localhost.zasran.com lmtp:unix:/var/run/cyrus/socket/lmtp

/etc/postfix/master.cf
lmtp unix - - n - - lmtp

/etc/cyrus.conf:
lmtpunix cmd="lmtpd" listen="/var/run/cyrus/socket/lmtp"
prefork=0 maxchild=20

/etc/imapd.conf:
lmtpsocket: /var/run/cyrus/socket/lmtp

------------ end of config quotes -----------

any pointers?

TIA

erik
Magnus Bäck
2004-08-06 07:42:38 UTC
Permalink
On Friday, August 06, 2004 at 03:20 CEST,
Post by Erik Steffl
what do I need to do to make the aliases work with postfix when lmtp
is used?
[...]
Post by Erik Steffl
alias_maps =3D hash:/etc/aliases
alias_database =3D hash:/etc/aliases
mailbox_transport =3D lmtp
=20
localhost lmtp:unix:/var/run/cyrus/socket/lmtp
zasran.com lmtp:unix:/var/run/cyrus/socket/lmtp
jojda.zasran.com lmtp:unix:/var/run/cyrus/socket/lmtp
localhost.zasran.com lmtp:unix:/var/run/cyrus/socket/lmtp
Local aliases are expanded by local(8). By using transport_maps to
direct the mail directly to the lmtp transport, the mail never reaches
local(8). You do not need the transport maps since you have defined
mailbox_transport.

[...]

--=20
Magnus B=E4ck
***@dsek.lth.se
Erik Steffl
2004-08-07 00:37:42 UTC
Permalink
Post by Magnus Bäck
On Friday, August 06, 2004 at 03:20 CEST,
=20
=20
Post by Erik Steffl
what do I need to do to make the aliases work with postfix when lmtp
is used?
=20
=20
[...]
=20
=20
Post by Erik Steffl
alias_maps =3D hash:/etc/aliases
alias_database =3D hash:/etc/aliases
mailbox_transport =3D lmtp
localhost lmtp:unix:/var/run/cyrus/socket/lmtp
zasran.com lmtp:unix:/var/run/cyrus/socket/lmtp
jojda.zasran.com lmtp:unix:/var/run/cyrus/socket/lmtp
localhost.zasran.com lmtp:unix:/var/run/cyrus/socket/lmtp
=20
=20
Local aliases are expanded by local(8). By using transport_maps to
direct the mail directly to the lmtp transport, the mail never reaches
local(8). You do not need the transport maps since you have defined
mailbox_transport.
thanks, that helps, however:

which aliases can be used if mail_transport is set to lmtp? None?=20
Should, in this configuration, the aliases be implemented on cyrus side?

Or should I use lmtp in some other way?

erik

Loading...