finalreport1182014

46
VIETNAM NATIONAL UNIVERSITY OF HCMC INTERNATIONAL UNIVERSITY INTERNSHIP REPORT BY NGUYEN LE CHANH DUY BUILDING MAIL SERVER ON LINUX FOR ENTERPRISE

Transcript of finalreport1182014

Page 1: finalreport1182014

VIETNAM NATIONAL UNIVERSITY OF HCMC

INTERNATIONAL UNIVERSITY

INTERNSHIP REPORT

BY

NGUYEN LE CHANH DUY

BUILDING MAIL SERVER ON LINUX

FOR ENTERPRISE

Submitted to: School of Computer Science and Engineering

International University, VNU-HCM

August 2014

Page 2: finalreport1182014

INTERNSHIP REPORT

by

Nguyen Le Chanh Duy

Submitted to: School of Computer Science and Engineering

International University, VNU-HCM

August 2014

Organization/Company: ATHENA

Address: 92 Nguyen Dinh Chieu street, Da Kao ward, district 1, Ho Chi Minh city, Vietnam.

Phone number: 090 78 79 477-094 323 00 99-(08)38244041

Duration of the Internship: 8 weeks (16-06-2014 – 16-08-2014)

Supervisors during the Internship:

o Name: Mr. Vo Do Thang.o Title: Director of ATHENA.o Address: 92 Nguyen Dinh Chieu, Da Kao ward, district 1, HoChiMinh city,

Vietnamo Email: [email protected]

ii

Page 3: finalreport1182014

ACKNOWLEDGMENTS

After 8 weeks of internship at ATHENA, i have completed my project “Building mail

server on Linux for enterprise” with the support from friends and instructor.

I want to thank ATHENA for providing me good conditions to complete my internship

project, especially, I want to thank Mr. Vo Do Thang who has instructed and supported

me during all the time of internship at ATHENA.

Moreover, I have learned new knowledge at ATHENA such as Linux server, Centos,

network, VPS…they will be helpful for my job in the future.

iii

Page 4: finalreport1182014

TABLE OF CONTENTS

I. DESCRIPTION OF COMPANY/ORGANIZATION.....................................................5

II. SUMMARY OF THE INTERNSHIP.............................................................................7

III. PLANNING ..................................................................................................................9

IV. INTERNSHIP ACTIVITIES & ACHIEVEMENTS...................................................11

A. Email Protocols..........................................................................................11

B. Email Structure..........................................................................................14

C. Mail Server on Linux for enterprise...........................................................16

D. System Requirement..................................................................................17

E. Start building the mail server.....................................................................17

V. INTERNSHIP ASSESSMENT.....................................................................................34

REFERENCES..................................................................................................................35

iv

Page 5: finalreport1182014

DESCRIPTION OF COMPANY/ORGANIZATION

ATHENA is a center of education and training of IT fields. It was established in 2004.

This is the center in which many experienced IT engineers work and study in order to

contribute to the development of IT fields in Vietnam.

The major fields of ATHENA:

o ATHENA center focus deeply on education and training of system and network

security, network management and maintenance following the standard quality

of Microsoft, Cisco, Oracle, Linux LPI, CEH…Moreover, ATHENA center also

has the private program of education and training for some government

organizations.

o After 10 years, many trainees of ATHENA center do the job in IT fields for some

government organizations and also for the big companies.

o Besides education and training programs, ATHENA center also cooperate and

exchange technology with some universities such as university of technology,

university of information technology, natural and university of science…

The instructors of ATHENA:

v

Page 6: finalreport1182014

o ATHENA instructors graduate from many big universities in Vietnam. They all

have to get international certificates such as MCSA, MCSE, CCNA, CCNP,

Security+, CEH, Microsoft Certified Trainer…in order to work at ATHENA.

o ATHENA instructors usually go abroad to be trained about the new technologies

and then they transmit those new technologies to the trainees.

vi

Page 7: finalreport1182014

SUMMARY OF THE INTERNSHIP

After 3 years in HCMC International University, I have taken many courses of Network

Engineering so I decided to take internship at ATHENA. Because, ATHENA is a center

that specializes in network and system fields. At ATHENA, I take a project that requires

me to build a mail server on Linux for enterprise.

First, I have to get used to new Linux OS: Centos 6.5. Although, I approached another

Linux OS in coursers in university. I must learn how to control Centos with commands in

terminal.

Second, I must build on local host in order to get used to the configuration of mail

services. Two Linux virtual machines need to be installed (server and client) to test the

mail exchange.

Next, I must correct bugs by myself. I can look for documents, solutions…from internet

or from friends to solve the problems. If it still does not work, I must discuss with the

instructor to get the solutions or the instructions.

Finally, I must build a mail server on VPS. Here, I have to set up putty to access the VPS

in order to configure. My mission is to make the VPS become a Linux mail server that

can connect with yahoo mail and gmail. If it does not exchange mail with gmail or yahoo

vii

Page 8: finalreport1182014

mail, I must fix bugs. My work is done if the VPS works correctly as the instructor

requires.

viii

Page 9: finalreport1182014

PLANNING

Week 1:

o Seeing the instructor to get the project.o Reading and understanding document.o Asking question if necessary.o Writing report.

Week 2:

o Reading and understanding Linux OS.o Get used to Centos 6.5o Writing report.

Week 3:

o Setting up VMware.o Setting up Centos 6.5 on 2 virtual machines (server and client).o Installing telnet, postfix and dovecot services on server.o Writing report.

Week 4:

o Configuring network (Ethernet, hosts…).o Configuring postfix and dovecoto Testing telnet service.o Writing report.

Week 5:

o Installing squirrelmail on server and thunderbird on client.o Configuring squirrelmail and thunderbird.o Sending mail between server and client via squirrelmail and thunderbird.o Writing report.

Week 6:

o Having a VPS.o Installing telnet, postfix and dovecot service on VPS.o Installing squirrelmail on VPS and thunderbird on the laptop.o Writing report.

Week 7:

ix

Page 10: finalreport1182014

o Configuring postfix and dovecot.o Configuring squirrelmail and thunderbird.o Exchange mail with gmail and yahoo mail.o Writing report.

Week 8:

o Fix errors.o Exchange mail with gmail and yahoo mail again.o Writing final report.o Having a project presentation.

x

Page 11: finalreport1182014

INTERNSHIP ACTIVITIES AND ACHIEVEMENTS

A/ Email Protocols:

Interactions between email servers and clients are governed by email protocols. 

The three most common email protocols are POP, IMAP. Most email software

operates under one of these (and many products support more than one). 

The Post Office Protocol (currently in version 3, hence POP3) allows email client

software to retrieve email from a remote server.  The Internet Message Access

Protocol (now in version 4 or IMAP4) allows a local email client to access email

messages that reside on a remote server. The SMTP (Simple Mail Transfer

Protocol) protocol is used by the Mail Transfer Agent (MTA) to deliver your

email to the recipient's mail server

1. Post Office Protocol (POP):

POP is the older design, and hails from an era when intermittent connection via

modem (dial-up) was the norm.  POP allows users to retrieve email when

connected, and then act on the retrieved messages without needing to stay "on-

line."  This is an important benefit when connection charges are expensive.

The basic POP procedure is to retrieve all inbound messages for storage on the

client, delete them on server, and then disconnect.  (The email server functions

like a mailbox at the Post Office -- a temporary holding area until mail gets to its

final destination, your computer.) 

xi

Page 12: finalreport1182014

Outbound mail is generated on the client, and held for transmission to the email

server until the next time the user's connection is active.  After it's uploaded, the

server forwards the outgoing mail to other email servers, until it reaches its final

destination. 

Most POP clients also provide an option to leave copies of email on the server.  In

this case, messages are only removed from the server when greater than a certain

"age" or when they have been explicitly deleted on the client.  It's the copies on

the client that are considered the "real" ones, however, with those left on the

