Exim (Mailserver minimal): Unterschied zwischen den Versionen

Aus Xinux Wiki
Zur Navigation springen Zur Suche springen
Zeile 1: Zeile 1:
= Exim4 Minimal-Setup (lokale Zustellung) =
+
= Installation von Exim und Mailutils =
 
 
 
* apt install exim4 mailutils -y
 
* apt install exim4 mailutils -y
 
+
=Anlegen der Konfiguration=
* cat > /etc/exim4/update-exim4.conf.conf << 'EOF'
+
*nano /etc/exim4/update-exim4.conf.conf
 +
<pre>
 
dc_eximconfig_configtype='local'
 
dc_eximconfig_configtype='local'
 
dc_other_hostnames='lab.int'
 
dc_other_hostnames='lab.int'
Zeile 17: Zeile 17:
 
dc_mailname_in_oh='true'
 
dc_mailname_in_oh='true'
 
dc_localdelivery='mail_spool'
 
dc_localdelivery='mail_spool'
EOF
+
</pre>
 
+
=Update der finalen Konfiguration=
 
* update-exim4.conf
 
* update-exim4.conf
 +
=Systemdienst neu starten=
 
* systemctl restart exim4
 
* systemctl restart exim4
 +
=Systemdienst checken=
 
* systemctl status exim4 --no-pager
 
* systemctl status exim4 --no-pager
 +
=Testmail versenden=
 
* echo "Testmail" | mail -s "Exim läuft" root
 
* echo "Testmail" | mail -s "Exim läuft" root
 +
=Mail als root checken=
 
* mail
 
* mail
 +
=Kontrolle=
 
* journalctl -u exim4 -n 20 --no-pager
 
* journalctl -u exim4 -n 20 --no-pager
 
* less /var/mail/root
 
* less /var/mail/root

Version vom 10. November 2025, 18:53 Uhr

Installation von Exim und Mailutils

  • apt install exim4 mailutils -y

Anlegen der Konfiguration

  • nano /etc/exim4/update-exim4.conf.conf
dc_eximconfig_configtype='local'
dc_other_hostnames='lab.int'
dc_local_interfaces='127.0.0.1 ; ::1 ; 10.20.10.11'
dc_readhost=''
dc_relay_domains=''
dc_minimaldns='false'
dc_relay_nets=''
dc_smarthost=''
CFILEMODE='644'
dc_use_split_config='false'
dc_hide_mailname=''
dc_mailname_in_oh='true'
dc_localdelivery='mail_spool'

Update der finalen Konfiguration

  • update-exim4.conf

Systemdienst neu starten

  • systemctl restart exim4

Systemdienst checken

  • systemctl status exim4 --no-pager

Testmail versenden

  • echo "Testmail" | mail -s "Exim läuft" root

Mail als root checken

  • mail

Kontrolle

  • journalctl -u exim4 -n 20 --no-pager
  • less /var/mail/root