procmail
[Top] [All Lists]

Re: ? character in my /var/spool/mail/$LOGNAME

2001-03-19 11:00:36
Stephen Lim <rux(_at_)ffs(_dot_)per(_dot_)sg> writes:
...
Currently I'm using Mandrake 7.2, reinstall postfix, mutt, fetchmail
and procmail from tarball sources.

I specify my mail spool is in /var/spool/mail/$LOGNAME.

Sending mail using mutt is no problem at all. Problem occured when I
run fetchmail (and of course I have .procmailrc and .fetchmailrc in my
homedir) and the mail that are downloaded, are being placed in
/var/spool/mail/$LOGNAME? instead of /var/spool/mail/$LOGNAME (notice
the question mar character) as well as it creates backup? file in my
homedir, instead of putting it in my $MAIL dir (which is $HOME/mail/)

And when I disable procmail (remove .procmailrc in my homedir) the
problem disappear, so I concluded that the problem is with procmail.
Anyone here experiencing similar problem and what's the solution ?

The problem is almost certainly that line ending in your .procmailrc are
CRLF instead of just LF.  Procmail treats the CR as part of the line
content, so it ends up as part of the variable value, and thus part of
the filenames.  "ls" then displays these as "?" because they're not
printable characters.

So, you need to strip the trailing CR from each line.  You can probably
do this from an editor, but I would tend to use tr or something like
that:

        tr -d "\015" <.procmailrc >new-rc
        mv new-rc .procmailrc


Philip Guenther
_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>