July 29, 2005

Note helpful lack of pid, so I had to strace all my imapds to track it down and then grep through source code for calls to perror (random guesswork). And it’s caused by… wait for it… famd not running (see #294656). Of course!

No, really. WTF?!?! I’m switching to dovecot. Utter utter crack.

Update: Corrected the bug number. #308313 is the other problem I’ve been debugging today, the combination of the two leading me to believe my machine was rooted or had fucked hardware. I utterly hate both courier *and* proftpd, and will be switching to dovecot and vsftpd as soon as possible.

6 Responses to “Courier… WTF?!”

I used to run Courier too, but it’s too slow and has some tricky and hidden WTF like this. I switched to Dovecot about a couple of weeks ago (http://blog.bulix.org/index.php/blog/480 [fr]). Faster, harder, stronger ! ((c) DaftPunk ;p)

Absolutely! Speed was the other thing – I run Dovecot at home and the indexing is brilliant – addressing the only downside to Maildirs, which is that they take ages to load. I think we settled on Courier because it could read our virtual users from PostgreSQL, before this functionality was mature in Dovecot, but it’s there now and works fine.

This script looks exceedingly handy though. Have you considered having it added to Dovecot? Have you tested with clients other than mutt? Some like Evolution seem to get really confused if the IMAP folders change under them, especially the whole namespace like this…

Hmmm. I have a different experience with the whole courier suite. It just works as advertised, both the MTA and IMAP. I don’t think I had to change the configuration much, if at all. Very few WTF moments…

The only thing I agree with is that courier-IMAP is a bit slow. Other than that it was just plug&play. I can’t be bothered changing the LDAP structure just to add dovecot in the mix. Maybe if I move off courier-mta I’d consider it, but at the moment I’ve got few reasons. Which MTA are you using by the way?

The MTA we use is postfix, which lets you specify whatever queries you want to be the source of its lookup tables. I’ve never used courier as an MTA, but I’ve got no problems with postfix so I’m not keen to start trying other stuff (especially courier) now. We would’ve used dovecot originally but it wasn’t quite ready to do the database stuff at the time, but I’ve always known it to be far less crackful than courier (look at the respective sizes of the packages for a start? and since when did you need 30 processes to serve about 10 IMAP connections?).

Change the LDAP structure? You’ve touched on one of my bugbears there… The way we’re trying to do our hosting system seems to push the boundaries of quite a lot of software. The problem with most other services which can read from databases, of which proftpd, libpam-pgsql and libnss-pgsql are especially guilty, and powerdns and courier less so, is the assumption that your database is not actually a relational database, but just contains only the tables with the crappy half-baked schemas that they made up, like a database table version of each configuration file. In our case, this is simply not true. We had to switch from MySQL to PostgreSQL so we could use views to patch up the difference between what’s actually in our backend database (customers, domains, e-mail accounts, etc) and what these services expect to see (a table full of only their entities) because they don’t let us specify our own queries.

Heh, I know exactly what you’re talking about. I never got how people could live with those crappy schemas in their databases. I did exactly what you’re doing for a long time, use postgresql + views, and was very happy with that. The reason I changed to LDAP was to make use of replication and partitioning, because we’ve got a number of real servers, and a bunch of servers on simple DSL/cable connection (= unreliable).

I recently made the switch from Courier to Dovecot as well, and am very satisfied with the simplicity and lack of bloat in Dovecot. As you described, setting up SQL authentication was dead simple by creating a couple new PostgreSQL views to our server backend.

I didn’t know of sam’s conversion script (on the French-language page) at the time, so I wrote my own migration script. It works pretty much the same: