kashani writes: > On 1/22/2011 1:34 PM, Alex Schuster wrote:
> I handle it with Postfix. Dovecot is only imap and won't accept main > directly. Whoops. > 1. install postfix with USE sasl or devecot-sasl, I don't believe it > matters which. Add the following lines to the bottom of > /etc/postfix/main.cf and fill in your hostname, domain, etc as needed. > > # local settings > myhostname = host.domain.com > mydomain = domain.com > myorigin = $myhostname > inet_interfaces = all > mydestination = $myhostname, localhost.$mydomain, localhost > mynetworks_style = subnet > mynetworks = 127.0.0.0/8 10.19.20.0/24 I left most items commented out as they are the same as the default, I only had to set mydomain, although dnsdomainname and hostname -d both return wonkology.org. > 2. run sudo newaliases > Postfix bitches if the /etc/mail/aliases.db doesn't exist and will hang > on start. > > 3. Verify postfix works, isn't complaining in the logs, etc. > Make sure it's up and running. That you can telnet to port 25 from > another machine and even send to a local user on your machine. Looks good! > 4. Add the user/pass stuff to the bottom of /etc/postfix/main.cf > > # relay host and credentials > relayhost = [my.external.relayhost.com] > smtp_sasl_auth_enable = yes > smtp_sasl_password_maps = hash:/etc/postfix/sasl.passwd > smtp_sasl_mechanism_filter = digest-md5 > smtp_sasl_security_options = noanonymous I need TLS authentication, and found what I need in a howto: smtp_sasl_tls_security_level = may And I removed smtp_sasl_mechanism_filter. > 5. Once you're this far it's time to test all the way through. > > make sure you can send from the localhost machine > sendmail -v s...@address.com > . > > Once you're sure that works test from another machine on the network. > Ideally it should just work if you've done all the steps. Relaying does not work yet, I get a "Relay access denied (in reply to RCPT TO command)" error. But my initial goal is reached, I can send mail to {root,wonko}@wonkology.org. That's all I wanted. Many many thanks kashani! Your howto is much more than I expected, it is much appreciated. I realize that postfix is not too complicated, so I will play more with it when I have some spare time. Wonko