Dovecot versus Postfix

Tommy Trussell tommy.trussell at gmail.com
Wed Nov 14 01:29:16 UTC 2007


On Nov 13, 2007 5:51 PM, Jan Sneep <jan at azureservices.ca> wrote:
> > man postfix
>
> When run that command I get the following;
>
> "POSTFIX(1)
> POSTFIX(1)
...
>
>        check  Warn about bad directory/file ownership or permissions, and
> cre-
>               ate missing directories.
> "
>
> Which isn't very useful for how to use the server.

Well that's REALLY unfortunate because the man page is much more
relevant seeming on this Ubuntu 6.0.6 box. I guess they "improved" it
by removing lots of detail.

If you use the command

apropos postfix

I hope you see all the postfix pages -- about 50 of them on my system
-- not that you need to understand them, but if you don't see them,
maybe there's a problem with the man pages on your system.

> >
> > and read the notes in the config files in
> > /etc/postfix/
>
> None of the files here have any notes in them that describe how to use the
> server. There are two script files, but they look like they are used for
> setup, not for describing how to use the server.

Here's where I'm starting to lose you -- how the server is set up
determines how you will use it...

> > and presumably you also read any relevant information on the
> > screen when you ran
> >
> > sudo dpkg-reconfigure postfix
>
> NEVER ran the install from packages as far as I know, seemed to be part of
> the LAMP server install.

Try running the command I mentioned -- I believe you will find it most
informative.

The LAMP setup is designed to be easy to install, NOT to be complete
"out of the box" because they can't anticipate how you will be using
it.

> >
> > (note that similar docs exist for dovecot in similar locations)
>
> in /usr/share/doc there are three dovecot folders, dovecot-imapd,
> dovecot-pop3d and dovecot.common. In the imapd and pop3d folders I have four
> out of the same five files that are in the postfix folder;
> changelog.Debian.gz, changelog.gz, copyright, and Readme.Debian. Again none
> of which seem to contain information on how to use the servers. The common
> folder has a whole lot of files, at the top of the read me it says
> "http://wiki.dovecot.org/ contains the most up-to-date documentation. Most
> of the files in doc/ are currently out of date."

Well, whether or not it's out of date, dovecot probably hasn't changed
a huge amount. I wouldn't assume it's ALL bad.

> what is the correct Ubuntu
> way to do this.

For the server stuff, the Ubuntu way will be almost completely the
same as the Debian way, so if you find any books or web sites
describing how to configure a Debian package, the same steps will
apply to Ubuntu LAMP.

> I tried unsuccessfully for 3 months to get Open Exchange to
> work on a Debian server and failed in the end because the instructions were
> for a "generic" Linux server, not a Debian one. So I'm a little gun shy of
> trying to apply "generic" info that may or MAY NOT apply.

You have me there. All I did in Ubuntu was install dovecot, read a
couple of pages on the web, and pointed my IMAP client to the server.
It worked. But it sounds like you're doing something Windows-oriented,
and I was doing things strictly linux and Mac oriented. Plus I
intentionally disabled all the machine-to-machine email handling
because I didn't need it.

> In the dovecot-common folder there is a wiki folder with 130 files in it.
> How do you get it to work? or do you have to read each file individually?

I've already wiped the box that had dovecot on it. I don't remember
having a problem there, but if they're html files, you can point a
browser or yelp at them.

> > I hope you know that postfix delivers mail, and dovecot serves
> > messages to mail clients via IMAP. Their functions don't overlap --
> > dovecot provides an IMAP service to Mail User Agents and postfix is a
> > Mail Transfer Agent.
>
> Well, I was hoping that whoever setup the defaut configurations for Postfix
> and Dovecot knew that and that they set it up properly. Again I assuming
> that they have set it up so that mail Postfix receives it sends to Dovecot
> and that Dovecot is an SMTP server?

Dovecot doesn't do SMTP.ALL it does is serve up mail on the machine to
users on your network. (Oh and I said it wrong before -- it serves up
mail as POP3 or IMAP.)

> But, then why are the Cron messages
> still in the Postfix mailboxes? Shouldn't they have been transfered to
> Dovecot if the server was setup properly? Where would I check where the
> Postfix is supposed to send messages on to?
>
> AGAIN, both of these seem to be working, just can't figure out how to
> actually USE them.

The messages appear in the mailbox because the system is generating
them and the defaults have been set to deliver them to that mailbox.
If you want to get to the mailbox from another system, just point your
email client at it.

> I just need something really
> really simple to replace my really really simple and easy to use Microsoft
> Mail application.

I'm sure something like that exists... I used to use one on my ancient
Mac. But the LAMP stuff is heavy duty, intended to be robust and
configurable for managing all sizes of servers and all numbers of
users. I think you've gotten bogged down in the details.

> > > Up until I started to play around with the settings for
> > Postfix and Dovecot
> > > there were no messages in anybodies mail box, however I now have 123
> > > messages in my "jan" mailbox. Webmin tells me they are in
> > /var/mail/jan and
> > > when I look at them they are all from Cron Daemon. when I
> > open one of them
> > > it is addressed from root at ubuntu.localdomain (Cron Daemon)
> > addressed to
> > > root at ubuntu.localdomain. With a subject of "Cron
> > <root at ubuntu> cd / &&
> > > run-parts -- report /etc/cron.hourly" and the following
> > message "run-parts:
> > > run-parts: component /etc/cron.hourly/spamrunner is a
> > broken symbolic link"
> >
> > you can look to see if spamrunner was partly removed and remove it
> > completely, reinstall it, or you could just delete the link and the
> > messages will stop.
>
> How would I do that?

I don't know what spamrunner is, but if it's a package, you can try
looking for it in aptitude. If you don't care about it, you can just
delete that file because it's a broken symbolic link. The command

sudo rm /etc/cron.hourly/spamrunner

would delete the link.

> > > Of course if I try to address any mail from my Win XP
> > machine to either
> > > jan at ubuntu.localdomain or root at ubuntu.localdomain it fails
> > because of course
> > > my default email account attempts to use my ISP's SMTP
> > server to send the
> > > mail and it is looking for an Internet domain name called
> > ubuntu.localdomain
> > > and DNS can't find that one on the public servers ... :O)
> >
> > it doesn't have to be on a PUBLIC server, but you need a name server
> > on your network that knows where everything on your LAN is. On my
> > network, my router is running linux so I activated a name server on
> > it. Handy, because it also assigns addresses using DCHP.
>
> My LinkSys DSL router has a built in DHCP that hands out the local
> addresses.

Yes but you need a name server that hands out local names OR you can
add a hosts file to every box on your network that lists the addresses
of all the boxes on your network.

> The Apache server is running and works. I can point my browser to
> http://ubuntu/egroupware and the server pulls up the appropriate files. It
> seems to know that ubuntu is a device on the LAN and not out on the
> Internet?

If you can do that from ANOTHER machine on your LAN then maybe the
LinkSys router is managing the names.

> > HOWEVER, I don't mess with routing mail -- I let the experts do that
> > for me. When I have used dovecot, I point to it directly from a mail
> > client like Thunderbird, and copy the messages to and from its message
> > stores. Those stores COULD be the same ones that postfix is managing
> > on your LAN.
>
> How do you point directly to it with an email client? For the POP3 server I
> would just give it the IP address of 192.168.1.104 ?

what happens when you do that? Give it the ubuntu username and
password and IP address and see!

what happens when you try to connect to it with an IMAP client? (I
prefer IMAP myself -- the messages will stay on the server.)

It sounds like you may have it configured already -- just use it!




More information about the ubuntu-users mailing list