SMTP Systemmail
D
smartssa at gmail.com
Mon Oct 2 15:31:45 UTC 2006
On 10/2/06, mario <ml at bortal.de> wrote:
> Hello List,
>
> how can i set up my ubuntu box so that the outgoing mails get send via
> smtp auth? If i use a system at myserver.dyndns.org mail address the mail
> get filtered by spam filters.
>
> I only know how to set up mailrc and msmtp for each user to do so, but i
> would like to set this up globally.
>
> Any ideas?
The best way is to use postfix for global sending.
I'm going to assume that you have ubuntu's default setup, which is very minimal.
You will need to edit /etc/postfix/main.cf and edit the relay host
$ sudo nano /etc/postfix/main.cf
find 'relayhost' and edit it...
relayhost = your.outgoing.mailserver.com
...and add the following lines:
smtp_sasl_auth_enable = yes
smtp_sasl_password_maps = hash:/etc/postfix/sasl_passwd
smtp_sasl_security_options =
You then need to create /etc/postfix/sasl_passwd with the format;
your.outgoing.mailserver.com username:password
and run:
$ sudo postmap hash:/etc/postfix/sasl_passwd
$ sudo postfix reload
Then, any local mail sent should end up relayed to the mail server you
specified, using the login and password.
Check the logs (/var/log/mail.info) to see if it is working.
Be warned, ANY mail sent will go out to your relay.
I have a .forward in my home directory, so that any system mail to
root (or my userid, and system accounts) gets sent to a proper email
box.
--
~ Darryl ~ smartssa at gmail.com
~ http://darrylclarke.com
More information about the ubuntu-users
mailing list