Home Forums OS X Server and Client Discussion Mail Procmail: Program failure

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #358722
    Anonymous
    Guest

    Procmail was working fine and dandy. Then, I enabled WebMail in Server Admin (I know SA restart bad mistake). Now, all incoming mail being filtered through Procmail is not reaching user’s inboxes.

    I get the following info in the mail.log when messages attept to make it to Cyrus’ deliver program:

    Aug  7 07:25:22 xserve postfix/pipe[25243]: 987AB394052: to=<[email protected]>, orig_to=<[email protected]>, relay=procmail, delay=4, status=deferred (temporary failure. Command output: procmail: Couldn't read "/Users//.procmailrc" procmail: Program failure (65) of "/usr/bin/cyrus/bin/deliver" )
    

    I noticed that the user name doesn’t appear in the error “/Users//.procmailrc”. This made me think that my transport in master.cf was bungled somehow.

    I’ve checked and double-checked main.cf and master.cf files and they are correct. I’ve restarted Postfix. Still the same error.

    Any advice is much appreciated.

    #358723
    5280Toad
    Participant

    My main.cf critical lines:

    mailbox_command = /usr/bin/procmail -t -a "$EXTENSION"
    mailbox_transport = procmail
    

    (commented out ‘mailbox_transport = cyrus)

    My master.cf transport:

    procmail  unix  -       n       n       -       -       pipe
      flags=R user=cyrus argv=/usr/bin/procmail -t -m USER=${user} EXTENSION=${extension} /etc/procmailrc
    

    My procmail recipe to hand off to Cyrus:

    DELIVERTO="/usr/bin/cyrus/bin/deliver"
    USERINBOX="$DELIVERTO -e -a $USER -m user/$USER"
    
    :0w
    | $USERINBOX
    
    #358724
    jgardner
    Participant

    Check the file permissions on /etc/procmailrc and on the .procmailrc file in your home directory. Be sure the “mail” group has read permissions.

    #359034
    Andy Clark
    Participant

    Same problem. I managed to get rid of the:
    Couldn’t read “/Users//.procmailrc”
    error. My procmail entry in master.cf was on one line. I threw in a carriage return after “pipe” and got rid of the first error. The single line entry must have kept the environment variables from being passed.to procmail.

    #359040
    Andy Clark
    Participant

    Seem to have figured out the second error.
    Tried testing out delivery manually.
    cat test_message | /usr/bin/procmail -t -m USER=aclark /etc/procmailrc

    procmail: Error while writing to “/usr/lib/cyrus-imapd/deliver”
    procmail: Program failure (65) of “/usr/lib/cyrus-imapd/deliver”

    (I use period rather than slash for delimitter in cyrus)
    cat test_message | /usr/lib/cyrus-imapd/deliver -e -a -m user.aclark
    user.aclark: Mailbox does not exist

    It looks like the -m option for procmail wants just the userid, not user/userid or user.userid

    Changed /etc/procmailrc from:
    USERINBOX=”$DELIVERTO -e -a $user -m user/$USER”
    to:
    USERINBOX=”$DELIVERTO -e -a $user -m $USER”

Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.

Comments are closed