OK. I have tried setting:
virtual_alias_maps = $alias_maps
And in /etc/aliases I now have:
# See man 5 aliases for format
postmaster: root
clamav: root
# Webmin: Redirect root to nick
root: nick@mydomain.com
And the mail queue won't clear:
2024-10-26T18:04:00.890009+01:00 mail-www dovecot: lmtp(1404363):
Error: lmtp-server: conn unix:pid=1404358,uid=102 [1]: rcpt
root@mydomain.com: Failed to lookup user root@mydomain.com: Invalid
settings in userdb: userdb returned 0 as uid
2024-10-26T18:04:00.892965+01:00 mail-www postfix/lmtp[1404358]:
4426B7062BF: to=<root@mydomain.com>,
relay=mail.howitts.co.uk[private/dovecot-lmtp], delay=7518,
delays=7517/0.11/0.07/0, dsn=4.3.0, status=deferred (host
mail.howitts.co.uk[private/dovecot-lmtp] said: 451 4.3.0
<root@mydomain.com> Temporary internal error (in reply to RCPT TO
command))
Am I too late for the destination address to get rewritten, so should I just purge the mailq and get some new test messages?
On 26/10/2024 17:51, Noel J via dovecot wrote:
Post aliases are implemented in the local delivery agent. To use lmtp, put your aliases in virtual_alias_maps
Postfix does not expand aliases with sendmail -bv, just reports if the address will be accepted.
On Sat, Oct 26, 2024 at 11:47 AM Benny Pedersen via dovecot < dovecot@dovecot.org> wrote:
Nick Howitt via dovecot skrev den 2024-10-26 18:36:
On 26/10/2024 17:22, Benny Pedersen via dovecot wrote:
I am pretty new to Dovecot and totally new to LMTP. I have normal delivery working but I am struggling with aliases. In my mail queue I am seeing things like:
But in my /etc/aliases, I am aliasing clamav to nick and nick@mydomain.com is a valid mail box that can receive normal mail.
The corresponding line in the mail log is:
2024-10-26T14:55:56.385500+01:00 mail-www dovecot:
lmtp(1371485): Error: lmtp-server: conn unix:pid=1371484,uid=102 [1]: rcpt clamav@mydomain.com: Failed to initialize user: Mail access for users with UID 107 not permitted (see first_valid_uid in config file, uid from userdb lookup).
How do I get round this issue? I can drop the minimum UID to 0, but then all system users are deemed valid for mail which is not true. None of them are. I think it is more common to have your MTA postfix/sendmail do the translation to aliases, so before you deliver it to lmtp. Maybe test if your MTA is indeed sending the alias
Marc via dovecot skrev den 2024-10-26 16:34: this log snipped above is not mta issues at all
i will take the possible problem later when dovecot does not say first_ Hi, I get:
root@mail-www:~# doveconf -n | grep first_valid_ first_valid_uid = 1000
set it to 100 then, not 1000
107 is lower then 1000, no ?
root@mail-www:~# doveconf -n | grep last_valid_ root@mail-www:~#
why is last not set ?
Is this not valid? My first proper user is user 1000. All users below that are system users and should never receive emails as themselves and need to be aliased to a proper user. Or have I misunderstood. in that case its ok to have 1000 as first_
do you change uid gid in userdb ?
TBH, I would have thought postfix may have rewritten the RCPT TO before it sent on to LMTP but that is said without knowledge.
At the same time I have received in my proper mailbox an email from root to clamav so I am massively puzzled. solve doveconf first :)
dovecot mailing list --dovecot@dovecot.org To unsubscribe send an email todovecot-leave@dovecot.org
dovecot mailing list --dovecot@dovecot.org To unsubscribe send an email todovecot-leave@dovecot.org
dovecot mailing list --dovecot@dovecot.org To unsubscribe send an email todovecot-leave@dovecot.org