mailx doesn't move examined mail to the user's mbox

Issues related to applications and software problems
Post Reply
h_fat
Posts: 48
Joined: 2007/04/13 17:23:48

mailx doesn't move examined mail to the user's mbox

Post by h_fat » 2011/08/05 11:27:43

I used to have the mail I read using the command "mail" moved automagically from /var/spool/mail to my mbox.
I don't think I confiured anything to get this behaviour on CentOS 4 and 5.
That was convenient because the mail I already checked out would not show up again when I typed "mail". But now every mail I ever received keeps showing up.

So how do you get mailx to move examined mail out of the way automatically in CentOS6?

keithwright
Posts: 16
Joined: 2011/08/01 18:53:57
Contact:

Re: mailx doesn't move examined mail to the user's mbox

Post by keithwright » 2011/08/16 18:08:08

After doing a bit of research, I came up with this solution:

Either create or add to the file in your home directory ~/.mailrc:

unset hold

h_fat
Posts: 48
Joined: 2007/04/13 17:23:48

Re: mailx doesn't move examined mail to the user's mbox

Post by h_fat » 2011/08/16 18:44:32

Thanks a lot Keith!

The problem was that the default /etc/mail.rc file seems to have changed between CentOS5 and CentOS6. Editing that file should fix the issue for all users.
That file states:
# Do not forward to mbox by default since this is likely to be
# irritating for most users today.

Really? Am I using an obsolete way to check mail?

Post Reply