server merely temporary backups.

2. Internet Access Message Protocol (IMAP):

IMAP is the newer protocol and oriented toward a "connected" mode of

operation.  The standard IMAP procedure is to leave messages on the

server instead of retrieving copies, so email is only accessible when "on-

line."  

IMAP is more suited to a world of always-on connections, particularly the

fast connections offered by broadband mechanisms.  Having to be

connected to read your email is a trivial obstacle when the connection is

always available.  (It's a little like leaving your messages at the Post

Office, and going there every time you want to read them.  That might be

difficult in the physical world, but it's easy in the virtual one.)

xii

Page 13: finalreport1182014

Because messages remain on the server, until explicitly deleted by the

user, they can be accessed by multiple client computers -- an important

advantage when you use more than one computer to check your email. 

IMAP does not preclude keeping copies on the client, but, in an inversion

of the way POP works, it's the server's copies that are considered the "real"

ones.  That offers an important security benefit -- you won't lose your

email if, for some reason, your client computer's storage media fails.

IMAP has other advantages over POP (detailed in the links provided

below).  It is the standard we recommend if you can't use MAPI.

3. The Simple Mail Transfer Protocol (SMTP):

At the risk of overloading you with information, you should know that

strictly speaking it's only the incoming mail that is handled by a POP or

IMAP protocol.  Outgoing mail for both POP and IMAP clients uses the

Simple Mail Transfer Protocol (SMTP).

When you set up a POP or IMAP email account on email client software,

you must specify the name of the (POP or IMAP) mail server computer for

incoming mail.  You must also specify the name of the (SMTP) server

computer for outgoing mail.  These names are typically in the same form

xiii

Page 14: finalreport1182014

as Web addresses (e.g., "imap.med.miami.edu").  Depending on the client,

there may also be specifications for email directories and searching.

B/ Email Structure:

o Mail User Agent (MUA): is a program that allows you to receive and

send e-mail messages; it's usually just called an e-mail program. To use an

MUA such as Eudora or Microsoft Outlook, you install the MUA program

on your computer and then use it to download and store e-mail messages

to your computer; it will also allow you to read or write messages offline.

Web-based MUAs, such as Hotmail and Yahoo, store messages on their

own mail servers and allow access to them through a Web page. An MUA

is sometimes called an e-mail agent or an e-mail client.

xiv

Page 15: finalreport1182014

o Mail Transport Agent (MTA): is an application that receives incoming

e-mail from local users (people within the same domain) and remote

senders and forwards outgoing e-mail for delivery. A computer dedicated

to running such applications is also called a mail server. Microsoft

Exchange, qmail, Exim and sendmail are among the more common mail

server programs.

o Mail Delivery Agent (MDA): is the software and other systems that are

responsible for sending and receiving mail between systems. That is the

ONLY things MTAs do: they send and receive messages between systems.

MTAs use the SMTP (Simple Mail Transfer Protocol) to send and receive

messages.

o Mail Submission Agent (MSA): is a computer program or software

agent that receives electronic mail messages from a mail user

agent (MUA) and cooperates with a mail transfer agent (MTA) for

delivery of the mail. It uses a variant of the Simple Mail Transfer

Protocol (SMTP), as specified in RFC 6409.

o Mail Access Agent/ Mail Retrieval Agent (MAA/MRA): is

a computer application that retrieves or fetches e-mail from a remote mail

server and works with a mail delivery agent to deliver mail to a local or

remote email mailbox. MRAs may be external applications by themselves

xv

Page 16: finalreport1182014

or be built into a bigger application like an MUA. Significant examples of

standalone MRAs include fetchmail, getmail and retchmail.

C/ Mail Server (Postfix, Dovecot…) for Enterprise on Linux:

This is a Linux mail server for small and medium companies/enterprises with low

investment. However, it is stable and effective.

o Postfix is Wietse Venema's mail server that started life at IBM research as

an alternative to the widely-used Sendmail program. Postfix attempts to be

fast, easy to administer, and secure. The outside has a definite Sendmail-

ish flavor, but the inside is completely different.

o Dovecot is an open source IMAP and POP3 email server for Linux/UNIX-

like systems, written with security primarily in mind. Dovecot is an

excellent choice for both small and large installations. It's fast, simple to

set up, requires no special administration and it uses very little memory.

xvi

Thunderbird, Outlook, Squirrelmail…

POSTFIXAuthenticate

DOVECOT

MailStoreMailBox(File Linux)

PROCMAILSpamAssanssin

Page 17: finalreport1182014

o SquirrelMail is a standards-based webmail package written in PHP. It

includes built-in pure PHP support for the IMAP and SMTP protocols, and

all pages render in pure HTML 4.0 (with no JavaScript required) for

maximum compatibility across browsers. It has very few requirements and

is very easy to configure and install. SquirrelMail has all the functionality

you would want from an email client, including strong MIME support,

address books, and folder manipulation. 

D/ System Requirement:

o The linux system requires normal hardware support, a linux server with medium

configuration can work stably and effectively. For example, a mail server with

configuration: CPU Pentium III 600MHZ, RAM 256MB, HDD 40GB can serve

from 300 to 400 users.

o Soft wares are required to install on a Linux mail server:

Operating System: Centos 6.5 running with command line. SMTP Server: Postfix 2.3.3 POP3/IMAP Server: 1.0.7 Web Mail: SquirrelMail 1.4.8 Web Server: Apache 2.2.3

Depending on the requirements, all the soft wares can be updated to the

newer version.

E/ Start building the mail server:

I/ Starting with local host:

1. Configure static IP address:

Server:

xvii

Page 18: finalreport1182014

# vi /etc/sysconfig/network-scripts/ifcfg-eth0BOOTPROTO=staticIPADDR=192.168.1.245NETMASK=255.255.255.0GATEWAY=192.168.1.254

Client:

# vi /etc/sysconfig/network-scripts/ifcfg-eth0BOOTPROTO=staticIPADDR=192.168.1.240NETMASK=255.255.255.0GATEWAY=192.168.1.250

2. Configure hostname:

# vi /etc/hosts127.0.0.1 mail.athena.lab129.168.1.245 mail.athena.lab

# vi /etc/sysconfig/networkNETWORKING=yesNETWORKING_IPV6=yesHOSTNAME=mail.athena.lab

3. Configure DNS:

The DNS is a hierarchical distributed naming system for computers,

services, or any resource connected to the Internet or a private network. It

associates various information with domain names assigned to each of the

participating entities. Most prominently, it translates easily

memorized domain names to the numerical IP addresses needed for the

purpose of locating computer services and devices worldwide. The

Domain Name System is an essential component of the functionality of

the Internet.

Install packages with command:

xviii

Page 19: finalreport1182014

# rpm –ivh <packages>:bind-9.8.2-0.17.rc1.el6_4.6.i686.rpmbind-libs-9.8.2-0.17.rc1.el6_4.6.i686.rpmbind-utils-9.8.2-0.17.rc1.el6_4.6.i686.rpm

Create file: /etc/named.conf

acl mynet {192.168.1.0/24

};options {

allow-transfer {none;};directory” /var/named”;query-source port 53;query-source-v6 port 53;dump-file “var/named/data/cache_dump.db”;statistics-file “var/named/data/named_stats.txt”;mamstatistics-file

“var/named/data/named_mem_stats.txt”;notify yes;

};zone “.” IN {

type hint;file “named.root”;

};zone “athena.lab” IN {

type master;file “athena.lab.db”;allow-query {mynet;};};

zone “1.168.192.in-addr.arpa” {type master;file “1.168.192.in-addr.arpa.db”;allow-query {mynet;};

};

Create file: /var/named/named.root by downloading via internet with the command: # wget http://www.internic.net/zones/named.root

Create file: /var/named/athena.lab

$TTL 86400@ IN S0A dns.athena.lab. root. {

46 ; serial3H ; refresh

xix

Page 20: finalreport1182014

15M ; retry1W ; expire1D ; ttl

}IN NS dns.athena.lab.

dns IN A 192.168.1.245mail IN A 192.168.1.245

Create file: /var/named/1.168.192.in-addr.arpa.db:

$TTL 86400@ IN S0A dns.athena.lab. root. {

46 ; serial10800 ; refresh900 ; retry604800 ; expire86400 ; ttl

}

@ IN NS dns.athena.lab.1 IN PTR mail.athena.lab.

Restart named daemon:

# service named restart

Shut down firewall:

# service iptables stop

4. Install and configure Postfix service:

Install Postfix service with command: # yum install postfix

Configure Postfix:

# vi /etc/postfix/main.cf## Line 75 – Uncommentmyhostname = mail.athena.lab

## Line 83 – Uncommentmydomain = athena.lab

## Line 99 - Uncomment

xx

Page 21: finalreport1182014

myorigin = $mydomain

## Line 116 inet_interfaces = all

## Line 164 –Add $mycomain mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain

## Line 250 - Uncommentmynetworks_style = subnet

## Line 264 – Uncomment, Add networksmynetworks = 192.168.1.0/24, 127.0.0.0/8

## Line 419 – Uncomment home_mailbox = Maildir/

Restart postfix:# service postfix restart# chkconfig postfix on# netstat –nat | grep 25

Install Telnet service:

# yum install telnet telnet-server –y

Create users:

# useradd user1# passwd user1# useradd user2# passwd user2

Telnet to server:

# telnet mail.athena.lab 25Trying ::1…Connected to mail.athena.lab.Escape character is ‘^]’.220 mail.athena.lab ESMTP Postfix

Send mail from user1 to user2:mail from: [email protected] 2.1.0 OKrcpt to: [email protected] 2.1.5 OK

xxi

Page 22: finalreport1182014

data354 End data with <CR><LF>.<CR><LF>Testing.250 2.0.0 OK: queued as 1247AF434Aquit 221 2.0.0 ByeConnection closed by foreign host.

5. Install and configure Dovecot service:

Install Dovecot service with command:

# yum install dovecot

Configure dovecot:

# vi /etc/dovecot/dovecot.conf## Line 20 – Uncomment protocols = imap pop3 lmtp

## Line 26 – Uncomment, remove “,::”listen = *

# vi /etc/dovecot/conf.d/10-auth.conf## Line 9 – Uncommentdisable_plaintext_auth = no

## Dòng 97 – Uncommentauth_mechanisms = plain login

# vi /etc/dovecot/conf.d/10-mail.conf## Line 24 – Uncomment mail_location = maildir:~/Maildir

# vi /etc/dovecot/conf.d/10-master.conf## Line 19 – Uncomment port = 143

## Line 22 – Uncomment port = 993

## Line 40 – Uncomment port = 110

## Line 43 – Uncomment

xxii

Page 23: finalreport1182014

port = 995

## Line 82 – Uncomment mode = 0600

## Line 83 – Uncomment, sửa lại thành:user = postfix

## Line 84 – Uncomment, sửa lại thành:group = postfix

Restart dovecot and postfix service:

# service dovecot restart# service postfix restart

6. Install and configure Mozilla Thunderbird:

Install thunderbird with command:

# yum install thunderbird

Create email account with thunderbird:

o Step 1: Access Mozilla Thunderbird

xxiii

Page 24: finalreport1182014

o Step 2: Create a new account > Emailo Step 3: Yourname: user1 > Email address: [email protected] > Password:

1234 > Remember passwordo Step 4: Continue > Manual configo Step 5: Incoming: 192.168.1.245 (IP server) > Outgoing: 192.168.1.245o Step 6: Re-test > confirm security > done

Create email account for user2 as we do for user1

Restart postfix, dovecot service, then exchange mail between user1 and

user2 by using Mozilla Thunderbird.

7. Install and configure Squirrelmail:

Install squirrelmail with commands:

# rpm –Uvh http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm# yum install squirrelmail

Configure squirrelmail:

# vi /etc/share/sbin/squirrelmail/config/conf.plo Step 1: Server Settings > Domain: athena.labo Step 2: Sendmail or SMTP > SMTPo Step 3: R > D > dovecoto Step 4: S to save > Q to quit

Restart postfix, dovecot and httpd service.

Exchange mail between user1 and user2 by accessing

http://<ipaddress>/webmail or http://<domain-name>/webmail

II/ Building mail server on VPS:

1. Install Putty to access the VPS

2. Register domain name:

xxiv

Page 25: finalreport1182014

xxv

Page 26: finalreport1182014

o Step 1: Access www.dot.tk to get a free domain name: athenacd.tko Step 2: Use DNS > Dot TK DNS Serviceo Step 3: Host name: www.athenacd.tk > IP address: 14.0.31.168

Host name: athenacd.tk > IP address: 14.0.31.168o Step 4: maintain this domain name in 3 monthso Step 5: Choose google account to manage this domain nameo Step 5: Sign in my.dot.tk > Go to domain > Modifyo Step 6: Add 2 records > Save changes

A Record > mail.athenacd.tk > 14.0.31.168MX Record > athenacd.tk > mail.athenacd.tk

3. Configure DNS:

Install packages with command: rpm –ivh <packages>:bind-9.8.2-0.17.rc1.el6_4.6.i686.rpmbind-libs-9.8.2-0.17.rc1.el6_4.6.i686.rpmbind-utils-9.8.2-0.17.rc1.el6_4.6.i686.rpm

Create file: /etc/named.conf

acl mynet {14.0.31.160/27

};options {

allow-transfer {none;};directory” /var/named”;query-source port 53;

xxvi

Page 27: finalreport1182014

query-source-v6 port 53;dump-file “var/named/data/cache_dump.db”;statistics-file “var/named/data/named_stats.txt”;mamstatistics-file

“var/named/data/named_mem_stats.txt”;notify yes;

};zone “.” IN {

type hint;file “named.root”;

};zone “athenacd.tk” IN{

type master;file “athenacd.tk.db”;allow-query {mynet;};};

zone “31.0.14.in-addr.arpa” {type master;file “31.0.14.in-addr.arpa.db”;allow-query {mynet;};

};

Create file: /var/named/named.root by downloading via internet with the

command: # wget http://www.internic.net/zones/named.root

Create file: /var/named/athena.tk

$TTL 86400@ IN S0A dns.athenacd.tk. root. {

46 ; serial3H ; refresh15M ; retry1W ; expire1D ; ttl

}IN NS dns.athenacd.tk.IN MX 10 mail.athenacd.tk.

dns IN A 192.168.1.245mail IN A 192.168.1.245www IN CNAME athenacd.tk.ftp IN CNAME athenacd.tk.

Create file: /var/named/31.0.14.in-addr.arpa.db:

xxvii

Page 28: finalreport1182014

$TTL 86400@ IN S0A dns.athenacd.tk. root. {

46 ; serial10800 ; refresh900 ; retry604800 ; expire86400 ; ttl

}

IN NS dns.athenacd.tk.1 IN PTR dns.athenacd.tk.2 IN PTR mail.athenacd.tk.

2. Install and configure Postfix service:

Install Postfix service with command: # yum install postfix

Configure Postfix:

# vi /etc/postfix/main.cf## Line 70 – Uncommentmyhostname = mail.athenacd.tk

## Line 83 – Uncommentmydomain = athenacd.tk

## Line 99 - Uncommentmyorigin = $mydomain

## Line 116 inet_interfaces = all

## Line 164 –Add $mycomain mydestination = $myhostname, localhost.$mydomain, localhost, $mydomain

## Line 250 - Uncommentmynetworks_style = subnet

## Line 264 – Uncomment, Add networksmynetworks = 14.0.31.160/27, 127.0.0.0/8

## Line 419 – Uncomment home_mailbox = Maildir/

xxviii

Page 29: finalreport1182014

Restart postfix:# service postfix restart# chkconfig postfix on# netstat –nat | grep 25

Install Telnet service:

# yum install telnet telnet-server –y

Create users:

# useradd duy# passwd duy# useradd tien# passwd tien

Telnet to server:

# telnet mail.athena.lab 25Trying ::1…Connected to mail.athena.lab.Escape character is ‘^]’.220 mail.athena.lab ESMTP Postfix

Send mail from duy to tien:mail from: [email protected] 2.1.0 OKrcpt to: [email protected] 2.1.5 OKdata354 End data with <CR><LF>.<CR><LF>Testing.250 2.0.0 OK: queued as 1247AF434Aquit 221 2.0.0 ByeConnection closed by foreign host.

Shut down sendmail service and change from MTA to Postfix:

xxix

Page 30: finalreport1182014

# /etc/rc.d/init.d/sendmail stop# chkconfig sendmail off# alternatives –config mta# service postfix restart

3. Install and configure Dovecot service:

Install Dovecot service with command:

# yum install dovecot

Configure dovecot:

# vi /etc/dovecot.conf## Line 20 – Uncomment protocols = imap pop3 lmtp

## Line 26 – Uncomment, remove “,::”listen = *

## Line 211 – Uncomment and add: mail_location = maildir:~/Maildir

Restart dovecot and postfix service:

# service dovecot restart# service postfix restart

4. Install and configure Squirrelmail:

Install squirrelmail with commands:

xxx

Page 31: finalreport1182014

# rpm –Uvh http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm# yum install squirrelmail

Configure squirrelmail:

# vi /etc/share/sbin/squirrelmail/config/conf.plo Step 1: Server Settings > Domain: athena.labo Step 2: Sendmail or SMTP > SMTPo Step 3: R > D > dovecoto Step 4: S to save > Q to quit

# vi /etc/httpd/conf/httpd.conf

<VirtualHost*:80>ServerName mail.athenacd.tkDocumentRoot /usr/share/squirrelmail</VirtualHost>

xxxi

Page 32: finalreport1182014

Restart postfix, dovecot and httpd service:

# service named restart# service postfix restart# service httpd restart# service dovecot restart

Exchange mail between user1 and user2 by accessing

http://<ipaddress>/webmail or http://<domain-name>/webmail

Exchange mail between users and yahoo mail, google mail by accessing

http://<ipaddress>/webmail or http://<domain-name>/webmail

xxxii

Page 33: finalreport1182014

xxxiii

Page 34: finalreport1182014

INTERNSHIP ASSESSMENT

During the internship period, I have gained new knowledge and many experiences from

my project. Firstly, I must take time to research about the Centos in order to understand

how it works. After researching, I recognized the differences between Centos and the

other OS, moreover, I have learned the way to control the Centos by using commands in

terminal. Secondly, I had chance to work with a real server, thanks to that, I knew how to

make it run correctly and fix bugs when problems happen. Next, by learning, I have

understood deeply about the mail protocols, dns, network configuration, network

problems… All of the experiences and knowledge that I have gained from the internship

will be helpful for my future career, because now I am taking the courses of Network

Engineering in university and in the future, as an network engineer, I will face with many

problems of systems, network, servers… However, during the internship period, I found

myself lack of basic knowledge, so beside researching via internet, I also re-learned

myself some courses that I have taken before.

xxxiv

Page 35: finalreport1182014

REFERENCES

athena.edu.vn/

it.med.miami.edu/x1111.xml

searchnetworking.techtarget.com/definition/mail-user-agent

searchsoa.techtarget.com/definition/mail-server

en.wikipedia.org/wiki/Mail_delivery_agent

en.wikipedia.org/wiki/Mail_submission_agent

en.wikipedia.org/wiki/Mail_retrieval_agent

en.wikipedia.org/wiki/Domain_Name_System

www.postfix.org/

www.dovecot.org/

squirrelmail.org/about/

xxxv

Page 36: finalreport1182014

36