The following issue has been SUBMITTED.
======================================================================
http://dbmail.org/mantis/view.php?id=673
======================================================================
Reported By: cmayo
Assigned To:
======================================================================
Project: DBMail
Issue ID: 673
Category: Command-Line programs (dbmail-users, dbmail-util)
Reproducibility: always
Severity: minor
Priority: normal
Status: new
target:
======================================================================
Date Submitted: 28-Jan-08 19:31 CET
Last Modified: 28-Jan-08 19:31 CET
======================================================================
Summary: dbmail-util -a hangs on physmessage integrity check
Description:
After upgrading from 2.2.5 to 2.2.8 (PostgreSQL 8.2.6) dbmail-util -ay
hangs on:
Repairing DBMAIL messageblocks integrity...
Ok. Found [0] unconnected messageblks.
Repairing DBMAIL physmessage integrity...
"SELECT * FROM pg_stat_activity" revealed the culprit to be:
"SELECT COUNT(*) FROM dbmail_physmessage WHERE id NOT IN (SELECT
physmessage_id FROM dbmail_messages)"
Testing the query on its own it does indeed run on and on. Replacing the
IN with a LEFT JOIN seems to fix the problem for me, returning in a few
hundred ms. I've attached a patch - also for the cleanup operation which I
haven't tested yet (the test has revealed 4 orphan physmessages so I'm glad
the check is there and I may try and recreate some messages entries for
them).
======================================================================
Issue History
Date Modified Username Field Change
======================================================================
28-Jan-08 19:31 cmayo New Issue
28-Jan-08 19:31 cmayo File Added: dbmail-2.2.8-check_physmessages.patch
======================================================================
_______________________________________________
Dbmail-dev mailing list
[email protected]
http://twister.fastxs.net/mailman/listinfo/dbmail-dev