Can't get rid of the .header files in the incoming directory....
Take 2, more info...
Spike Cacti
spike_cacti at YAHOO.COM
Fri Apr 29 15:16:05 IST 2005
These are the files in 1 of the incoming directory.
-rw------- 1 postfix postfix 560 Apr 29
09:26 0F9925018B.2FCCA.header
-rw------- 1 postfix postfix 655 Apr 29
09:25 1113150180.90685.header
-rw------- 1 postfix postfix 492 Apr 29
09:38 1505750245.D9F99.header
-rw------- 1 postfix postfix 661 Apr 29
09:25 3740C50181.BB3CC.header
-rw------- 1 postfix postfix 654 Apr 29
09:26 377DC50192.2C0F7.header
-rw------- 1 postfix postfix 642 Apr 29
09:28 3FD34501AA.CE42A.header
-rw------- 1 postfix postfix 664 Apr 29
09:30 41F3D501DB.150E6.header
-rw------- 1 postfix postfix 753 Apr 29
09:36 4D89550227.E5E08.header
-rw------- 1 postfix postfix 600 Apr 29
09:37 555DF50251.EC685.header
-rw------- 1 postfix postfix 696 Apr 29
09:31 56614501F1.7145D.header
-rw------- 1 postfix postfix 2145 Apr 29
09:36 62EF75022F.4DB55.header
-rw------- 1 postfix postfix 702 Apr 29
09:37 646E450246.E6DCE.header
-rw------- 1 postfix postfix 672 Apr 29
09:37 7FDEA5024D.66BD8.header
-rw------- 1 postfix postfix 2100 Apr 29
09:26 9B7B150180.60E20.header
-rw------- 1 postfix postfix 633 Apr 29
09:38 9BC5F50245.C8FE3.header
-rw------- 1 postfix postfix 1463 Apr 29
09:26 A169B50174.CC622.header
-rw------- 1 postfix postfix 651 Apr 29
09:25 B6CB450174.15372.header
-rw------- 1 postfix postfix 1256 Apr 29
09:27 BF8845019F.C5637.header
-rw------- 1 postfix postfix 1284 Apr 29
09:35 D7A7D50211.2B245.header
-rw------- 1 postfix postfix 454 Apr 29
09:26 E01FD50192.27BEE.header
-rw------- 1 postfix postfix 765 Apr 29
09:25 F1DCC5017F.056E1.header
Doing a strace, I can see the following :
chdir("/var/spool/MailScanner/incoming/15462") = 0
open(".", O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY)
= 6
fstat64(6, {st_mode=S_IFDIR|0700, st_size=360, ...}) =
0
fcntl64(6, F_SETFD, FD_CLOEXEC) = 0
getdents64(6, /* 18 entries */, 4096) = 808
stat64("4D89550227.E5E08", {st_mode=S_IFDIR|0700,
st_size=80, ...}) = 0
unlink("E5E08.header") = -1 ENOENT
(No such file or directory)
stat64("4D89550227.E5E08.header",
{st_mode=S_IFREG|0600, st_size=753, ...}) = 0
unlink("2B245.header") = -1 ENOENT
(No such file or directory)
stat64("D7A7D50211.2B245.header",
{st_mode=S_IFREG|0600, st_size=1284, ...}) = 0
unlink("7145D.header") = -1 ENOENT
(No such file or directory)
stat64("56614501F1.7145D.header",
{st_mode=S_IFREG|0600, st_size=696, ...}) = 0
unlink("150E6.header") = -1 ENOENT
(No such file or directory)
stat64("41F3D501DB.150E6.header",
{st_mode=S_IFREG|0600, st_size=664, ...}) = 0
unlink("CE42A.header") = -1 ENOENT
(No such file or directory)
stat64("3FD34501AA.CE42A.header",
{st_mode=S_IFREG|0600, st_size=642, ...}) = 0
unlink("C5637.header") = -1 ENOENT
(No such file or directory)
stat64("BF8845019F.C5637.header",
{st_mode=S_IFREG|0600, st_size=1256, ...}) = 0
unlink("2C0F7.header") = -1 ENOENT
(No such file or directory)
stat64("377DC50192.2C0F7.header",
{st_mode=S_IFREG|0600, st_size=654, ...}) = 0
unlink("27BEE.header") = -1 ENOENT
(No such file or directory)
stat64("E01FD50192.27BEE.header",
{st_mode=S_IFREG|0600, st_size=454, ...}) = 0
unlink("60E20.header") = -1 ENOENT
(No such file or directory)
stat64("9B7B150180.60E20.header",
{st_mode=S_IFREG|0600, st_size=2100, ...}) = 0
unlink("2FCCA.header") = -1 ENOENT
(No such file or directory)
stat64("0F9925018B.2FCCA.header",
{st_mode=S_IFREG|0600, st_size=560, ...}) = 0
unlink("CC622.header") = -1 ENOENT
(No such file or directory)
stat64("A169B50174.CC622.header",
{st_mode=S_IFREG|0600, st_size=1463, ...}) = 0
unlink("90685.header") = -1 ENOENT
(No such file or directory)
stat64("1113150180.90685.header",
{st_mode=S_IFREG|0600, st_size=655, ...}) = 0
unlink("056E1.header") = -1 ENOENT
(No such file or directory)
stat64("F1DCC5017F.056E1.header",
{st_mode=S_IFREG|0600, st_size=765, ...}) = 0
unlink("BB3CC.header") = -1 ENOENT
(No such file or directory)
stat64("3740C50181.BB3CC.header",
{st_mode=S_IFREG|0600, st_size=661, ...}) = 0
I am not an expert, but I think it's unlinking with
the wrong filename....
Could have to do with this code in WorkArea.pm, sub
ClearAll :
# Clean up the whole thing
while($f = $dirhandle->read()) {
#print STDERR "Studying \"$f\"\n";
next if $f =~ /^\./;
# Needs untaint:
$f =~ /([-\w]+\.header)$/ and unlink "$1";
# And delete core files
$f =~ /^core$/ and unlink "core";
# Also needs untaint... sledgehammer. nut.
$f =~ /(.*)/;
push @ToDelete, $1 if -d "$1";
}
$dirhandle->close();
Maybe due to the fact that you added a new header
section in the name for Postfix queue files ? I dont
think your regexp will match names like :
377DC50192.2C0F7.header
I could also be totally wrong ;-) I just took a very
quick look...
Spike
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
------------------------ MailScanner list ------------------------
To unsubscribe, email jiscmail at jiscmail.ac.uk with the words:
'leave mailscanner' in the body of the email.
Before posting, read the Wiki (http://wiki.mailscanner.info/) and
the archives (http://www.jiscmail.ac.uk/lists/mailscanner.html).
Support MailScanner development - buy the book off the website!
More information about the MailScanner
mailing list