Terminal: "you new have mail"

Discussion in 'macOS' started by Supp0rtLinux, May 30, 2014.

  1. Supp0rtLinux macrumors member

    Feb 28, 2008
    I recently re-used an old script and put it into cron. After testing a few things in the terminal, I saw "You have new mail". Typing in "mail" showed me a list (reminded me a lot of the old "pine" program from my earlier UNIX days). Since these trap errors in the crontab, I would actually like to see them for as long as the cron job is scheduled. Is there a way to forward them? I recall from long ago using a .vacation or .forward file or something like that, but assuming I used either to forward it to my gmail account, I would also need an internet connection, right? Or will it just queue up until I have a connection and then send a la sendmail? I use the default Mac Mail program... is it possible to read my "local" mail from Mac Mail? I also recall having this issue on Linux and doing something to have local system mail for root go to a real mailbox. But A) I don't recall what I did and B) it was on servers that always had internet connections so I could safely redirect system emails for root out to my work account. Can someone remind me the old school ways to resolve this and see the local emails?
  2. Supp0rtLinux thread starter macrumors member

    Feb 28, 2008
    I recalled that I used to fix this for root on Linux servers by editing /etc/aliases and then running 'newaliases'. However, this requires a 24x7 internet connection or the email(s) will queue up. So I guess I have 2 questions:

    1) is there any reason I couldn't use /etc/aliases to fix this on my Mac? I'm thinking something like:

    Open Terminal
    'sudo su -'
    'vi /etc/aliases' and add an entry for my account (ass: hole@gmail.com)

    2) since this would be internet connection dependent as well as dependent on the system being on (not always a guarantee on a laptop), is it possible to read the local mail file from Mac Mail? Or maybe from an alternative client like Thunderbird?
  3. HenryAZ macrumors 6502a


    Jan 9, 2010
    South Congress AZ
    Use mail :)

    Once you see the list, enter the message number.

    Aliases is likely /etc/postfix/aliases. Check in /etc/postfix/main.cf to confirm.

Share This Page