List Info

Thread: FW: maia_mail keeps growin




FW: maia_mail keeps growin
country flaguser name
Netherlands
2007-06-29 07:40:37
Report to the list to ;)

-----Oorspronkelijk bericht-----
Van: Erik Weber [mailto:twiztargmail.com] 
Verzonden: vrijdag 29 juni 2007 14:39
Aan: Michiel van den Berg
Onderwerp: Re: [Maia-users] maia_mail keeps growin

Michiel van den Berg wrote:
> Yes, im just doing that. Added some debug info to. It
says its
deleting all the mail for id=x but it actually doesn't do
this. For
example:
>
> 2007-06-29 12:26:51 Maia: [process-quarantine-sub]
Learned mail item
3320 as spam and reported it
> 2007-06-29 12:26:51 Maia: [process-quarantine-sub]
Deleted
spam/non-spam recipient references to mail item 3320 type C
> 2007-06-29 12:26:51 Maia: [process-quarantine-sub]
Retaining mail item
3320, since it still has recipient references.
> 2007-06-29 12:26:51 Maia: [process-quarantine-sub]
TIMING [total 1556
ms] - msg-prep: 5 (0%), send-report: 1549 (100%),
delete-mail: 3 (0%),
rundown: 0 (0%)
>
> DB:
> 3320  	20  	C  	expired203320
> 3320 		31 	C 	expired313320
>
> If I remove 1 of the lines from the DB in
maia_mail_recieved, it does
actually delete the other entry & mail entry to. But as
long as there
are 2 or more lines. It doesn't delete them.
>
> It does seem like the delete statement in
process-quarantine-sub is
good. The amavis user I use for db connectivity also has the
proper
delete right as I can manually delete a row when logged in
as that user.
And it also deletes the row if there is only 1 on the ID.
Besides that I
really have no clue whats going on at this moment. But I
will keep
debugging.
>
>   
The mail wouldn't happen to have multiple recipients?

-- 
Erik
_______________________________________________
Maia-users mailing list
Maia-usersrenaissoft.com
http://www.renaissoft.com/mailman/listinfo/maia-users

Re: FW: maia_mail keeps growin
country flaguser name
Netherlands
2007-06-29 08:03:40
Here is where it goes wrong, in process-quarantine-sub.pl

I even tried replacing the '?' in the $delete var with
actual entries in
the db, but even that is failing. It seems my mysql or perl
doesn't like
to remove 2 entries at a time if using below query.

I tried putting the query in the mysql commandline client
and in
phpmyadmin, but both just accept it.


# Delete mail references for all recipients who agree
# that the mail item is [spam|ham].
    $delete = "DELETE FROM maia_mail_recipients "
