Mail User Agent - MUA : Mutt
Mail Transfer Agent - MTA (incoming) : Fetchmail
Mail Delivery Agent - MDA : Postfix
Mail Transfer Agent - MTA (outgoing) : Postfix
(Pengertian dan perkembangan dari masing-masing item di atas
silakan cari sendiri di internet)
Download dan Install Paket
lubuntu@lubuntu:~$ sudo apt-get install mutt
...
The following extra packages will be installed:
libtokyocabinet9 postfix
...
The following NEW packages will be installed:
libtokyocabinet9 mutt postfix
...
lubuntu@lubuntu:~$ sudo apt-get install fetchmail
Setting file konfigurasi
File :
.fetchmailrc
Lokasi: /home/lubuntu
Mail Server: Outlook.com
Mail Protocol: POP3
Keterangan: bila file ini belum ada buat dengan
vi atau
leafpad
lalu ubah permission-nya menjadi 0700 dengan:
sudo chmod 700 ~/.fetchmailrc
Isi file:
#======================================================#
poll pop3.live.com with protocol pop3 user MAIL_USER@outlook.com \
with password MAIL_PASSWORD is lubuntu here;
# Bila menggunakan procmail sebagai MDA-nya
# mda "/usr/bin/procmail -d %T"
options
ssl
sslproto ssl3
sslcertck
#======================================================#
File :
.muttrc
Lokasi: /home/lubuntu
Keterangan: bila file ini belum ada buat dengan
vi atau
leafpad
lalu ubah permission-nya menjadi 0700 dengan:
sudo chmod 700 ~/.muttrc
Isi file:
#======================================================#
# Personal data
set realname =lubuntu
set from = MAIL_USER@outlook.com
set use_from = yes
set envelope_from ="yes"
set charset=UTF8
# Setting environment variables:
set mbox_type=Maildir
set spoolfile="~/Maildir"
#======================================================#
# Folders
set mask="!^\\.[^.]"
set folder="~/Maildir"
set mbox="~/Maildir" # Mailbox-nya di sini
set record="+.Sent" # lokasi pesan terkirim
set postponed="+.Drafts" # lokasi pesan draf
set move=no # tidak memindahkan pesan dari spool.
#======================================================#
# Pengurutan:
set sort_browser=alpha # mengurutkan mailbox
#======================================================#
# Urutan header dan tampilan
hdr_order Date: From: User-Agent: X-Mailer \
To: Cc: Reply-To: Subject:
ignore *
unignore Date: From: User-Agent: X-Mailer \
To: Cc: Reply-To: Subject:
#======================================================#
# Penyunting teks
# pakai vi
set editor="vi -c 'set tw=70 et' '+/^$' "
set edit_headers # See the headers when editing
#======================================================#
# Aliases
set sort_alias=alias # pengurutan nama alias
#======================================================#
# Lain-lain
set markers # menandai penggalan baris teks dengan a +
set smart_wrap # jangan memenggal di tengah kata
set pager_context=5 # menahan 5 baris akhir saat menggulung.
set status_on_top # Baris Status di atas.
push <show-version> # versi Mutt saat startup
File :
sasl_passwd dan
sasl_passwd.db
Lokasi: /etc/postfix
Isi file sasl_passwd:
smtp.live.com:587 MAIL_USER@outlook.com:MAIL_PASSWORD
Simpan, lalu ketikkan perintah:
lubuntu@lubuntu:~$ sudo chown root:root /etc/postfix/sasl_passwd
lubuntu@lubuntu:~$ sudo postmap hash:/etc/postfix/sasl_passwd
file mapping sasl_passwd.db terbentuk
File :
main.cf
Lokasi: /etc/postfix
Isi file:
# See /usr/share/postfix/main.cf.dist for a commented, more complete version
# Debian specific: Specifying a file name will cause the first
# line of that file to be used as the name. The Debian default
# is /etc/mailname.
#myorigin = /etc/mailname
smtpd_banner = $myhostname ESMTP $mail_name (Ubuntu)
biff = no
# appending .domain is the MUA's job.
append_dot_mydomain = no
# Uncomment the next line to generate "delayed mail" warnings
#delay_warning_time = 4h
readme_directory = no
# TLS parameters
# smtpd_tls_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem
# smtpd_tls_key_file=/etc/ssl/private/ssl-cert-snakeoil.key
# smtpd_use_tls=yes
# smtpd_tls_session_cache_database = btree:${data_directory}/smtpd_scache
smtp_tls_session_cache_database = btree:${data_directory}/smtp_scache
smtp_tls_security_level = may
# See /usr/share/doc/postfix/TLS_README.gz in the postfix-doc package for
# information on enabling SSL in the smtp client.
myhostname = lubuntu
alias_maps = hash:/etc/aliases
alias_database = hash:/etc/aliases
mydestination = lubuntu, localhost.localdomain, , localhost
relayhost = smtp.live.com:587
mynetworks = 127.0.0.0/8 [::ffff:127.0.0.0]/104 [::1]/128
mailbox_size_limit = 0
recipient_delimiter = +
inet_interfaces = all
inet_protocols = all
smtp_sasl_auth_enable = yes
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
smtp_sasl_security_options =
home_mailbox = Maildir/
Cara memainkannya
Dari Terminal:
lubuntu@lubuntu:~$ sudo postfix start
lubuntu@lubuntu:~$ fetchmail
lubuntu@lubuntu:~$ mutt
Ketika di dalam Mutt, bila ingin mengambil email dari Outlook, ketik tanda
! untuk
dapat menjalankan perintah shell, lalu ketik
fetchmail
Membuat email dengan tombol
m
Menambahkan lampiran dengan
a
Mengirim email dengan
y
Selesai dan keluar dari Mutt dengan tombol
q
lubuntu@lubuntu:~$ sudo postfix stop
Top Bang-Bang(et) hasilnya.