I running Linux Mint Debian Edition tracking testing and have started a cron job that will send something to the root mailbox. Mint has heirloom and exim4 installed. However, mail was getting nothing. I realized that in /etc/aliases, there was a line
root: mint
Since you can't log into the mint user (and /var/mail had no mint file), I commented out the root: mint line and did a:
/etc/init.d/exim4 restart
Now, mail is going to the user mail not root. Roots mail can be found in /var/mail/mail.
For some reason, it is not going to the root user. As root, I can
su mail
But this is inconvenient. I would like root's mail to go to root.
Can someone let me know how to have root's mail actually go to root's mailbox?
There is no /root/.forward file, either.
Thanks,
Narnie
---------- Post updated at 07:54 PM ---------- Previous update was at 12:21 AM ----------
I had done a:
grep -R mail /etc/exim4
And didn't see anything interesting.
I decided to do a:
grep -R root /etc/exim4
And got an interesting hit that fits. In /etc/exim4/conf.d/mmm_mail4root (which should have giving me a hint but was among many other files so I couldn't see the forest for the trees) I found this:
### router/mmm_mail4root
#################################
# deliver mail addressed to root to /var/mail/mail as user mail:mail
# if it was not redirected in /etc/aliases or by other means
# Exim cannot deliver as root since 4.24 (FIXED_NEVER_USERS)
mail4root:
debug_print = "R: mail4root for $local_part@$domain"
driver = redirect
domains = +local_domains
data = /var/mail/mail
file_transport = address_file
local_parts = root
user = mail
group = mail
That was the smoking gun I needed. Now I know what was going on.