15.6.4 To Address Mail over a BNU or UUCP Link

15.7 Storing Mail

Mail is stored in different ways depending on specific situation as shown in +++XRef id=25594+++. The mail program uses the following type of mailboxes or folders:

System Mailbox

This resides in /var/spool/mail directory and each system mailbox is named by the user ID associated with it. For example, if the user ID is smith, the system mailbox is /var/spool/mail/smith. When the mail arrives for any user ID, it is placed in the respective system mailbox. The shell checks for the new mail and issues the following message when the user logs in: YOU HAVE NEW MAIL
Personal Mailbox

Each user has a personal mailbox. When the mail is read using the mail command by the user, and if it is not saved in a file or deleted, it is written to user's personal mailbox, $HOME/mbox ($HOME is the default login directory). For a user ID smith, the personal mailbox is /home/smith/mbox.
dead.letter File

If the user interrupts the message being created to complete some other tasks, the system saves the incomplete message in the dead.letter file in the user's home directory ($HOME). For a user ID smith, /home/smith/dead.letter is the dead.letter file.

To save message in an organized fashion, users can use folders. Messages can be put into a user's personal folder from system mailbox or personal mailbox as shown in +++XRef id=25594+++.

The mail command can be used with various flags as shown below:

Displays the system mailbox.
mail -f
Displays your personal mailbox (mbox).
mail -f+folder
Displays a mail folder.
mail user@address
Addresses a message to the specified user.

Figure 143: Message Path for Mail

15.8 Mail Administrator's Reference