Mail Server Debian 13

Dari Dokumentasi Robie
Revisi sejak 22 April 2026 04.06 oleh Robie (bicara | kontrib) (←Membuat halaman berisi '= PANDUAN LENGKAP INSTALASI MAIL SERVER = '''Debian 13 di Proxmox CT''' ''Edisi Revisi v2.0 — Diperbarui berdasarkan hasil implementasi nyata'' '''Stack:''' Apache2 • BIND9 • Postfix • Dovecot 2.4 • Roundcube • Telnet '''Spesifikasi:''' HDD 8 GB | RAM 512 MB | Proxmox Container (CT) | IP: 192.168.111.103 == BAB 1 — PENDAHULUAN & GAMBARAN UMUM == === 1.1 Tujuan Panduan === Panduan ini menjelaskan langkah-langkah lengkap untuk membangun Mail Server...')
(beda) ← Revisi sebelumnya | Revisi terkini (beda) | Revisi selanjutnya → (beda)
Loncat ke navigasi Loncat ke pencarian

PANDUAN LENGKAP INSTALASI MAIL SERVER

Debian 13 di Proxmox CT Edisi Revisi v2.0 — Diperbarui berdasarkan hasil implementasi nyata

Stack: Apache2 • BIND9 • Postfix • Dovecot 2.4 • Roundcube • Telnet Spesifikasi: HDD 8 GB | RAM 512 MB | Proxmox Container (CT) | IP: 192.168.111.103

BAB 1 — PENDAHULUAN & GAMBARAN UMUM

1.1 Tujuan Panduan

Panduan ini menjelaskan langkah-langkah lengkap untuk membangun Mail Server di atas Proxmox Container (CT) menggunakan Debian 13. Konfigurasi dirancang sesuai dengan keterbatasan sumber daya (HDD 8 GB, RAM 512 MB) dan telah diverifikasi melalui implementasi nyata.

✅ KOREKSI v2: Panduan ini adalah revisi v2 yang memperbaiki beberapa konfigurasi dari versi sebelumnya, khususnya untuk Dovecot 2.4, konfigurasi socket auth Postfix-Dovecot, sistem logging di Debian 13, dan format pengujian Telnet.

1.2 Arsitektur Layanan

Urutan instalasi wajib diikuti karena setiap layanan menjadi prasyarat bagi layanan berikutnya:

Urutan Layanan Aplikasi Fungsi
1 DNS Server BIND9 Resolusi domain, MX record, PTR record
2 Web Server Apache2 + PHP Hosting webmail Roundcube
3 Database MariaDB Penyimpanan data Roundcube
4 SMTP Server Postfix 3.10 Kirim & terima email (port 25/587)
5 IMAP/POP3 Dovecot 2.4 Pengambilan email oleh klien (port 143/110)
6 Webmail Roundcube Antarmuka web baca/kirim email
7 Testing Telnet Pengujian koneksi SMTP/IMAP manual

1.3 Spesifikasi Lingkungan

Platform Proxmox VE (Container / CT mode)
OS Guest Debian 13 (Trixie) 64-bit
Storage 8 GB HDD
RAM 512 MB + Swap 512 MB (wajib diaktifkan)
IP Address 192.168.111.103 (sesuaikan dengan jaringan Anda)
Domain belajar.local
Hostname mailserver.belajar.local
Postfix 3.10.5
Dovecot 2.4.1 (syntax berbeda dari versi lama!)
Akses Root shell via Proxmox Console atau SSH

📌 CATATAN: Semua perintah dijalankan sebagai root. Dovecot 2.4 di Debian 13 menggunakan syntax konfigurasi baru yang berbeda dari tutorial lama berbasis Dovecot 2.2/2.3.

BAB 2 — PERSIAPAN PROXMOX CONTAINER (CT)

2.1 Membuat Container Debian 13 di Proxmox

  1. Login ke Proxmox Web UI (https://IP-PROXMOX:8006)
  2. Download template: Datacenter → Node → local → CT Templates → cari debian-13
  3. Klik Create CT dan isi konfigurasi:
Parameter Nilai
CT ID 101 (atau nomor bebas)
Hostname mailserver
Template debian-13-standard_*.tar.zst
Disk 8 GB
CPU 1 core
RAM 512 MB
Swap 512 MB (wajib)
Network eth0 → vmbr0, IP static 192.168.111.103/24
DNS 8.8.8.8 (sementara, akan diganti ke lokal)

2.2 Konfigurasi Awal Sistem

2.2.1 Update & Paket Dasar

apt update && apt upgrade -y
apt install -y curl wget git nano net-tools dnsutils ufw rsyslog

✅ KOREKSI v2: rsyslog wajib diinstall di awal. Debian 13 secara default hanya menggunakan systemd journald sehingga /var/log/mail.log tidak terbuat otomatis tanpa rsyslog.

2.2.2 Set Hostname

hostnamectl set-hostname mailserver
nano /etc/hosts

Isi file /etc/hosts:

127.0.0.1       localhost
192.168.111.103   mailserver.belajar.local   mailserver

2.2.3 Aktifkan Swap

fallocate -l 512M /swapfile
chmod 600 /swapfile
mkswap /swapfile
swapon /swapfile
echo "/swapfile none swap sw 0 0" >> /etc/fstab
free -h   # verifikasi swap aktif

2.3 Konfigurasi Firewall

ufw allow 22/tcp
ufw allow 25/tcp
ufw allow 53
ufw allow 80/tcp
ufw allow 110/tcp
ufw allow 143/tcp
ufw allow 443/tcp
ufw allow 587/tcp
ufw allow 993/tcp
ufw allow 995/tcp
ufw enable
ufw status

BAB 3 — INSTALASI DNS SERVER (BIND9)

3.1 Instalasi BIND9

apt install -y bind9 bind9utils bind9-doc dnsutils
named -v
systemctl status bind9

3.2 Konfigurasi named.conf.options

nano /etc/bind/named.conf.options

Isi file:

options {
    directory "/var/cache/bind";
    forwarders { 8.8.8.8; 8.8.4.4; };
    dnssec-validation auto;
    listen-on { any; };
    allow-query { any; };
    recursion yes;
};

3.3 Konfigurasi Zone — named.conf.local

nano /etc/bind/named.conf.local

Isi file:

zone "belajar.local" {
    type master;
    file "/etc/bind/db.belajar.local";
};
zone "111.168.192.in-addr.arpa" {
    type master;
    file "/etc/bind/db.192.168.111";
};

3.4 File Zone Forward

cp /etc/bind/db.local /etc/bind/db.belajar.local
nano /etc/bind/db.belajar.local

Isi file:

$TTL    604800
@   IN  SOA mailserver.belajar.local. root.belajar.local. (
                2024010101 ; Serial
                604800 ; Refresh
                86400  ; Retry
                2419200 ; Expire
                604800 ) ; Negative Cache TTL
;
@       IN  NS  mailserver.belajar.local.
@       IN  A   192.168.111.103
@       IN  MX 10 mailserver.belajar.local.
mailserver IN A 192.168.111.103
mail       IN A 192.168.111.103
www        IN A 192.168.111.103

3.5 File Zone Reverse

cp /etc/bind/db.127 /etc/bind/db.192.168.111
nano /etc/bind/db.192.168.111

Isi file:

$TTL    604800
@   IN  SOA mailserver.belajar.local. root.belajar.local. (
                2024010101 ; Serial
                604800 ; Refresh
                86400  ; Retry
                2419200 ; Expire
                604800 ) ; Negative Cache TTL
;
@   IN  NS  mailserver.belajar.local.
103 IN  PTR mailserver.belajar.local.

3.6 Set DNS ke Lokal & Verifikasi

nano /etc/resolv.conf

Isi file:

nameserver 192.168.111.103
search belajar.local

Verifikasi & restart:

named-checkconf
named-checkzone belajar.local /etc/bind/db.belajar.local
named-checkzone 111.168.192.in-addr.arpa /etc/bind/db.192.168.111
systemctl restart bind9 && systemctl enable bind9

# Verifikasi
nslookup mailserver.belajar.local 192.168.111.103
dig MX belajar.local @192.168.111.103
dig -x 192.168.111.103 @192.168.111.103

BAB 4 — INSTALASI WEB SERVER (Apache2 + PHP + MariaDB)

4.1 Instalasi Apache2

apt install -y apache2 apache2-utils
systemctl start apache2 && systemctl enable apache2

4.2 Instalasi PHP & Modul

apt install -y php php-cli php-common php-curl php-gd php-intl \
    php-json php-mbstring php-mysql php-net-ldap2 \
    php-net-smtp php-net-socket php-pear php-xml \
    php-zip libapache2-mod-php
php -v
php -m | grep -E 'mysql|curl|mbstring|xml|zip|gd|intl'

4.3 Instalasi & Konfigurasi MariaDB

apt install -y mariadb-server mariadb-client
systemctl start mariadb && systemctl enable mariadb
mysql_secure_installation

Jawaban saat mysql_secure_installation:

  1. Enter current password: (kosong, langsung Enter)
  2. Set root password? Y → masukkan password kuat
  3. Remove anonymous users? Y
  4. Disallow root login remotely? Y
  5. Remove test database? Y
  6. Reload privilege tables? Y

4.4 Buat Database Roundcube

mysql -u root -p
CREATE DATABASE roundcubemail CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
CREATE USER 'roundcube'@'localhost' IDENTIFIED BY 'password_roundcube';
GRANT ALL PRIVILEGES ON roundcubemail.* TO 'roundcube'@'localhost';
FLUSH PRIVILEGES;
EXIT;

⚠️ PERHATIAN: Ganti 'password_roundcube' dengan password yang kuat dan catat baik-baik.

4.5 Aktifkan Modul Apache

a2enmod rewrite ssl headers
systemctl restart apache2

BAB 5 — INSTALASI SMTP SERVER (POSTFIX)

📌 CATATAN: Versi Postfix yang terinstall di Debian 13 adalah 3.10.5. Akan muncul pesan 'backwards-compatible default settings' saat pertama jalan — ini normal dan akan diatasi di langkah konfigurasi.

5.1 Instalasi Postfix

apt install -y postfix postfix-mysql mailutils

Saat dialog instalasi muncul:

  1. General type of mail configuration: Internet Site
  2. System mail name: belajar.local

5.2 Konfigurasi main.cf

nano /etc/postfix/main.cf

Isi/ubah konfigurasi:

# Identitas server
myhostname = mailserver.belajar.local
mydomain = belajar.local
myorigin = $mydomain
# Jaringan
inet_interfaces = all
inet_protocols = ipv4
mydestination = $myhostname, localhost.$mydomain, $mydomain, localhost
mynetworks = 127.0.0.0/8 192.168.111.0/24
relayhost =
# Mailbox format Maildir
home_mailbox = Maildir/
mailbox_size_limit = 51200000
message_size_limit = 10240000
# SASL Auth via Dovecot
smtpd_sasl_type = dovecot
smtpd_sasl_path = private/auth
smtpd_sasl_auth_enable = yes
smtpd_sasl_security_options = noanonymous
smtpd_sasl_local_domain = $myhostname
# Pembatasan relay
smtpd_recipient_restrictions =
    permit_sasl_authenticated,
    permit_mynetworks,
    reject_unauth_destination
# Matikan warning compatibility
compatibility_level = 3.6
# Optimasi RAM rendah
default_process_limit = 10
smtpd_client_connection_rate_limit = 30

✅ KOREKSI v2: Tambahkan compatibility_level = 3.6 untuk menghilangkan warning 'Postfix is using backwards-compatible default settings' yang muncul di log.

5.3 Aktifkan Port Submission di master.cf

nano /etc/postfix/master.cf

Uncomment baris submission (hapus tanda #):

submission inet n       -       y       -       -       smtpd
  -o syslog_name=postfix/submission
  -o smtpd_tls_security_level=encrypt
  -o smtpd_sasl_auth_enable=yes
  -o smtpd_recipient_restrictions=permit_sasl_authenticated,reject

5.4 Restart & Verifikasi

systemctl restart postfix && systemctl enable postfix
postfix check
ss -tlnp | grep -E ':25|:587'

BAB 6 — INSTALASI IMAP/POP3 SERVER (DOVECOT 2.4)

⚠️ PERHATIAN: Dovecot 2.4 di Debian 13 menggunakan syntax konfigurasi yang BERBEDA dari versi 2.2/2.3. Jangan gunakan tutorial lama yang masih pakai disable_plaintext_auth atau auth_mechanisms langsung — syntax tersebut sudah tidak valid dan akan menyebabkan error saat restart.

6.1 Instalasi Dovecot

apt install -y dovecot-core dovecot-imapd dovecot-pop3d
# Cek versi (akan menampilkan 2.4.x)
dovecot --version

6.2 Konfigurasi Protokol — dovecot.conf

nano /etc/dovecot/dovecot.conf

Ubah/atur baris:

protocols = imap pop3

6.3 Konfigurasi Mail Format — 10-mail.conf

Dovecot 2.4 menggunakan parameter mail_driver dan mail_path (bukan mail_location seperti versi lama):

nano /etc/dovecot/conf.d/10-mail.conf

Cari baris-baris lama dan comment semua, lalu tambahkan:

# Dovecot 2.4 - gunakan mail_driver dan mail_path
mail_driver = maildir
mail_path = ~/Maildir
mail_privileged_group = mail

✅ KOREKSI v2: Di Dovecot 2.4, parameter mail_location sudah diganti menjadi mail_driver + mail_path. Menggunakan mail_location di versi ini akan diabaikan atau menyebabkan error.

6.4 Konfigurasi Autentikasi — Syntax Dovecot 2.4

Di Dovecot 2.4, disable_plaintext_auth diganti dengan auth_allow_cleartext. Buat file konfigurasi khusus:

nano /etc/dovecot/conf.d/99-custom.conf

Isi file:

# Konfigurasi auth untuk Dovecot 2.4
# 'disable_plaintext_auth' sudah tidak ada di versi ini
auth_allow_cleartext = yes
passdb pam {
}
userdb passwd {
}

✅ KOREKSI v2: Jangan menambahkan disable_plaintext_auth atau auth_mechanisms di 10-auth.conf karena akan menyebabkan: Job for dovecot.service failed because the control process exited with error code.

6.5 Konfigurasi Socket Auth untuk Postfix — 10-master.conf

Ini adalah konfigurasi KRITIS. Postfix membutuhkan akses ke socket auth Dovecot. Jika socket ini tidak dikonfigurasi dengan benar, Postfix akan error: SASL: Connect to Dovecot auth socket failed: Permission denied.

nano /etc/dovecot/conf.d/10-master.conf

Cari bagian service auth dan pastikan isinya seperti ini:

service auth {
  # Socket untuk Postfix SASL
  unix_listener /var/spool/postfix/private/auth {
    mode = 0660
    user = postfix
    group = postfix
  }
  # Socket untuk userdb
  unix_listener auth-userdb {
    mode = 0600
    user = dovecot
  }
}

⚠️ PERHATIAN: Urutan restart wajib: Dovecot DULU baru Postfix. Jika Postfix direstart sebelum Dovecot, socket belum terbuat dan Postfix akan gagal otentikasi.

6.6 Verifikasi Konfigurasi Sebelum Restart

# Cek tidak ada error syntax
doveconf -n 2>&1 | head -20
# Pastikan parameter utama terbaca
doveconf -n | grep -E 'mail_driver|auth_allow|protocols'

Output yang diharapkan:

auth_allow_cleartext = yes
mail_driver = maildir
mail_path = ~/Maildir
protocols = imap pop3

6.7 Restart Dovecot & Verifikasi Socket

# 1. Restart Dovecot dulu
systemctl restart dovecot
systemctl status dovecot
# 2. Verifikasi socket auth sudah terbuat
ls -la /var/spool/postfix/private/auth

Output yang diharapkan dari ls -la:

srw-rw---- 1 postfix postfix ... /var/spool/postfix/private/auth
# 3. Baru restart Postfix
systemctl restart postfix
# 4. Cek port yang terbuka
ss -tlnp | grep -E ':25|:110|:143|:587'

BAB 7 — MEMBUAT AKUN PENGGUNA EMAIL

Postfix dan Dovecot menggunakan akun sistem Linux sebagai akun email. Setiap user email = satu akun Linux.

7.1 Buat User & Direktori Maildir

# Buat user (tanpa login shell untuk keamanan)
adduser --shell /sbin/nologin user1
adduser --shell /sbin/nologin user2
# Buat struktur direktori Maildir
mkdir -p /home/user1/Maildir/{new,cur,tmp}
chown -R user1:user1 /home/user1/Maildir
mkdir -p /home/user2/Maildir/{new,cur,tmp}
chown -R user2:user2 /home/user2/Maildir
# Verifikasi
ls -la /home/user1/Maildir/

📌 CATATAN: Username = bagian email sebelum @. User 'user1' memiliki email [email protected]

BAB 8 — PENGUJIAN DENGAN TELNET

8.1 Instalasi Telnet

apt install -y telnet

8.2 Pengujian Koneksi SMTP (Port 25)

telnet 192.168.111.103 25

Server harus membalas dengan banner: 220 mailserver.belajar.local ESMTP Postfix ⚠️ PERHATIAN: Jika koneksi terhubung tapi langsung tertutup tanpa banner 220, artinya Postfix menolak koneksi. Cek log dengan: journalctl -u postfix --no-pager | tail -20

Setelah banner muncul, ketik perintah berikut satu per satu:

EHLO belajar.local

Balas: 250-mailserver.belajar.local + daftar fitur ESMTP

MAIL FROM:<[email protected]>

Balas: 250 2.1.0 Ok

RCPT TO:<[email protected]>

Balas: 250 2.1.5 Ok

DATA

Balas: 354 End data with <CR><LF>.<CR><LF>

Ketik isi email dengan format lengkap (From, To, Subject WAJIB ada, diikuti baris kosong sebelum isi pesan):

From: [email protected]
To: [email protected]
Subject: Test Email Pertama
Halo user2, ini adalah email test dari user1.
.

Titik (.) di baris terakhir harus berdiri sendiri tanpa spasi untuk menandai akhir pesan. Balas: 250 2.0.0 Ok: queued as XXXXXXXX

QUIT

Balas: 221 2.0.0 Bye ✅ KOREKSI v2: Format DATA yang benar wajib menyertakan header From:, To:, Subject: lalu satu baris kosong sebelum isi pesan. Tanpa header lengkap, beberapa mail client akan menolak atau gagal menampilkan email.

8.3 Verifikasi Email Masuk ke Maildir

ls /home/user2/Maildir/new/

Jika muncul file seperti 1776829892.Vfc11I411e9M718352.mail, email berhasil diterima.

# Lihat isi email
cat /home/user2/Maildir/new/NAMA_FILE_EMAIL

8.4 Pengujian Koneksi IMAP (Port 143)

telnet 192.168.111.103 143

Server harus membalas: * OK Dovecot ready

a LOGIN user2 passworduser2
b SELECT INBOX
c FETCH 1 BODY[]
d LOGOUT

8.5 Cek Log — Cara yang Benar di Debian 13

✅ KOREKSI v2: Di Debian 13 tanpa rsyslog, file /var/log/mail.log TIDAK ADA secara default. Gunakan journald untuk melihat log:

# Log Postfix via journald
journalctl -u postfix --no-pager | tail -30
# Log Dovecot via journald
journalctl -u dovecot --no-pager | tail -30
# Monitor realtime
journalctl -u postfix -f
# Setelah rsyslog terinstall, baru bisa pakai:
tail -f /var/log/mail.log

8.6 Troubleshooting Cepat

Error
Connection closed by foreign host (tanpa banner 220)
journalctl -u postfix --no-pager | tail -20
Kemungkinan penyebab dan solusi:
  1. SASL: Connect to Dovecot auth socket failed: Permission denied → Dovecot belum dikonfigurasi socketnya atau belum direstart. Jalankan: systemctl restart dovecot, lalu cek ls -la /var/spool/postfix/private/auth
  2. fatal: no SASL authentication mechanisms → Akibat dari error socket di atas. Setelah Dovecot diperbaiki dan direstart, restart juga Postfix.
  3. mynetworks tidak mencakup IP → Tambahkan: postconf -e 'mynetworks = 127.0.0.0/8 192.168.111.0/24'
Error
Dovecot gagal restart setelah edit 10-auth.conf
  1. Hapus atau comment baris disable_plaintext_auth dan auth_mechanisms yang ditambahkan manual
  2. Gunakan file 99-custom.conf dengan parameter auth_allow_cleartext = yes sebagai gantinya
  3. Verifikasi dengan: doveconf -n 2>&1 | head -10

BAB 9 — INSTALASI WEBMAIL (ROUNDCUBE)

Roundcube adalah webmail berbasis PHP. Prasyarat: Apache2, PHP, dan MariaDB sudah berjalan, serta Postfix dan Dovecot sudah berhasil diuji dengan Telnet.

9.1 Download & Ekstrak Roundcube

cd /var/www/html
# Download Roundcube (cek versi terbaru di https://roundcube.net)
wget https://github.com/roundcube/roundcubemail/releases/download/1.6.6/roundcubemail-1.6.6-complete.tar.gz
tar xzf roundcubemail-1.6.6-complete.tar.gz
mv roundcubemail-1.6.6 roundcube
rm roundcubemail-1.6.6-complete.tar.gz

9.2 Set Permission

chown -R www-data:www-data /var/www/html/roundcube
chmod -R 755 /var/www/html/roundcube
chmod -R 777 /var/www/html/roundcube/temp
chmod -R 777 /var/www/html/roundcube/logs

9.3 Konfigurasi Apache Virtual Host

nano /etc/apache2/sites-available/roundcube.conf

Isi file:

<VirtualHost *:80>
    ServerName mail.belajar.local
    DocumentRoot /var/www/html/roundcube
    <Directory /var/www/html/roundcube>
        Options -Indexes +FollowSymLinks
        AllowOverride All
        Require all granted
    </Directory>
    ErrorLog ${APACHE_LOG_DIR}/roundcube_error.log
    CustomLog ${APACHE_LOG_DIR}/roundcube_access.log combined
</VirtualHost>

Aktifkan site:

a2ensite roundcube.conf
a2dissite 000-default.conf
systemctl reload apache2

9.4 Import Skema Database

mysql -u roundcube -p roundcubemail < /var/www/html/roundcube/SQL/mysql.initial.sql

9.5 Setup via Web Installer

  1. Buka browser: http://192.168.111.103/roundcube/installer
  2. Ikuti wizard — pastikan semua ceklis hijau di halaman pertama
  3. Isi konfigurasi database:
    1. Database server: localhost
    2. Database name: roundcubemail
    3. Database user: roundcube
    4. Database password: (sesuai yang dibuat di BAB 4)
  4. Isi konfigurasi IMAP:
    1. IMAP host: localhost, port: 143
    2. Connection type: normal (TLS opsional)
  5. Isi konfigurasi SMTP:
    1. SMTP host: localhost, port: 25
  6. Klik Create config lalu Initialize database
  7. Setelah selesai, WAJIB hapus folder installer:
rm -rf /var/www/html/roundcube/installer

9.6 Akses Roundcube

Buka browser dan akses: http://192.168.111.103/roundcube Login menggunakan username dan password akun Linux (user1 atau user2). 📌 CATATAN: Jika login gagal, pastikan Dovecot berjalan dan cek: journalctl -u dovecot --no-pager | tail -20

BAB 10 — VERIFIKASI AKHIR & TROUBLESHOOTING

10.1 Checklist Verifikasi Lengkap

Item Pengujian Perintah Hasil Diharapkan
BIND9 berjalan systemctl is-active bind9 active
MX record terdaftar dig MX belajar.local mailserver.belajar.local
PTR record terdaftar dig -x 192.168.111.103 mailserver.belajar.local
Apache2 berjalan systemctl is-active apache2 active
MariaDB berjalan systemctl is-active mariadb active
Postfix berjalan systemctl is-active postfix active
Port SMTP terbuka grep :25 LISTEN :25
Port Submission terbuka grep :587 LISTEN :587
Dovecot berjalan systemctl is-active dovecot active
Port IMAP terbuka grep :143 LISTEN :143
Socket auth ada ls /var/spool/postfix/private/auth socket file ada
Kirim email SMTP telnet localhost 25 220 banner muncul
Email masuk Maildir ls /home/user2/Maildir/new/ ada file email
Login IMAP telnet localhost 143 * OK Dovecot ready
Roundcube dapat diakses curl -sI http://localhost/roundcube HTTP 200

10.2 Perintah Manajemen Cepat

# Restart semua layanan sekaligus (urutan penting!)
systemctl restart bind9 mariadb apache2 dovecot postfix

# Cek status semua layanan
for svc in bind9 apache2 mariadb postfix dovecot; do
    echo "[$svc]: $(systemctl is-active $svc)"
done

# Monitor log email realtime
journalctl -u postfix -f

# Cek antrian email
mailq

# Flush antrian email tertunda
postqueue -f

# Tambah user email baru
adduser --shell /sbin/nologin namauser
mkdir -p /home/namauser/Maildir/{new,cur,tmp}
chown -R namauser:namauser /home/namauser/Maildir

APPENDIX — REFERENSI CEPAT

A.1 Daftar Port Layanan

Port Protokol Layanan Keterangan
25 TCP Postfix SMTP Terima email antar server
53 TCP/UDP BIND9 DNS Resolusi nama domain
80 TCP Apache2 HTTP Webmail Roundcube
110 TCP Dovecot POP3 Ambil email (POP3)
143 TCP Dovecot IMAP Ambil email (IMAP)
443 TCP Apache2 HTTPS Webmail HTTPS (opsional)
587 TCP Postfix Submission Kirim email dari klien
993 TCP Dovecot IMAPS IMAP over SSL
995 TCP Dovecot POP3S POP3 over SSL

A.2 Ringkasan Koreksi v2 dari Implementasi Nyata

No Masalah Panduan v1 (Salah) Panduan v2 (Benar)
1 Dovecot 2.4 auth config disable_plaintext_auth = no auth_allow_cleartext = yes di 99-custom.conf
2 Dovecot 2.4 mail format mail_location = maildir:~/Maildir mail_driver = maildir + mail_path = ~/Maildir
3 Socket Postfix-Dovecot Tidak ada konfigurasi socket service auth { unix_listener /var/spool/postfix/private/auth }
4 Urutan restart service Restart bersamaan Dovecot dulu, baru Postfix
5 Log di Debian 13 tail -f /var/log/mail.log journalctl -u postfix --no-pager
6 Format perintah DATA SMTP Langsung isi tanpa header From/To/Subject wajib, lalu baris kosong, lalu isi
7 Postfix compatibility Tidak dikonfigurasi compatibility_level = 3.6
8 IP Address contoh 192.168.1.100 192.168.111.103

— Panduan Mail Server Debian 13 di Proxmox CT — Revisi v2.0 —