LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Ubuntu (https://www.linuxquestions.org/questions/ubuntu-63/)
-   -   postfix/procmail doesn't deliver emails! (https://www.linuxquestions.org/questions/ubuntu-63/postfix-procmail-doesnt-deliver-emails-319348/)

eisman 05-02-2005 10:12 AM

postfix/procmail doesn't deliver emails!
 
Hi,

I try to get an imap server running on my machine, but it seems that postfix/procmail doesn't deliver emails to the courier-imap server.

Or should I say the messages stay in /var/mail/userid and are not delivered to the Maildir of the user.

What is here the problem? I tried changing the config files, as read on the internet, but couldn't find the right instructions to fix the problem.

Fetchmail does work, it gets the messages from the pop account.
courier imap server seems to work, because I can get a connection as the user, but I don't see the directories created by maildirmake++ (new, cur, tmp).

Postfix seems to work for sending the files to my pop provider (test went ok, checked it and the mail was delivered)!

One remark, as I have read on an article, you should make the Maildir (in the users dir) with root rights, but then I can't connect to the directory with the mailclient, so I chown-ed it to the users rights and then I could connect.

the ~/.procmail was also as root rights, but I did do a chown to the users rights. all seems to be ok, but the mails stay in the /var/mail/userid file..

Someone has an idea?

Thanks.

rzoia 05-18-2005 09:21 AM

Maildirs
 
You should add
Code:

home_mailbox = Maildir/
to your /etc/postfix/main.cf file. And then do "sudo postfix reload" so that postfix reloads the new configuration.
Now mail will be delivered to ~/Maildir for each user.
Note that you should have an alias for root in /etc/aliases, so that root mail goes to that user instead of root (because root's home directory is not /home/root but /root, so there is no /home/root/Maildir...).

Other changes I did in order for the rest of the system to recognize my Maildirs:
- Added
Code:

MAIL=~/Maildir
and
Code:

export MAIL
to /etc/profile
- Changed /etc/pam.d/login and /etc/pam.d/ssh as follows:
Code:

session optional pam_mail.so standard dir = ~/Maildir
- Changed /etc/login.defs:
Code:

QMAIL_DIR  Maildir/
MAIL_FILE  Maildir/

And finally, added this to my .muttrc so that mutt knows how to deal with my Maildir (just in case I need to read mail with mutt):
Code:

set mbox_type=maildir
set folder=~/Maildir/
set spoolfile=~/Maildir/

Hope that helps.


All times are GMT -5. The time now is 01:06 PM.