On a fairly small server where dbmail-util gets run on a nightly basis.
mysql> SELECT count(id) FROM dbmail_physmessage WHERE id NOT IN (SELECT
physmessage_id FROM dbmail_messages);
+-----------+
| count(id) |
+-----------+
| 30365 |
+-----------+
1 row in set (2.14 sec)
mysql> SELECT count(id) FROM dbmail_physmessage;
+-----------+
| count(id) |
+-----------+
| 72994 |
+-----------+
1 row in set (0.04 sec)
mysql> SELECT count(message_idnr) FROM dbmail_messages;
+---------------------+
| count(message_idnr) |
+---------------------+
| 44944 |
+---------------------+
1 row in set (0.25 sec)
mysql>
Anne wrote:
Interesting. How many records do you have in dbmail_physmessage?
Our server:
SELECT count(id) FROM dbmail_physmessage WHERE id NOT IN (SELECT
physmessage_id FROM dbmail_messages);
result: 233753 records
SELECT count(id) FROM dbmail_physmessage
result: 302735 records
SELECT count(message_idnr) FROM dbmail_messages
result: 75369 records
Looks like we can clean up a lot records!
It would be nice to see some other people's stats.
Anne
Thank you Josh for your answer.
I get:
dbmail=> select * from dbmail_physmessage WHERE id NOT IN (SELECT
physmessage_id FROM dbmail_messages);
id | messagesize | rfcsize | internal_date
----+-------------+---------+---------------
(0 rows)
So deleting wouldn't do anything right?
I'm upgrading to 2.2.6. Howecome the debian package number did not
change? After building svn I get: dbmail_2.2.5-1.deb.
Marc
Op 25-jul-2007, om 0:19 heeft Josh Marshall het volgende geschreven:
Hi Marc,
I had the same problem also with 2.2.5, until I ran the following
SQL code:
DELETE FROM dbmail_physmessage WHERE id NOT IN (SELECT
physmessage_id FROM dbmail_messages);
Regards,
Josh.
Marc Dirix wrote:
Repairing DBMAIL for cached header values...
Ok. Found [24] un-cached physmessages.
........................
_______________________________________________
DBmail mailing list
[email protected]
https://mailman.fastxs.nl/mailman/listinfo/dbmail
_______________________________________________
DBmail mailing list
[email protected]
https://mailman.fastxs.nl/mailman/listinfo/dbmail
_______________________________________________
DBmail mailing list
[email protected]
https://mailman.fastxs.nl/mailman/listinfo/dbmail
_______________________________________________
DBmail mailing list
[email protected]
https://mailman.fastxs.nl/mailman/listinfo/dbmail