artifex maximus,

> The system: FreeBSD 4.11, sendmail 8.13.3, amavisd-new 2.3.2, perl 5.8.7
> Sometimes I get the following message

> (j74EV955013392) run_command: [13395] /usr/bin/file p001 </dev/null 2>&1
> (j74EV955013392) result line from file(1): p001: ASCII English text
> (j74EV955013392) lookup_re("ASCII English text") matches key...
> (j74EV955013392) File-type of p001: ASCII English text; (asc)
> (j74EV955013392) TROUBLE in check_mail: parts_decode_ext FAILED: Error
> reading from file(1) utility: \
>  Operation not supported by device at (eval 64) line 153, <GEN187> line 1.

Looks like another manifestation of the PerlIO sloppy I/O status returns,
which escalated with perl 5.8.7 returning EAGAIN instead of a success
at end of data from a pipe, but in your case perhaps it returns status ENODEV.
More insight might be gained by truss -f, or you may just try ignoring
that particular status, as apparently the data lines read are just fine:

--- amavisd~    Wed Jun 29 12:26:11 2005
+++ amavisd     Wed Aug 17 00:21:19 2005
@@ -12959,5 +12959,5 @@
   @EXPORT_OK = qw(&init &decompose_part &determine_file_types);
 }
-use Errno qw(ENOENT EACCES EAGAIN);
+use Errno qw(ENOENT EACCES EAGAIN ENODEV);
 use IO::File qw(O_CREAT O_EXCL O_WRONLY);
 use File::Basename qw(basename);
@@ -13099,5 +13099,5 @@
       }
     }
-    defined $ln || $!==0 || $!==EAGAIN
+    defined $ln || $!==0 || $!==EAGAIN || $!==ENODEV
       or die "Error reading from file(1) utility: $!";
     if ($index < @part_list) {
-----------------

> Mark said before to try file itself. I did:
> root# su vscan
> $ /usr/bin/file p001 </dev/null 2>&1
> p001: ASCII English text
> $ echo $?
> 0

More experimentation with Perl I/O reading from a pipe would be interesting.
Could be that Perl 5.8.7 on FreeBSD 4.11 behaves differently than on FreeBSD 
5.4.

> The bonus question :) is how could I requeue this kind of messages?

If less that few days have passed since the problem, the message is
still at the sending MTA's queue and should be retried every so often,
so no manual action is necessary.

Its copy is also in the file:
  /var/amavis/amavis-milter-j74EV955013392/email.txt
which you may re-send by examining the envelope addresses
from the logs, then:
  sendmail -i -f sender recip1 recip2 ... 
</var/amavis/amavis-milter-j74EV955013392/email.txt
(recipients may eventually receive two copies if you do this manually)

  Mark


-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
_______________________________________________
AMaViS-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/amavis-user
AMaViS-FAQ:http://www.amavis.org/amavis-faq.php3
AMaViS-HowTos:http://www.amavis.org/howto/

Reply via email to