Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

What are some of the Dos and Don't to setting up an email server on Ubuntu? Are there any gotcha's?


locked by HopelessN00b Dec 5 '14 at 2:20

This question exists because it has historical significance, but it is not considered a good, on-topic question for this site, so please do not use it as evidence that you can ask similar questions here. This question and its answers are frozen and cannot be changed. More info: help center.

up vote 8 down vote accepted

+1 for Postfix

Be very careful to make sure that your machine cannot be used as an open relay. If it's for an internal lan only, do not accept connections on your public IP. If it's for an external SMTP server, make sure you don't accept any email not intended for your domain. If you need to provide SMTP for your users while they're outside of the network, either use a VPN (in which case they're not outside the network) or implement authentication (and real authentication, not just POP before SMTP)

Toc check for open relay, just use one (or better, many) of the systems that a search for "test open relay" will yield, e.g: – Colas Nahaboo May 27 '09 at 15:17

Whatever you do, do not use Sendmail. The configuration files are so complicated that they created a macro language that compiles down to the actual config files.

The O'Reilly Sendmail book (the bat book) is the thickest on my shelf.

muahhhhaa:) so true – Stann Apr 20 '11 at 9:59


  • use exim or postfix, they're (IMNSHO) the only credible SMTP servers for Linux at the moment.
Also, Ubuntu 9.04 comes with dovecot and postfix pre-packaged and configured to work together, just look for the dovecot-postfix package – agnul Apr 30 '09 at 10:17

Slicehost has fantastic articles that will work with any host, with email specific guides at


I would use qmail, just follow that very good book "life with qmail"


Not the answer you're looking for? Browse other questions tagged or ask your own question.