Presentation is loading. Please wait.

Presentation is loading. Please wait.

Linux Operations and Administration Chapter Twelve Configuring a Mail Server.

Similar presentations


Presentation on theme: "Linux Operations and Administration Chapter Twelve Configuring a Mail Server."— Presentation transcript:

1 Linux Operations and Administration Chapter Twelve Configuring a Mail Server

2 Linux Operations and Administration Objectives Identify key elements in the Linux e-mail architecture Describe how MTAs and MUAs are used in the Linux mail system Configure a mail server in YaST 2

3 Linux Operations and Administration Introduction to the Linux Mail System E-mail predates the Internet Today, e-mail is the most widely used Internet service OpenSUSE includes sophisticated e-mail programs –Such as Evolution and Kmail In Linux environment, e-mail is modular –A separate program is used to manage each function 3

4 Linux Operations and Administration Introduction to the Linux Mail System (cont’d.) 4 Figure 12-1 The Linux e-mail architecture © Cengage Learning 2013

5 Linux Operations and Administration Introduction to the Linux Mail System (cont’d.) Two main types of programs typically used on a Linux e-mail server: –Mail transfer agent (MTA) A program for receiving and delivering messages via Simple Mail Transfer Protocol In Linux, the MTA is often Postfix or sendmail –Mail user agent (MUA) An e-mail program that enables users to access their mailboxes for reading and sending electronic messages Examples: Evolution, KMail, command-line utility mail 5

6 Linux Operations and Administration Introduction to the Linux Mail System (cont’d.) Simple Mail Transfer Protocol (SMTP) –TCP/IP protocol that defines how e-mail is sent across the network Postfix –Default MTA in openSUSE 6

7 Linux Operations and Administration Introduction to the Linux Mail System (cont’d.) When MTA receives the message from MUA: –It determines whether the message is intended for a recipient on local domain or a recipient on another domain –If it’s on the local domain (example.com): MTA saves the message in local machine’s message store until the recipient reads it –For a recipient on another domain: MTA sends the message via SMTP to a remote MTA 7

8 Linux Operations and Administration Mail Transfer Agents MTA –Actual mail server –Responsible for: Receiving e-mails from local users Forwarding them to a local message store or a remote MTA Messages are transferred from the local message store to users via mail delivery agent (MDA) –Protocols which can be used for the transfer: Post Office Protocol (POP3) Internet Message Access Protocol (IMAP) 8

9 Linux Operations and Administration Mail Transfer Agents (cont’d.) Process of an MTA sending messages not belonging to local domain to a remote MTA isn’t automatic –Your domain’s DNS settings must be configured correctly –MTA needs to be able to establish a connection with the remote MTA 9

10 Linux Operations and Administration Sendmail –Most widely used MTA on UNIX/Linux systems –Not the preferred MTA on openSUSE Linux systems Postfix –Preferred MTA Ease of configuration, reliability, and security 10

11 Linux Operations and Administration Sendmail (cont’d.) In most organizations, employees need to send e- mail to many other domains You can edit Sendmail configuration file to: –Change the MTA behavior to allow multiple domains –Set rules, such as message filters Sendmail is a large program compared with other mail programs –It performs all MTA functions 11

12 Linux Operations and Administration Qmail Written by Dan Bernstein A fast, modular MTA Lightweight, secure, and reliable Designed with security and ease of use in mind Easier to configure –Such as allowing multiple domains Multiple modules handle qmail’s MTA functions –Each no bigger than 30 KB 12

13 Linux Operations and Administration Postfix Developed by Wietse Venema Default MTA package on openSUSE Linux systems Designed as a modular MTA Easier to configure, and more reliable and secure than sendmail Its modular design enhances security –Each module has its own set of permissions to follow the guideline of least privileges 13

14 Linux Operations and Administration Mail User Agents MUA –An e-mail program that enables users to send and read messages stored in their mailboxes In the Linux e-mail system: –Each user has a local mailbox –Local MTAs send messages to users’ mailboxes –MUA doesn’t actually receive messages It allows users to read messages that have already been placed in mailboxes 14

15 Linux Operations and Administration Mail User Agents (cont’d.) MUAs can store messages in one of two ways –Method 1 Messages are stored on users’ computers Frees up space on the server –Method 2 Messages are stored on the mail server Users can access them from any computer on the local domain 15

16 Linux Operations and Administration Mail User Agents (cont’d.) Table 12-1 –Describes four MUA packages included with openSUSE All these packages can use both methods of storing messages 16

17 Linux Operations and Administration Mail User Agents (cont’d.) 17 Table 12-1 Common openSUSE Linux MUAs

18 Linux Operations and Administration Using Mailx Example showing how to use mailx 18

19 Linux Operations and Administration Example: using mailx to read messages in mailbox: Using Mailx (cont’d.) 19

20 Linux Operations and Administration Using Mailx (cont’d.) Using mail command with no arguments displays all messages in mailbox Table 12-2 –Describes common commands that can be entered at the interactive prompt Activity 12-1: Using the Mailx Program –Send and display e-mails with the mailx program 20

21 Linux Operations and Administration Using Mailx (cont’d.) 21 Table 12-2 Common mailx commands

