Contridentuallity

Not a fact, a theory!?

Installing an SMTP server on Linux (Ubuntu)

, , , , ,

Well well well...

It's really simple to install an SMTP server for personal or business use on Linux (Ubuntu).

First off...open up your terminal.

Type the following command :
sudo apt-get install postfix


It might ask you for a password. If it does, simply enter your account login password.

Once all headers have been fetched and downloaded, it will ask you a few questions such as your computername (which you could make "localhost") etc...just some basic questions.

For further configuration settings, type the following into the terminal as a new command :
sudo dpkg-reconfigure postfix


And that's it...
You have your own personal SMTP server running on Linux (Ubuntu).

So you might be wondering how this could be of any use to you...or you might even be wondering how you should set up your email client to use your personal or network Linux computer to send mail via this local server.

Well...having your own SMTP server has many great advantages. It is much faster, much more reliable, and you can go back and check all log files if necessary. I primarily use this local SMTP server for the PHP mail() function which allows me to quickly and efficiently send emails via a PHP function.

If you are planning on using this with your email client such as Opera M2, Thunderbird, Outlook, whatever, simply set the SMTP host name to be "localhost" or whatever your computername is for the Linux box. It should be sending through port 25 with no secure authentication at all.

After installing this...I managed to send emails out to my Gmail and Yahoo accounts in litterally 3 seconds. No jokes. That's extremely quick.

Have fun...and feel free to post your comments here.

AMD Athlon 64 x2 - My new processorChange root password and login as root - Linux Ubuntu Dapper 6.06

Comments

insidenothing Monday, January 29, 2007 4:34:31 PM

Perfect! Much thanks for this quick and easy.. I was about to build from source but thought I would google ubuntu and smtp... you saved me a hour on my PII =)

patrick

Antonie PotgieterContrid Monday, January 29, 2007 5:51:50 PM

Hi Patrick,

I'm glad to hear that you found this article useful.
I actually have a bunch of Linux tutorials from things I figured out myself. I'll post some more here...maybe someone will find it useful.

Best Regards,
Antonie

jasw Monday, June 18, 2007 4:37:23 PM

I have installed the mail server as per your guidelines but really don't know how to put it to use. Need step by step procedure to send mails through this

jasw

ApoloBetaapolobeta Wednesday, July 8, 2009 5:37:08 AM

wow... thanks for sharing these tips! May be the solution for my business, a little office who needs send (sometimes) a big number of e-mails... The ISP and the web hosting service limit us very much at amount of mail sending by hour or day! and the price for a dedicated server is very expensive!! (very very much in Mexico).

I think that's a great solution to me and other people in similar situations.

Thanks a lot!

pedro lomas hernandezpelomher Monday, July 20, 2009 3:41:58 PM

Pues a mi no me funciona localhost.
A pesar de haber configurado postfix de acuerdo con las instrucciones de localhost, al enviar correos , utilizando mozilla thunderbird mediante localhost, thunderbird los da por enviados, pero nunca llegan a la direccion a la que se envian.

neha srinivasneha4488 Saturday, February 20, 2010 9:03:02 AM

hi i m new to this.. i followed your instructions.. how do i test it??anyway i can set up an email gateway for encryption?? thanks for any help possible..

robownes Tuesday, March 16, 2010 12:39:40 PM

Hi Antonie,

Installed the postfix as you said, and had a moment of great hope. However, I soon found that I could only send to other PCs on my local LAN. All other mail servers, gmail included, rejected my mails because they were not from a "recognised" smtp server.

I would appreciate ideas on ways to get round this, if this is possible.

Robin

wichodarkblue Tuesday, October 19, 2010 4:19:16 AM

I have already installed the postfix, and lamp, but i can't send emails with php
so, I think that I have to configure the php.ini but I don't know what to do what part to configure I need your help please

Michael Lornestr8goods Friday, January 14, 2011 2:18:12 PM

I am inquiring about an old link, regarding the smtp server. I have ubuntu 10.10 and I am using evolution. Trying to get my yahoo mail popped and the smtp won't send mail. Receiving is ok. I can't seem to configure it for outgoing. I tried everything. Any ideas. I tried the smtp postfix but I am not sure what to do after that. Do you have any setup screen shots? Any help would be appreciated.

Thanks
Michael

Write a comment

You must be logged in to write a comment. If you're not a registered member, please sign up.

February 2012
S M T W T F S
January 2012March 2012
1 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29