Maybe I'm ding something stupid?
Here's the filter:
# exim filter
if $received_protocol is not "scanmails" and first_delivery
then
if "$sender_address" is "" then
pipe "/usr/sbin/scanmails -oMr scanmails -f '<>' -bm $recipients"
else
pipe "/usr/sbin/scanmails -oMr scanmails -f $sender_address -bm $recipients"
endif
endif
Here's the debug output:
Exim version 3.12 debug level 99 uid=0 gid=0
probably Berkeley DB version 1.8x (native mode)
charlotte.intern.cats.ms in local_domains? yes (matched *.cats.ms)
Actual local interface address is 127.0.0.1
Actual local interface address is 10.0.1.2
Actual local interface address is 10.0.8.2
Actual local interface address is 10.0.9.2
Caller is an admin user
Caller is a trusted user
user name "root" extracted from gecos field "root"
sender address = root@???
set_process_info: 8533 3.12 accepting a local non-SMTP message from <root@???>
Sender: root@???
Recipients:
kai
search_tidyup called
>>Original headers (size=0):
kai@??? in *@localhost? no (end of list)
root@??? in *@localhost? no (end of list)
rewritten sender = root@???
search_tidyup called
>>Final headers:
P Received: from root by charlotte.intern.cats.ms with local (Exim 3.12 #1 (Debian))
id 12p6k8-0002Dd-00; Tue, 09 May 2000 11:55:56 +0200
I Message-Id: <E12p6k8-0002Dd-00@???>
F From: root <root@???>
T To: kai@???
Date: Tue, 09 May 2000 11:55:56 +0200
Data file written for message 12p6k8-0002Dd-00
Writing spool header file
Size of headers = 308
LOG: 0 MAIN
<= root@??? U=root P=local S=309
exec /usr/sbin/exim -d99 -Mc 12p6k8-0002Dd-00
Exim version 3.12 debug level 99 uid=8 gid=8
probably Berkeley DB version 1.8x (native mode)
charlotte.intern.cats.ms in local_domains? yes (matched *.cats.ms)
Actual local interface address is 127.0.0.1
Actual local interface address is 10.0.1.2
Actual local interface address is 10.0.8.2
Actual local interface address is 10.0.9.2
Caller is an admin user
Caller is a trusted user
set_process_info: 8534 3.12 delivering specified messages
delivering message 12p6k8-0002Dd-00
set_process_info: 8534 3.12 delivering 12p6k8-0002Dd-00
Opened spool file 12p6k8-0002Dd-00-H
user=root uid=0 gid=0 sender=root@???
sender_local=1 resent=no ident=root
Non-recipients:
Empty Tree
---- End of tree ----
recipients_count=1
body_linecount=0 message_linecount=6
running system filter as uid=0 gid=8 euid=8 egid=8
Filter: start of processing
Sub-condition is true: $received_protocol is not scanmails
Sub-condition is true: first_delivery
Condition is true: $received_protocol is not scanmails and first_delivery
Condition is false: $sender_address is
Filter: pipe message to: /usr/sbin/scanmails -oMr scanmails -f $sender_address -bm $recipients
Filter: at end "delivered" is true
Filter: end of processing
after system filter restored uid=0 gid=8 euid=8 egid=8
LOG: 1 MAIN
original recipients ignored (message_filter)
message_filter added |/usr/sbin/scanmails -oMr scanmails -f $sender_address -bm $recipients
Delivery address list:
|/usr/sbin/scanmails -oMr scanmails -f $sender_address -bm $recipients
locked /var/spool/exim/db/retry.lockfile
opened DB file /var/spool/exim/db/retry: flags=0
>>>>>>>>>>>>>>>>>>>>>>>>
Considering: |/usr/sbin/scanmails -oMr scanmails -f $sender_address -bm $recipients
unique = |/usr/sbin/scanmails -oMr scanmails -f $sender_address -bm $recipients:message filter
>>>>>>>>>>>>>>>>>>>>>>>>
After directing:
Local addresses:
|/usr/sbin/scanmails -oMr scanmails -f $sender_address -bm $recipients
Remote addresses:
Failed addresses:
Addresses to be routed:
Deferred addresses:
search_tidyup called
>>>>>> Local deliveries >>>>>>
locked /var/spool/exim/db/retry.lockfile
opened DB file /var/spool/exim/db/retry: flags=0
dbfn_read: key=T:|/usr/sbin/scanmails -oMr scanmails -f $sender_address -bm $recipients@???
delivering |/usr/sbin/scanmails -oMr scanmails -f $sender_address -bm $recipients as |/usr/sbin/scanmails -oMr scanmails -f $sender_address -bm $recipients using address_pipe:
uid=8 gid=8 home=NULL current=/
auxiliary group list: <none>
set_process_info: 8535 3.12 delivering 12p6k8-0002Dd-00 to |/usr/sbin/scanmails -oMr scanmails -f $sender_address -bm $recipients using address_pipe
address_pipe transport entered
shell pipe command before expansion:
/usr/sbin/scanmails -oMr scanmails -f $sender_address -bm $recipients
address_pipe transport returned FAIL
post-process |/usr/sbin/scanmails -oMr scanmails -f $sender_address -bm $recipients
LOG: 0 MAIN
** |/usr/sbin/scanmails -oMr scanmails -f $sender_address -bm $recipients <message filter> T=address_pipe: Expansion of command "/usr/sbin/scanmails -oMr scanmails -f $sender_address -bm $recipients" in address_pipe transport failed: unknown variable name "recipients"
search_tidyup called
set_process_info: 8534 3.12 tidying up after delivering 12p6k8-0002Dd-00
Processing retry items
Succeeded addresses:
Failed addresses:
|/usr/sbin/scanmails -oMr scanmails -f $sender_address -bm $recipients: no retry items
message filter: no retry items
Deferred addresses:
end of retry processing
sending error message to: root@???
writing data block size=354 timeout=0
Exim version 3.12 debug level 99 uid=8 gid=8
probably Berkeley DB version 1.8x (native mode)
charlotte.intern.cats.ms in local_domains? yes (matched *.cats.ms)
Actual local interface address is 127.0.0.1
Actual local interface address is 10.0.1.2
Actual local interface address is 10.0.8.2
Actual local interface address is 10.0.9.2
Caller is an admin user
Caller is a trusted user
sender address =
set_process_info: 8536 3.12 accepting a local non-SMTP message from <>
Sender:
search_tidyup called
>>Original headers (size=197):
X-Failed-Recipients: message filter
From: Mail Delivery System <Mailer-Daemon@???>
To: root@???
Subject: Mail delivery failed: returning message to sender
root@??? in *@localhost? no (end of list)
rewrite_one_header: type=F:
From: Mail Delivery System <Mailer-Daemon@???>
Mailer-Daemon@??? in *@localhost? no (end of list)
rewrite_one_header: type=T:
To: root@???
root@??? in *@localhost? no (end of list)
search_tidyup called
>>Final headers:
P Received: from mail by charlotte.intern.cats.ms with local (Exim 3.12 #1 (Debian))
id 12p6k9-0002Dg-00; Tue, 09 May 2000 11:55:57 +0200
X-Failed-Recipients: message filter
F From: Mail Delivery System <Mailer-Daemon@???>
T To: root@???
Subject: Mail delivery failed: returning message to sender
I Message-Id: <E12p6k9-0002Dg-00@???>
Date: Tue, 09 May 2000 11:55:57 +0200
Data file written for message 12p6k9-0002Dg-00
Writing spool header file
Size of headers = 429
LOG: 0 MAIN
<= <> R=12p6k8-0002Dd-00 U=mail P=local S=1315
exec /usr/sbin/exim -d99 -Mc 12p6k9-0002Dg-00
LOG: 5 MAIN
Error message sent to root@???
message filter: children all complete
Writing spool header file
Exim version 3.12 debug level 99 uid=8 gid=8
probably Berkeley DB version 1.8x (native mode)
charlotte.intern.cats.ms in local_domains? yes (matched *.cats.ms)
Size of headers = 308
LOG: 0 MAIN
Completed
end delivery of 12p6k8-0002Dd-00
Actual local interface address is 127.0.0.1
Actual local interface address is 10.0.1.2
Actual local interface address is 10.0.8.2
Actual local interface address is 10.0.9.2
Caller is an admin user
Caller is a trusted user
set_process_info: 8537 3.12 delivering specified messages
delivering message 12p6k9-0002Dg-00
set_process_info: 8537 3.12 delivering 12p6k9-0002Dg-00
Opened spool file 12p6k9-0002Dg-00-H
user=mail uid=8 gid=8 sender=
sender_local=0 resent=no ident=mail
Non-recipients:
Empty Tree
---- End of tree ----
recipients_count=1
body_linecount=20 message_linecount=8
running system filter as uid=0 gid=8 euid=8 egid=8
Filter: start of processing
Sub-condition is true: $received_protocol is not scanmails
Sub-condition is true: first_delivery
Condition is true: $received_protocol is not scanmails and first_delivery
Condition is true: $sender_address is
Filter: pipe message to: /usr/sbin/scanmails -oMr scanmails -f '<>' -bm $recipients
Filter: at end "delivered" is true
Filter: end of processing
after system filter restored uid=0 gid=8 euid=8 egid=8
LOG: 1 MAIN
original recipients ignored (message_filter)
message_filter added |/usr/sbin/scanmails -oMr scanmails -f '<>' -bm $recipients
Delivery address list:
|/usr/sbin/scanmails -oMr scanmails -f '<>' -bm $recipients
locked /var/spool/exim/db/retry.lockfile
opened DB file /var/spool/exim/db/retry: flags=0
>>>>>>>>>>>>>>>>>>>>>>>>
Considering: |/usr/sbin/scanmails -oMr scanmails -f '<>' -bm $recipients
unique = |/usr/sbin/scanmails -oMr scanmails -f '<>' -bm $recipients:message filter
>>>>>>>>>>>>>>>>>>>>>>>>
After directing:
Local addresses:
|/usr/sbin/scanmails -oMr scanmails -f '<>' -bm $recipients
Remote addresses:
Failed addresses:
Addresses to be routed:
Deferred addresses:
search_tidyup called
>>>>>> Local deliveries >>>>>>
locked /var/spool/exim/db/retry.lockfile
opened DB file /var/spool/exim/db/retry: flags=0
dbfn_read: key=T:|/usr/sbin/scanmails -oMr scanmails -f '<>' -bm $recipients@???
delivering |/usr/sbin/scanmails -oMr scanmails -f '<>' -bm $recipients as |/usr/sbin/scanmails -oMr scanmails -f '<>' -bm $recipients using address_pipe:
uid=8 gid=8 home=NULL current=/
auxiliary group list: <none>
set_process_info: 8538 3.12 delivering 12p6k9-0002Dg-00 to |/usr/sbin/scanmails -oMr scanmails -f '<>' -bm $recipients using address_pipe
address_pipe transport entered
shell pipe command before expansion:
/usr/sbin/scanmails -oMr scanmails -f '<>' -bm $recipients
address_pipe transport returned FAIL
post-process |/usr/sbin/scanmails -oMr scanmails -f '<>' -bm $recipients
LOG: 0 MAIN
** |/usr/sbin/scanmails -oMr scanmails -f '<>' -bm $recipients <message filter> T=address_pipe: Expansion of command "/usr/sbin/scanmails -oMr scanmails -f '<>' -bm $recipients" in address_pipe transport failed: unknown variable name "recipients"
search_tidyup called
set_process_info: 8537 3.12 tidying up after delivering 12p6k9-0002Dg-00
Processing retry items
Succeeded addresses:
Failed addresses:
Deferred addresses:
|/usr/sbin/scanmails -oMr scanmails -f '<>' -bm $recipients: no retry items
message filter: no retry items
end of retry processing
LOG: 0 MAIN
Frozen (delivery error message)
delivery deferred: update_spool=1 header_changed=0
Writing spool header file
Size of headers = 429
end delivery of 12p6k9-0002Dg-00
Regards - Kai Henningsen
--
http://www.cats.ms
Spuentrup CTI Fon: +49 700 CALL CATS (=22 55 22 87)
Windbreede 12 Fax: +49 251 322312 99
D-48157 Muenster Mob: +49 161 322312 1
Germany GSM: +49 171 7755060