22 Linux Operations and Administration Mail Server Configuration Configuration procedures differ depending on the Linux distribution With openSUSE Linux, you can use a mail server configuration utility in YaST Control Center to perform configuration tasks, including: –Enable virus scanning –Define the type of network connection MTA uses to determine how e-mail is delivered –Configure an outbound mail server that’s used if you have a dial-up connection or aren’t connected to the Internet 22

23 Linux Operations and Administration Mail Server Configuration (cont’d.) –Define masquerade name for outgoing e-mail Useful for companies that prefer using a more professional name than actual mail server name –Configure incoming mail options, such as: Firewall settings Root mailbox account Whether to accept mail from remote servers Local alias accounts Virtual domains 23

24 Linux Operations and Administration The Mail Server Configuration Wizard Root user can start Mail Server Configuration Wizard yast2 mail command is used to start wizard Following sections describe the steps in wizard 24

25 Linux Operations and Administration General Settings Can use General Settings window to specify network connection type –Determines how MTA delivers messages –Default option is “Permanent” Selecting this option allows Postfix (the MTA) to send messages in real time as they’re created 25

26 Linux Operations and Administration General Settings (cont’d.) –Dial-up option For Linux machines that connect to the Internet via a dial-up connection Forces users to queue outbound mail server manually when they’re ready to send or receive messages Example: –To e-mail a user on a remote computer, you must use sendmail -q command after sending your message 26

27 Linux Operations and Administration General Settings (cont’d.) –“No connection” option For Linux machines that don’t have access to the Internet Users with this option can e-mail each other only on local machines Can also use General Settings window to enable virus scanning with AMaViS program –AMaViS stands for A Mail Virus Scanner 27

28 Linux Operations and Administration General Settings (cont’d.) 28 Figure 12-2 The General Settings window © Cengage Learning 2013

29 Linux Operations and Administration Outgoing Mail Outgoing Mail window is used to configure dial-up connections by: –Adding your ISP’s SMTP server, such as smtp.provider.com –Clicking Authentication button to enter authentication credentials MTAs can send messages to remote MTAs –If your mail server is connected to the Internet, you can leave outgoing mail server entry blank 29

30 Linux Operations and Administration Outgoing Mail (cont’d.) When you send e-mails, your full computer name is used in the name field –Example: john@linux-001.example.com Most companies prefer to have the organization name displayed –To do this: Click the Masquerading button Set a display name for each user on the network 30

31 Linux Operations and Administration Outgoing Mail (cont’d.) 31 Figure 12-3 The Outgoing Mail window © Cengage Learning 2013

32 Linux Operations and Administration Incoming Mail Accept remote SMTP connections option –This check box is disabled if: If your computer isn’t directly connected to the Internet You have a dial-up connection –Select this option if: If you’re connected to the Internet directly –If you select this option, you must configure firewall settings Need to select Open Port in Firewall check box 32

33 Linux Operations and Administration Incoming Mail (cont’d.) 33 Figure 12-4 The Incoming Mail window © Cengage Learning 2013

34 Linux Operations and Administration Incoming Mail (cont’d.) Downloading section –If a company hosts e-mail on a server that isn’t connected directly to its networks: Enter remote server’s credentials in Downloading section –Protocols that can be used to transfer e-mail from a remote MTA: POP3—Post Office Protocol 3 (POP3) IMAP—Internet Message Access Protocol (IMAP) 34

35 Linux Operations and Administration Incoming Mail (cont’d.) “Forward root’s mail to” text box –Root user account has full access to all Linux machines on a network –Logging in to mail server as a regular user with limited permissions is recommended –You can redirect system e-mails to your regular user account by entering your username in “Forward root’s mail to” text box 35

36 Linux Operations and Administration Incoming Mail (cont’d.) Delivery Mode drop-down list –Options Directly Through procmail To Cyrus IMAP Server Aliases button –Used for redirecting e-mail to a different local user or a list of local users Virtual domains button –Used to create an alias for your domain name 36

37 Linux Operations and Administration Incoming Mail (cont’d.) If you selected masquerading option in Outgoing Mail window: –You should configure a domain alias Activity 12-2: Configuring a Mail Server –Configure a mail server to send e-mail from a user on one computer to a user on another computer 37

38 Linux Operations and Administration Incoming Mail (cont’d.) 38 Figure 12-5 The Forwarder Settings window © Cengage Learning 2013

39 Linux Operations and Administration Summary E-mail is based on standard protocols for sending, storing, and receiving electronic messages Mail transfer agent delivers messages between systems via Simple Mail Transfer Protocol Mail user agent is the mail application users run to access mailboxes and send and receive e-mail SMTP is the standard protocol for sending e-mail across a network Sendmail is the most widely used MTA on Linux systems Postfix is the preferred MTA in openSUSE 39

40 Linux Operations and Administration Summary (cont’d.) Qmail is a modular MTA KMail and Evolution are two graphical MUAs Mailx is a command-line MUA Fetchmail is a text-based MUA Can configure settings for an openSUSE mail server with YaST Mail Server Configuration Wizard POP3 and IMAP are client/server protocols for receiving e-mail Procmail: to filter and sort incoming e-mail Cyrus: a type of IMAP server 40


Download ppt "Linux Operations and Administration Chapter Twelve Configuring a Mail Server."

Similar presentations


Ads by Google