[Dovecot] Apple patches 11-14

Timo Sirainen tss at iki.fi
Wed Jan 7 01:26:28 EET 2009


On Tue, 2009-01-06 at 17:06 -0600, Mike Abbott wrote:
> Patch #11 adds a few dtrace providers to key points in the code.  We  
> are still validating the correct placement and usefulness of these.   
> One cool thing about dtrace is that when not in use the hooks  
> literally are just a couple of no-op instructions.

I don't see dtrace-dovecot.h included in it.

Anyway I think the current code is too invasive. For example:

#ifdef APPLE_OS_X_SERVER
	if (DOVECOT_OD_LOOKUP_START_ENABLED())
		DOVECOT_OD_LOOKUP_START(in_od_info, (char *) in_user_name);
#endif

Couldn't the DOVECOT_OD_LOOKUP_START() macro be changed so that the
whole code would become simply:

	DOVECOT_OD_LOOKUP_START(in_od_info, (char *) in_user_name);

And it would internally have the "if
(DOVECOT_OD_LOOKUP_START_ENABLED())" part. That also makes it simple to
get rid of the #ifdefs in .c files.

> Patch #12 increases many listen queue sizes to handle high loads  
> better.  The new values are not necessarily the best possible values  
> but they do allow more throughput.

I guess those can be changed. I've really no idea what the tradeoffs
here are. I suppose it uses some more memory, but is it relevant with
today's memory sizes? Could they be increased even higher than your
values?

> Patch #13 makes dovecot adapt to dynamic host identity changes upon  
> config reload.

Since it's not necessary to limit the domain name length, it could be
just i_strdup()ed. (I should have done this in the mbox code too.)

> Patch #14 covers three miscellaneous changes, to support more file  
> descriptors 

I guess this is the same as running ulimit -n before starting dovecot?
Is it useful to have this code inside Dovecot?

> and an "unlimited" number of mail processes, 

+ /* APPLE - treat as "unlimited" */
+ set->max_mail_processes = 1000000;

Hmm. Is it really a good idea to allow unlimited? Anyway -1U would be
"more" unlimited. :)

> and a different default mail user.

+		"uid=98",	/* _dovecot's uid */
+		"gid=6",	/* _dovecot's gid */

Why does it matter which uid/gid is used for dump-capability? Maybe it
could be just run as root.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part
Url : http://dovecot.org/pipermail/dovecot/attachments/20090106/7bd1f438/attachment.bin 


More information about the dovecot mailing list