procmail
[Top] [All Lists]

RE: [Q] Piping to formail fails, but piping to sendmail works

2000-01-03 07:23:41
hi,

does anyone know what these errors are saying?

<snip>
procmail: Couldn't determine implicit lockfile from "
${FORMAIL} -A"X-SBClass: Spam" >>${SPAMFOLDER}"
/bin/sh: : Ambiguous redirect
procmail: Error while writing to " ${FORMAIL} -A"X-SBClass: Spam"
${SPAMFOLDER}"
procmail: Couldn't determine implicit lockfile from "
${FORMAIL} -A"X-SBClass: Blocked" >>${BLOCKFOLDER}"
/bin/sh: : Ambiguous redirect
procmail: Error while writing to " ${FORMAIL} -A"X-SBClass: Blocked"
${BLOCKFOLDER}"
procmail: Couldn't determine implicit lockfile from " $FORMAIL -A"X-Sorted:
Bulk" >>$BULKFOLDER"
/bin/sh: : Ambiguous redirect
procmail: Error while writing to " $FORMAIL -A"X-Sorted: Bulk"
$BULKFOLDER"
From QCSBS(_at_)bio(_dot_)zzn(_dot_)com  Thu Dec 30 03:19:57 1999
 Subject: "QUICK CASH SECRET BANKING SYSTEM" NOW REVEALED AT LAST!
  Folder: /var/spool/mail/gtinternet                                       4338
procmail: Couldn't determine implicit lockfile from "
${FORMAIL} -A"X-SBClass: Blocked" >>${BLOCKFOLDER}"
/bin/sh: : Ambiguous redirect
procmail: Couldn't determine implicit lockfile from " $FORMAIL -A"X-Sorted:
Bulk" >>$BULKFOLDER"
/bin/sh: : Ambiguous redirect
From Mamasita98520(_at_)yahoo(_dot_)com  Thu Dec 30 06:33:34 1999
 Subject: DB Search
  Folder: /var/spool/mail/gtinternet                                       1412
procmail: Couldn't determine implicit lockfile from "
${FORMAIL} -A"X-SBClass: Blocked" >>${BLOCKFOLDER}"
/bin/sh: : Ambiguous redirect
procmail: Couldn't determine implicit lockfile from " $FORMAIL -A"X-Sorted:
Bulk" >>$BULKFOLDER"
/bin/sh: : Ambiguous redirect
From tazapawan(_at_)aol(_dot_)com  Thu Dec 30 08:58:45 1999
 Subject: Search Request
  Folder: /var/spool/mail/gtinternet                                       1526
procmail: Couldn't determine implicit lockfile from " $FORMAIL -A"X-Sorted:
Default" >>$DEFAULT"
/bin/sh: : Ambiguous redirect
procmail: Couldn't determine implicit lockfile from " $FORMAIL -A"X-Sorted:
Bulk" >>$BULKFOLDER"
/bin/sh: : Ambiguous redirect
From admin(_at_)tox-games(_dot_)com  Thu Dec 30 09:22:46 1999
 Subject: VSO Proposal
  Folder: /var/spool/mail/gtinternet                                       1099
procmail: Couldn't determine implicit lockfile from "
${FORMAIL} -A"X-SBClass: Blocked" >>${BLOCKFOLDER}"
/bin/sh: : Ambiguous redirect
procmail: Couldn't determine implicit lockfile from " $FORMAIL -A"X-Sorted:
Bulk" >>$BULKFOLDER"
/bin/sh: : Ambiguous redirect
From guidenet99(_at_)earthlink(_dot_)net  Thu Dec 30 10:11:27 1999
 Subject: Make An Extra $300 By Next Week
  Folder: /var/spool/mail/gtinternet

<snip>

i am getting mail through it just doesnt seem to be filtering spam.

any assistance is greatly appreciated.

-regards

greg

-----Original Message-----
From: sam(_at_)progressive-systems(_dot_)com 
[mailto:sam(_at_)progressive-systems(_dot_)com]
Sent: Thursday, December 30, 1999 8:25 AM
To: David W. Tamkin
Cc: procmail(_at_)informatik(_dot_)rwth-aachen(_dot_)de
Subject: Re: [Q] Piping to formail fails, but piping to sendmail works



Sam wrote,

| This recipe works fine:
|
|   :0 c
|   |$SENDMAIL sam
|
| But when I try to use formail, it fails:
|
|   :0 c
|   |/usr/local/bin/formail | $SENDMAIL sam
|
|   :0 c
|   |(/usr/local/bin/formail) | $SENDMAIL sam
|
|   # Even this does not work and /tmp perms are fine
|   :0 c
|   |cat >> /tmp/out

Here's a thought: the recipe with no characters from $SHELLMETAS works,
but those with characters from $SHELLMETAS do not.  So, first question,
what is $SHELL set to?  Perhaps to a name (or a relative path) that doesn't
exist?


It's this type of insightful thinking that separates the sharp
sysadmins from the mediocre ones. :-)

Yes, that was exactly the problem.  Setting SHELL to /bin/sh made it
work fine.  I figured this out shortly after sending the email.

The mailing lists are just aliases and don't run out of a user's
account.  So the uid,gid when procmail runs is "daemon", which of
course, doesn't have a shell.  On SunOS, the SHELL is conveniently set
to /bin/sh (probably a security risk) for uids w/o shells but NetBSD
sets them to /sbin/nologin (exit).  That's why I have to explicitly
set the shell for the procmailrc to work.

Live and learn.

Thanks,
Sam

<Prev in Thread] Current Thread [Next in Thread>
  • RE: [Q] Piping to formail fails, but piping to sendmail works, Gregory S. Waits <=