In message <[EMAIL PROTECTED]>, Johannes B. Ullrich <[EMAIL PROTECTED]> writes

I am having problems with MySQL 4.0.12 on RedHat Advanced Server 2.1 using a dual Xeon with 8 GByte of RAM.

I have a database collecting logs. Each day, a new table is created. In
order to allow for queries across more than one day, I use 'MERGE'
tables. Each individual table contains 10-30 Million rows. The merge
table covers 30 days (one month).

At the start of a new day, the merge table is rebuild using an 'alter
table' statement. However, this statement is sometimes locked for quite
a while, if queries against the table are pending. In this case,
the context switch rate of the server 'explodes' to 100,000 and higher.
The server becomes essentially unresponsive.

Usually, I can 'fix' things by killing some queries that lock the 'alter
table' querie. However, this causes the server to crash in some cases
(not well reproducable).

Error message from log:
:Snipped.

Can I suggest you try creating a second merge table with a different name and then doing a double rename to swap the two merge tables i.e.
"rename table merge to merge_old, merge_new to merge".


Anyway that's what I'd try next.

Cheers

--
Chad Hanna
Chairman Berkshire Family History Society www.berksfhs.org.uk
Quality Family History Data www.familyhistoryonline.net

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]



Reply via email to