Previous Page | Next Page

  1. Introduction
  2. Abbreviated Boot
  3. The Boot Process
  4. Startup and Run Levels
  5. Initialization Scripts
  6. Runlevel Scripts
  7. Login Process
  8. Bash Shell
  9. Filesystems
  10. LILO, Kernel and Root Filesystem
  11. The Kernel
  12. Passwords, Users, Groups, and Quotas
  13. The Environment
  14. The /etc/sysconfig directory
  15. The /proc filesystem
  16. Process Control
  17. Devices
  18. Daemons Services
  19. Inetd and Network Services
  20. Programs and Libraries
  21. Security and PAM
  22. The printer services
  23. Mouse support with gpm
  24. Mail
  25. News
  26. UUCP
  27. LDAP
  28. NFS and RPC
  29. Samba, NetBIOS, WINS, nmbd
  30. Identd (auth)
  31. Telnet and FTP
  32. Apache web server
  33. DNS and named
  34. How X Works
  35. X Scripts
  36. Support for Text
  37. Keymapping for Programs
  38. Keycode Table
  39. Example Keymap File
  40. Terminfo Commands
  41. VT100 ESC sequences
  42. Kernel Revisited
  43. Configuration Files
  44. Credits

Linux Mail

Mail messages

RFC822 defines the structure of an internet mail header. A mail message consists of:

  1. Mail header
  2. Mail body

They are separated by a blank line. The header contains:

  1. Source address of the mail
  2. Destination address of the mail
  3. Subject line
  4. Date the mail was sent

The mail process

There are four types of programs used in the process of sending and receiving mail. They are:

  • MUA - Mail users agent. This is the program a user will use to type e-mail. It usually incorporates an editor for support. The user types the mail and it is passed to the sending MTA.
  • MTA - Mail transfer agent is used to pass mail from the sending machine to the receiving machine. There is a MTA program running on both the sending and receiving machine. Sendmail is a MTA.
  • LDA - Local delivery agent on the receiving machine receives the mail from its MTA. This program is usually procmail.
  • Mail notifier - This program notifies the recipient that they have mail. Normally this requires two programs, biff and comsat. Biff allows the administrator or user to turn on comsat service.

The MTA on both machines use the network SMTP (simple mail transfer protocol) to pass mail between them, usually on port 25.

The user's mailbox resides in "var/spool/mail/username".

Remote mail through ISPs over PPP

Mail delivered through an internet service provider (ISP) gets delivered to a mailbox on an ISP server machine. A remote mail protocol is used to support this type of mail. This is necessary because for the mail to get delivered, it must first go to a server machine at an ISP rather than directly to the receiving machine. There are two types of remote mail protocol.

  • POP3 (RFC 1939) - Currently most used.
  • IMAP (RFC 2060) - More powerful

A remote mail client program is required to use the POP3 or IMAP protocol for mail. Client capabilities are built into some MUA programs When you are using client POP mail services, you must poll the mail service to check for new mail. Most Linux versions come with the fetchmail program which will get your mail from the main mail server and put it into your mailbox on your local machine. Fetchmail will periodically poll your main mail server so you won't need to do int manually. Of course the mail transfer agent software such as sendmail must be set up in order to do this. To connect to remote mailboxes or mail servers, your system will need to support TCP/IP, uucp and/or serial connection ability such as PPP. This is dependant on the mechanism your system will use to connect to mail services.

Mailbox Formats

  • mbox - Mailbox format, puts each mailbox into a directory of files.
  • BABYL - An old mail system.
  • MMDF - The simplest. Older and crude.
  • MH - Mailbox format, puts each mailbox into a directory of files.
  • qmail

MUAs

  • Mutt - Similar to elm but with more commands and more configuration options.
  • Elm - A simple mail program. Metamail must be installed for elm to read MIME mail.
  • Mailx -
  • pine - Supports IMAP remote mail and is liked for new users.
  • metamail - Allows MIME support
  • mh - Mail handler.
  • deliver - file/process mail based on rules
  • procmail - file/process mail based on rules
  • majordomo - manages e-mail lists
  • mserv - provide files-by-mail
  • Netscape - Has POP3 and IMAP remote mail capability. Not highly recommended to be a MUA since that is not its speciality.
  • smail - Compose mail inside an emacs environment. There's a MTA also called smail. Don't confuse them.
  • rmail - Converts the mail inbox into BABYL format. Not recommended.
  • mush - Mail users shell for filtering and batch processing.

MTAs

  • qmail - It has high security, high speed, and ease of configuration.
  • sendmail - Sendmail is complicated for beginners but may not be very fast or secure.
  • smail - Smail is simpler than sendmail. It has good security. It is less efficient than sendmail when traffic volume is high.
  • exim - Has more features than smail, can block spam, and has reasonable security.
  • vmail

LDAs

  • procmail

Other Mail Programs

  • Fetchmail - Used to retrieve mail from the ISP mail server.
  • biff - Allows the comsat service to be turned on and off.
  • comsat - Notifies the user of new mail.