[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: IMAP and Exim



I run a similar set up here.

Basically, what you do is:

i) Install postfix and maildrop. Postfix will replace exim, but is probably
better anyway (more secure) and is pretty straight forward to configure
(default configuration worked here). Maildrop is a mail forwarding agent that
will understand mail-directories rather than the default unix mail box.

ii) Install courier imap. Getting this to work is not straight-forward: you
will need to install the PAM modules and libpam-pwdb and libdb2 and the utils
package. Get the courier imap server howto from your favourite howtos mirror
and read it! You will have to create some new accounts and use some utils to
create a userdb file. One bit that you may find doesn't work is that the howto
suggests using a full username@host in the entry in the userdb. I found that
this doesn't work - just use your username.

iii) Once you have a working imap server, with your selection of maildirectories
and sub-mail-directories (remember, when you use maildirmake, use the -f option
to specify multiple depth subfolders within your main mail dir - eg
maildirmake -f mywork.commercial /home/vmail/matthew_maildir to create what will
become imap://localhost/INBOX.mywork.commercial). Now create a ~/.forward file
which contains:

bash# cat /home/matthew/.forward 
"| maildrop -d matthew"

(quote marks are needed). This causes postfix to pass all mail for you to maildrop,
so create a ~/.mailfilter file with your required filtering options. Remember to
add a default catch-all filter at the end. Maildrop shoves the mail into the mail
directories that courier allows you to access through imap. This sounds conplicated
but works well and stabily in practice. 

You may have to fiddle with the ownerships of the maildirectories - try making yourself
the owner and vmail the group recursivly: 

bash# chown -R username.vmail /home/vmail/username_mail_dir

My ~/.mailfilter looks like this:

bash# cat /home/matthew/.mailfilter 
if(/.*boot.*lists\.debian.*/)
{
to /home/vmail/Maildir-Matthew/.linux.debian-boot
}

if(/.*lists\.debian.*/)
{
to /home/vmail/Maildir-Matthew/.linux.debian
}

if(/.*zap.*/)
{
to /home/vmail/Maildir-Matthew/.riscos.zap
}

if(/.*freshmeat.*/)
{
to /home/vmail/Maildir-Matthew/.linux.news
}

if(1)
{
to /home/vmail/Maildir-Matthew
}

Hope this helps.

Matthew

On Tue, Mar 13, 2001 at 10:57:19PM -0300, Carlos Laviola wrote:
> 
> On 14-Mar-2001 John M. wrote:
> > 
> > I want to set up an IMAP server, but I don't know what package to get.  I
> > currently have Exim working great, it sends and receives mail, but I need
> > access to this mail from home and from several machines, so I don't want
> > to use POP, but IMAP seems to be just what I'm looking for.  I'm using
> > woody and I looked at the available IMAP packages, but it just got me
> > confused.  Could someone please tell me what package I can use with Exim
> > and how I would configure it.
> 
> >From what I saw skimming thru apt-cache, you can install task-imap, or
> cyrius-imapd. For information on configuration and exim compatibility, refer to
> the programs' own documentation (sorry, I do not run either of them).
> 
> > 
> > Thanks.
> > 
> > 
> > 
> 
> -- 
> Carlos Laviola - ICQ 55799523
> pub  1024D/3516D372 2000-06-05 Carlos Laviola <claviola@ajato.com.br>
>      Key fingerprint = 3BE1 6591 C78C 2AA4 31DD  AEEF 6406 0227 3516 D372
> 



-- 

Matthew Sackman
Nottingham,
ENGLAND

Using Debian/GNU Linux
Enjoying computing



Reply to: