postfix ignores /etc/aliases
I want postfix to sent e-mails to root or postmaster to another e-mail address.
So I have the following in /etc/aliases :
root@ secumailtest:/var/log# more /etc/aliases
# See man 5 aliases for format
postmaster: francois.lagrange@ securendo.com
abuse: francois.lagrange@ securendo.com
root: francois.lagrange@ securendo.com
Still, notifications to root are not sent to francois.lagrange@ securendo.com, but rather to root@ cesinge.com. cesinge.com is the domain of the server, the only entry in the mysql mail database.
mysql> select * from domains;
| domain |
| cesinge.com |
1 row in set (0.00 sec)
Postfix is otherwise configured to use /etc/aliases.
root@secumailtest:/var/log# postconf -n
alias_database = hash:/etc/aliases
alias_maps = hash:/etc/aliases
append_dot_mydomain = no
biff = no
So why is postfix ignoring the aliases and sending these notifications to root@ local domain instead of the defined alias?
I did a newaliases.
Note: I added a space after the '@' because the site's editor stubbornly converts them to clickable e-mail addresses...
I'm also running Debian. Your /etc/aliases looks very different from mine.
This is /etc/hosts. There's not much in it.
secumailtest - that's all.
It seems that Postfix or SpamAssassin just ignore /etc/aliases (and also the postfix forwardings table). I see that all notification mails are always sent to and from firstname.lastname@example.org. I assume that root is because that's the user running postfix and spamassassin. And I guess @cesinge.com because it's the DNS domain to which the machine belongs?
What bothers me is that I don't have a clear understanding of how this works. Then I could consider tweaking something to force these mails to a mailbox that I read.
Testing this further, I replaced all the .cesinge.com in the hosts file by .securendo.com, to see if these would be used when system root mails are sent.
I then sent a mail to just root: mail root
The mail cannot be delivered, because the machine, secumailtest, cannot be resolved (no A record) in that other domain securendo.com (normal).
While the mail to root itself fails, the system still manages to send me an undelivered mail notification email@example.com! So I have to conclude that this @cesinge.com is somehow forced in there for system generated messages. I does not come from the host file. It ignores any modification from the aliases or forwardings. From where does this adres firstname.lastname@example.org come, then? <puzzled>
|All times are GMT -5. The time now is 11:00 AM.|