如果我发送电子邮件
echo "test" | mail -s "Test" myuser
echo "test" | mail -s "Test" root
/var/log/mail.log 包含
Apr 7 16:30:30 ScotLX postfix/pickup[247827]: 46871740CE7: uid=1000 from=<myuser@ScotLX>
Apr 7 16:30:30 ScotLX postfix/cleanup[249740]: 46871740CE7: message-id=<[email protected]>
Apr 7 16:30:30 ScotLX postfix/qmgr[247828]: 46871740CE7: from=<myuser@ScotLX>, size=325, nrcpt=1 (queue active)
Apr 7 16:30:30 ScotLX postfix/local[249742]: 46871740CE7: to=<myuser@ScotLX>, relay=local, delay=0.02, delays=0.01/0/0/0, dsn=2.0.0, status=sent (delivered to command: procmail -a "$EXTENSION")
Apr 7 16:30:30 ScotLX postfix/qmgr[247828]: 46871740CE7: removed
Apr 7 16:30:40 ScotLX postfix/pickup[247827]: 801EE740CE7: uid=1000 from=<myuser@ScotLX>
Apr 7 16:30:40 ScotLX postfix/cleanup[249740]: 801EE740CE7: message-id=<[email protected]>
Apr 7 16:30:40 ScotLX postfix/qmgr[247828]: 801EE740CE7: from=<myuser@ScotLX>, size=325, nrcpt=1 (queue active)
Apr 7 16:30:40 ScotLX postfix/local[249742]: 801EE740CE7: to=<root@ScotLX>, relay=local, delay=0.01, delays=0/0/0/0, dsn=2.0.0, status=sent (delivered to command: procmail -a "$EXTENSION")
Apr 7 16:30:40 ScotLX postfix/qmgr[247828]: 801EE740CE7: removed
在我看来没问题,但 ls -la /var/mail/ 返回
drwxrwsr-x 2 root mail 4096 Apr 7 16:35 .
drwxr-xr-x 11 root root 4096 Jun 24 2020 ..
-rw-r----- 1 myuser mail 169303 Apr 7 16:35 myuser
-rw-r----- 1 root mail 0 Apr 5 19:17 root
和“sudo mail”返回
No mail for root
/etc/hosts 包含
127.0.0.1 localhost
127.0.1.1 ScotLX ScotLX.fritz.box
和 /etc/mailname 包含
127.0.0.1 localhost
127.0.1.1 ScotLX ScotLX.fritz.box
/etc/aliases 包含
postmaster: root
root 的电子邮件到哪里去了?谁能指出我解决方案的方向?