_$: apt-get install postfix


Either during the installation or with _$: dpkg-configure postfix

Configuration style -> Satellite
System mail name ->
SMTP relay host ->
Root and postmaster mail recipient -> <user>
Other destinations to accept mail for (blank for none): -> Default values
Force synchronous updates on mail queue? -> No
Local networks: -> Default values
Mailbox size limit (bytes): -> 0
Local address extension character: -> +
Internet protocols to use: -> all

Note: Some cloud providers might have troubles if the mail server that relays your email is in the same network than this host and you use the FQDN. Instead, we might need to use the mail server’s internal IP address. For instance,

In order to do the DNS resolution, postfix will use whatever we have in the /etc/resolv.conf file. Anything you write in the /etc/hosts file will be ignored. Instead, we will configure postfix:

relayhost =


_$: echo "test" | sendmail <user>
_$: echo "test" | mail <user> -s "Test"