User Tools

Site Tools


en:for_admin:emails

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
en:for_admin:emails [2024/12/30 02:55] – removed - external edit (Unknown date) 127.0.0.1en:for_admin:emails [2024/12/30 03:22] (current) mkadlof
Line 1: Line 1:
 +====== Emails ======
 +This article describes how to configure the Eden cluster servers to send email notifications.
  
 +1. Remove all unnecessary interfering packages:
 +
 +  apt purge postfix* exim* mailutils* sendmail*
 +  apt autoremove
 +
 +2. Install the MTA (Mail Transport Agent) program called ''msmtp'':
 +
 +  apt install msmtp
 +
 +3. Add the configuration file ''/etc/msmtprc'' and include the following content:
 +
 +  defaults
 +  auth off
 +  tls off
 +  account default
 +  host poczta.mini.pw.edu.pl
 +  port 25
 +  from <HOST-NAME>@mini.pw.edu.pl
 +  logfile /var/log/msmtp
 +
 +<WRAP center round important 60%>
 +Update the sending server's hostname!
 +</WRAP>
 +
 +4. Link the ''msmtp'' program to the sendmail ''command'':
 +
 +  ln -s /usr/bin/msmtp /usr/sbin/sendmail
 +
 +5. Create the ''/var/log/msmtp'' file and set the permissions:
 +
 +  touch /var/log/msmtp
 +  chown msmtp:root msmtp
 +  chmod 660 msmtp
 +
 +6. Create a ''logrotate'' entry for the log file and save it to: ''/etc/logrotate.d/msmtp''
 +
 +  /var/log/msmtp {
 +      daily
 +      rotate 7
 +      compress
 +      delaycompress
 +      missingok
 +      notifempty
 +      create 660 msmtp root
 +  }
 +