[Dovecot] appending domain based on port

Timo Sirainen tss at iki.fi
Thu Jan 31 17:42:53 EET 2008


On Thu, 2008-01-31 at 10:32 -0500, Eric Hester wrote:
> I use sql for my passwd db. So are you saying use some kind of
> conditional in my select that checks for @ in the username and if not
> found appends the domain based on the %l variable (using something
> like a join to a table that has port to domain mappings). Interesting.

Exactly. The "checks for @ in username" part could be done easily by
checking if '%d' = ''.

> Im worried that might add significant load to the sql server though.
> This is a fairly large install. (300,000+ boxes).

If there are only a few ports, you could use a CASE instead of a table
join. But I'd think both of them could be done quickly by the SQL
server. It's still a pretty simple query.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://dovecot.org/pipermail/dovecot/attachments/20080131/e7036e46/attachment.bin 


More information about the dovecot mailing list