On 2004-07-13 07:40:18 +0100 Ian Douglas alug@k1ngph1cher.com wrote:
[tux@alice tux]$ cat ~/.forward "|IFS=' ' && exec /usr/bin/procmail -f || exec 75 tux"
I'm pretty sure this should be something more like:
|/usr/bin/procmail -f tux
Look at "man procmail" on your system to see if it has the preferred invocation. If you really need the above form, I think
|IFS=' ' exec /usr/bin/procmail -f || exec 75 tux
is more usual... not sure why those &&s were there. Usually && behaves like a ; dividing two commands, but the second command is only run if the first one succeeds (unlike ; where the second command is always run as soon as the first exits). In the line above, starting at the left, | says this is a pipe (so email gets sent to its input), IFS=' ' just sets a shell variable (without running a command), then the shell thinks && is the command, so it complains with the error you gave. Maybe it used to be accepted by some shell, but I'm not sure I've ever seen it before.
By the way, many modern MTAs can run procmail without a .forward file, by checking whether .procmailrc exists. Exim is definitely one and I'd expect Postfix to be able to do that too. Exim's default debian config does this, I believe. Maybe a Postfix user can tell us how that works?
In general, I suggest avoiding procmail unless you have a Compelling Reason. Its configuration is user-hostile line noise and alternatives like maildrop and Exim filter files are easier to write.