.
              "WHERE mail_id = ? AND type = ?";
    $sth = $dbh->prepare($delete)
               or fatal(sprintf("Couldn't prepare
query: %s",
$dbh->errstr));
    $sth->execute($mail_id,$type)
        or fatal(sprintf("Couldn't execute query:
%s", $dbh->errstr));
    if ($debug) {
        output(sprintf("Deleted spam/non-spam recipient
references to
mail item %d type %s", $mail_id, $type));
    }

-----Oorspronkelijk bericht-----
Van: maia-users-bouncesrenaissoft.com
[mailto:maia-users-bouncesrenaissoft.com] Namens
Michiel van den Berg
Verzonden: vrijdag 29 juni 2007 14:41
Aan: Maia
Onderwerp: [Maia-users] FW: maia_mail keeps growin


Report to the list to ;)

-----Oorspronkelijk bericht-----
Van: Erik Weber [mailto:twiztargmail.com] 
Verzonden: vrijdag 29 juni 2007 14:39
Aan: Michiel van den Berg
Onderwerp: Re: [Maia-users] maia_mail keeps growin

Michiel van den Berg wrote:
> Yes, im just doing that. Added some debug info to. It
says its
deleting all the mail for id=x but it actually doesn't do
this. For
example:
>
> 2007-06-29 12:26:51 Maia: [process-quarantine-sub]
Learned mail item
3320 as spam and reported it
> 2007-06-29 12:26:51 Maia: [process-quarantine-sub]
Deleted
spam/non-spam recipient references to mail item 3320 type C
> 2007-06-29 12:26:51 Maia: [process-quarantine-sub]
Retaining mail item
3320, since it still has recipient references.
> 2007-06-29 12:26:51 Maia: [process-quarantine-sub]
TIMING [total 1556
ms] - msg-prep: 5 (0%), send-report: 1549 (100%),
delete-mail: 3 (0%),
rundown: 0 (0%)
>
> DB:
> 3320  	20  	C  	expired203320
> 3320 		31 	C 	expired313320
>
> If I remove 1 of the lines from the DB in
maia_mail_recieved, it does
actually delete the other entry & mail entry to. But as
long as there
are 2 or more lines. It doesn't delete them.
>
> It does seem like the delete statement in
process-quarantine-sub is
good. The amavis user I use for db connectivity also has the
proper
delete right as I can manually delete a row when logged in
as that user.
And it also deletes the row if there is only 1 on the ID.
Besides that I
really have no clue whats going on at this moment. But I
will keep
debugging.
>
>   
The mail wouldn't happen to have multiple recipients?

-- 
Erik
_______________________________________________
Maia-users mailing list
Maia-usersrenaissoft.com
http://www.renaissoft.com/mailman/listinfo/maia-users
_______________________________________________
Maia-users mailing list
Maia-usersrenaissoft.com
http://www.renaissoft.com/mailman/listinfo/maia-users

Re: FW: maia_mail keeps growin
country flaguser name
Canada
2007-06-29 14:26:10
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Michiel van den Berg wrote:

>> 2007-06-29 12:26:51 Maia: [process-quarantine-sub]
Learned mail item
> 3320 as spam and reported it
>> 2007-06-29 12:26:51 Maia: [process-quarantine-sub]
Deleted
> spam/non-spam recipient references to mail item 3320
type C
>> 2007-06-29 12:26:51 Maia: [process-quarantine-sub]
Retaining mail item
> 3320, since it still has recipient references.
>> 2007-06-29 12:26:51 Maia: [process-quarantine-sub]
TIMING [total 1556
> ms] - msg-prep: 5 (0%), send-report: 1549 (100%),
delete-mail: 3 (0%),
> rundown: 0 (0%)
>> DB:
>> 3320  	20  	C  	expired203320
>> 3320 		31 	C 	expired313320
>>
>> If I remove 1 of the lines from the DB in
maia_mail_recieved, it does
> actually delete the other entry & mail entry to.
But as long as there
> are 2 or more lines. It doesn't delete them.

To a point this is correct behaviour--Maia sees that the
mail item
(3320) has more than one recipient (20 and 31), so it won't
actually
delete the mail item until all of those recipients have
passed judgment
on it (or it becomes too old and gets expired by
expire-quarantine-cache.pl).

What seems wrong, though, is that in this example both of
these items
have apparently been confirmed (type 'C'), which means that
all of the
recipients /have/ expressed their opinion of the mail item. 
In that
case, the item should have been deleted.


> The amavis user I use for db connectivity also has the
proper
> delete right as I can manually delete a row when logged
in as that user.

This statement seems to contradict what you said in later
posts, where
you showed an attempt to delete a row manually from the
command line and
showed that this had no effect.

- --
Robert LeBlanc <rjlrenaissoft.com>
Renaissoft, Inc.
Maia Mailguard <http://www.maiamail
guard.com/>

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (GNU/Linux)

iD8DBQFGhVzSGmqOER2NHewRAgJ1AKCM7JPkxcdSff9b8gwn6d3J3s5AfgCd
HGnv
S8Hyaj3hKvAFz/BSvUV5VLw=
=MwHD
-----END PGP SIGNATURE-----
_______________________________________________
Maia-users mailing list
Maia-usersrenaissoft.com
http://www.renaissoft.com/mailman/listinfo/maia-users

Re: FW: maia_mail keeps growin
country flaguser name
Canada
2007-06-29 14:36:31
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Robert LeBlanc wrote:

> What seems wrong, though, is that in this example both
of these items
> have apparently been confirmed (type 'C'), which means
that all of the
> recipients /have/ expressed their opinion of the mail
item.  In that
> case, the item should have been deleted.

Just to follow up on this, are you sure there are no other
rows with
that mail ID but with types other than 'C'?  You showed two
rows for
item 3320, both with type 'C', but perhaps that was because
of the query
you were using.  Try not selecting on the mail type, e.g.

 SELECT * FROM maia_mail_recipients WHERE mail_id = 3320;

If you see additional rows with types other than 'C'
(confirmed spam) or
'G' (confirmed ham), that would explain why
process-quarantine is not
deleting the item.  If it sees that some recipients still
haven't judged
the item yet (i.e. it is type 'S' (suspected spam) or 'H'
(suspected
ham)), then it retains the item.

If that turns out to be the case, also take a look at the
mail item
itself to verify the number of recipients (in the
maia_mail.envelope_to
column).  Does the number of recipients match the number of
rows in the
earlier query?

- --
Robert LeBlanc <rjlrenaissoft.com>
Renaissoft, Inc.
Maia Mailguard <http://www.maiamail
guard.com/>

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (GNU/Linux)

iD8DBQFGhV8/GmqOER2NHewRAmItAKCUz/kq69iUKmbNBsRtwILH2ALaYACg
q9p1
4SqZsYpAEfYqCXXk8vN/YEU=
=vWBQ
-----END PGP SIGNATURE-----
_______________________________________________
Maia-users mailing list
Maia-usersrenaissoft.com
http://www.renaissoft.com/mailman/listinfo/maia-users

[1-4]

about | contact  Other archives ( Real Estate discussion Medical topics )