Previous Thread
Next Thread
Print Thread
Rate Thread
#221386 07/18/2002 10:29 AM
Joined: Apr 2001
Posts: 59
Junior Member
Junior Member
Offline
Joined: Apr 2001
Posts: 59
Everything was dandy with my boards when I went to bed last night.

This morning my boards all have SQL errors inserted all over the page to the tune of:
SQL ERROR: Unable to do_query: UPDATE w3t_Users SET U_SessionId = '8c0469dac676293843590e170b8f17f0' WHERE U_Number = 871
Incorrect key file for table: 'w3t_Users'. Try to repair it

SQL ERROR: Unable to do_query: SELECT COUNT(*) FROM w3t_Users WHERE U_Approved='yes'
Got error 127 from table handler

I WOULD try to go into the admin section to close the boards and run the "Repair" command, but I can't get into thte admin pages. Please someone, give us a helping hand quickly!

Helice
http://forum.foolmoon.com


Sponsored Links
Joined: May 1999
Posts: 3,039
Guru
Guru
Offline
Joined: May 1999
Posts: 3,039
This sounds like you will probably need to do a direct repair of that table. If this is your server then you should be able to run myisamchk on your database files to check and repair corruption. An alternative would be to install something like phpmyadmin which should let you repair the table from a browser.


UBB.threads Developer
Joined: Apr 2001
Posts: 59
Junior Member
Junior Member
Offline
Joined: Apr 2001
Posts: 59
I have phpadmin, but I can't find any option that says "Repair"... can you tell me what to do?

Joined: May 1999
Posts: 3,039
Guru
Guru
Offline
Joined: May 1999
Posts: 3,039
On newer versions of mysql you can normally just do:

REPAIR TABLE w3t_Users


UBB.threads Developer
Joined: Apr 2001
Posts: 59
Junior Member
Junior Member
Offline
Joined: Apr 2001
Posts: 59
Dear Scream,

I've done this, and received the following report from phpmyadmin:

Table Op Msg_type Msg_text
threads.w3t_Users repair info Wrong block with wrong total length starting at 1570136
threads.w3t_Users repair warning Number of rows changed from 631 to 5170
threads.w3t_Users repair status OK


It said "repair status OK", but my pages now have twice as many SQL errors as before the repair. I'm really desperate now.

Sponsored Links
Joined: Apr 2001
Posts: 59
Junior Member
Junior Member
Offline
Joined: Apr 2001
Posts: 59
Whoa! Cancel that...


Out of desperation and fear I ran the REPAIR TABLE w3t_Users command about 25 times...


every time I ran it, it corrected the number of rows in the table until I got a result (finally) that just said OK. And now it appears the SQL errors have vanished!

Thank you so much for giving me the right command to fix it, I was about to drop from an aneurism, but good heavens! Why did this happen, and how can I prevent it from happening again?!

Thank you Scream,

Helice
http://forum.foolmoon.com

Joined: May 1999
Posts: 3,039
Guru
Guru
Offline
Joined: May 1999
Posts: 3,039
Hmm, is that your forum.fullmoon.com site? I just went, registered and logged in and didn't see any sql errors.


UBB.threads Developer
Joined: May 1999
Posts: 3,039
Guru
Guru
Offline
Joined: May 1999
Posts: 3,039
Ah, you replied while I was testing Mysql tables can sometimes get corrupted. Can be a variety of things, even when a hardrive fills up. It definitely shouldn't happen that often. Reports of table corruption here are pretty rare. If it does start to happen frequently it could be a sign of an underlying problem which you might want to talk to your host about if you're on a hosted server.


UBB.threads Developer

Link Copied to Clipboard
Donate Today!
Donate via PayPal

Donate to UBBDev today to help aid in Operational, Server and Script Maintenance, and Development costs.

Please also see our parent organization VNC Web Services if you're in the need of a new UBB.threads Install or Upgrade, Site/Server Migrations, or Security and Coding Services.
Recommended Hosts
We have personally worked with and recommend the following Web Hosts:
Stable Host
bluehost
InterServer
Visit us on Facebook
Member Spotlight
Posts: 70
Joined: January 2007
Forum Statistics
Forums63
Topics37,573
Posts293,925
Members13,849
Most Online5,166
Sep 15th, 2019
Today's Statistics
Currently Online
Topics Created
Posts Made
Users Online
Birthdays
Top Posters
AllenAyres 21,079
JoshPet 10,369
LK 7,394
Lord Dexter 6,708
Gizmo 5,833
Greg Hard 4,625
Top Posters(30 Days)
Top Likes Received
isaac 82
Gizmo 20
Brett 7
Morgan 2
Top Likes Received (30 Days)
None yet
The UBB.Developers Network (UBB.Dev/Threads.Dev) is ©2000-2024 VNC Web Services

 
Powered by UBB.threads™ PHP Forum Software 8.0.0
(Preview build 20221218)