Active Sessions table becomes corrupted every other day.

Christopher Crowley ccrowley@tulane.edu
Tue, 19 Feb 2002 16:29:22 -0600


Hello -

I am using MySQL (3.22.32-log) to backend my 2.2.7 IMP on a Solaris 8 box.

With unacceptable frequency, the active_sessions table is becoming
corrupted.  Every night, I drop the table and recreate it.  At the time this
occurred, there we approximately 12,500 records in the active sessions
table.  From the system logs on the mailserver which IMP connects to, I know
that there are approximately 4,200 unique logins daily.


My questions are:
1. What MySQL tuning parameters is everyone using for their implementations?
Currently, this system ( Sun 450, 2 processors) only has 1GB memory.  A
small amount (200 MB) of swapping is occurring.  I am ordering memory, and
that should help.
****
**** As an aside, when I allowed general access yesterday to an IMP 3.0
implementation
**** with Kronolith and Turba, the swap usage went up to 800 MB, and I had
**** to discontinue access to it.
****

2. Has anyone else experienced this problem with MySQL?  Was it solved by
upgrading?

3. Does anyone else purge active sessions on an hourly, or very frequent
basis?

Thanks.  A little additional info is listed below.




# mysqladmin -p version
Enter password:
mysqladmin  Ver 8.0 Distrib 3.22.32, for sun-solaris2.6 on sparc
TCX Datakonsult AB, by Monty

Server version          3.22.32-log
Protocol version        10
Connection              Localhost via UNIX socket
UNIX socket             /tmp/user_mysql.sock
Uptime:                 5 min 10 sec

Threads: 55  Questions: 7378  Slow queries: 0  Opens: 16  Flush tables: 1
Open tables: 10



# ../../bin/isamchk --force active_sessions
Checking ISAM file: active_sessions
Data records:   12444   Deleted blocks:       0
- check file-size
../../bin/isamchk: error: Size of datafile is: 5864454          Should be:
5959068
- check delete-chain
- check index reference
- check data record references index: 1
../../bin/isamchk: error: Found key at page 240640 that points to record
outside datafile
- check record links
../../bin/isamchk: error: Record-count is not ok; is 12346        Should be:
12444
../../bin/isamchk: warning: Found      12346 parts                Should be:
12523 parts
- recovering ISAM-table 'active_sessions.ISM'
Data records: 12444
Data records: 12346