When you log in to your system, you may see a notice that says “You have mail.” Someone has sent you a message or document by electronic mail (email). With email, you can compose a message at your terminal and send it to another user or list of users. You can also read any messages that others may have sent to you.
Email has several advantages over paper mail: it’s convenient if you’re already logged in, it’s delivered much more quickly, you can send it to any number of people almost as easily as to just one person, and the messages can be stored for later reference.
There are a lot of email programs for UNIX. Some UNIX systems have only an old, simple program named mail, which this book doesn’t cover. Most UNIX systems have a Berkeley program called Mail (with an uppercase “M”), mailx, or just mail. A popular menu-driven program that’s easier to learn is called pine. All programs’ basic principles are the same, though. We’ll cover the Berkeley mail program.
Your mail’s recipient doesn’t have to be logged in. The messages you send are stored in the recipient’s “mailbox,” a file deep in the UNIX filesystem (often located in the directory /usr/mail). Messages are kept there until the recipient logs in and decides to read them.
To send mail, give the address of each person you want to send a message to, like this:
mail address1 address2 ...
There are several kinds of addresses, too many to explain here. If you have questions, see one of the references ...