View Full Version : Crashed mySQL database table
Hi,
I have been running a Coppermine photo gallery successfully for the last year and a half but it suddenly crashed on 20 August 2007.
On debug mode I found out the following:
---------
Table './raniasplacec_coppermine2/cpg_pictures' is marked as crashed and should be repaired
---------
I ran the query 'Repair table cpg_pictures', but I got the similar message again:
--------
Error
SQL query:
SELECT `cpg_pictures`. *
FROM cpg_pictures
LIMIT 0 , 30
MySQL said:
#145 - Table './raniasplacec_coppermine2/cpg_pictures' is marked as crashed and should be repaired
---------
Coppermine Gallery Support team took me through all the above steps and also asked me to update my version, which I did. In the end they told me that it is not a Coppermine Gallery problem and I should contact my webhost support.
I contacted Powweb support they replied:
-------------
We apologize for the inconvenience this may have caused you. We are aware of the issue you’re facing with MySQL server. Currently, our engineers are working to resolve the issue as soon as possible. Once the issue is resolved, you will be able to access your MySQL database.
If you have any further questions, please don't hesitate to contact us. We are available 24x7.
-------------
I don't know much about mysql databases, as far as I am concerned I can access the the database, it just does not repair the crashed table on submitting query.
I am afraid that if no one is able to help me, I will lose my photo gallery.
Any suggestions/advice?
Thanks.
There are a number of on-going issues at present with MySql database access and creation.
If you can, I'd wait until they're resolved.
Croc Hunter
8-24-07, 10:02 AM
Wait? You can't be serious Ian? They have waited 4 days!
First make a backup of your current tables not overwriting your existing backup (obviously you logged into phpMyAdmin to run the query). Run a repair on all tables.
To run a repair on all tables:
1. Login to the database through OPS> Services> MySQL> click "Administer" for the database.
2. Click the name of the database on the left hand side, wait until all the tables appear.
3. On the right hand side scroll to the bottom.
4. Click on "Check All"
5. From the "With selected" drop down box choose "'Repair table" from the list.
Failing this I would look at restoring your last working database you had saved.
Let me know how you go.
Resubmit your original ticket number via email.
Get on the phone and work with them to fix it.
Don't just wait.
dmacminn
8-24-07, 10:11 AM
Thanks for the helpful outline of "How" to perform a table repair ... However, it should be noted that the procedure works with tables that are only slightly damaged, and the database should not be "in use" when the repair is run -- I've repaired more than one table out of existence using the "Repair Table" tool!
In most situations where you see a crashed table like this, you should:
1) restore the damaged table from backup (you can check the MySQL console for existing backups -- but, you may often need one of your own
from a previous period, since the system keeps, at most 3 days)
2) re-index, etc. if and as necessary
3) upgrade the application to a newer version...
The above is the advice you should be given re the issue (since in Technical Support we don't actually support applications and their files/databases at all) --- so, I suggest doing it yourself, that way you know which version was used and you're probably more familiar with the application and how it should behave than the average support team member.
BTW: This is the first Coppermine instance I've heard of, but older versions of OSCommerce and the occasional phpBB2 seem to occasionally show this behavior due to the differences in Version 4 to Version 5 of MySQL.
Croc Hunter
8-24-07, 11:11 AM
So you looked at this customers account, couldn't "fix" it and escalated his ticket for him? I hope so. Tell the rep what they "should" have advised the customer as you rightly pointed out. Or as you too are "Technical" Support Staff is your advice even more unsupported than that of the rep this customer initally wrote to?
We the customer really dont care how if it's 6 before 1 or 1 before 6. We just expect you not to break our websites and when you do, 'support' to give a "fix" in a timely manner.
dmacminn
8-24-07, 11:35 AM
No ... I didn't look at the site/ticket ... I'm just speaking generally...
Unfortunately, we continue to open a fair number of tickets for things that we're not really the best people to have working on it ... that's unfortunate because things that we rarely do - rarely get done well or quickly.... and it can cause a delay, before someone gets a handle on the issue and discovers that it really simply relates to needing a database restore, or whatever...
As the Forum is about people finding answers for things that aren't supported by Tech Support -- I will continue to advocate that people use the best solution available to them ...
Would you rather do the research and ask the questions and then do backup/restore/repair yourself -- or have someone in T.S. who rarely touches the customer-side of MySQL try this for you?
I fully understand that people "expect" that "since we're responsible for breaking it, we have to fix it" -- I get lots of those calls every day ----
The unfortunate reality is, that while we know that there are going to be some problems caused by the change from MySQL V4 to MySQL5, problems with your applications/databases continue to be your ultimate responsibility and, you are the best person to address them...
An issue doesn't become something we provide support on (and T.S aren't going to be trained on it) because the version offered is changing ... that's why we sent the notices -- so you could prepare for the problems and take whatever precautions are needful.
So, again ... I'd rather teach you to fish...
In this case -- in any case, where a Database is corrupted or a table damaged
You should follow the above procedure -- as soon as the system is stable and you can accomplish it. Ask questions here if you need assistance ... it is far more immediate than the escalation system (since Tier1 are rarely going to even touch a database at all). Don't wait for support ... you need to download the available backups to preserve them (if you wait the 24-48 hours to hear back, the required on-system database may have already disappeared).
The reality is, that most of Technical Support are not webdesigners/webdevelopers or database experts/users -- they are trained to support the system/network services and troubleshoot issues relating to the common server-side things that stop working ... How does Coppermine work? How is it installed? What are its issues? Dunno. Never used it....
My point here, (and I do have one), is simply this -- I would offer that YOU should try to handle issues/problems with your website applications/files/database and that you should try to get help with that here in the forum. There are many people here with much more experience with particular applications, their installation, problems, fixes, idiosyncrasies, etc., than you would find in Technical Support, generally.
So, in short, the best answers for these kinds of issues are here ... TS don't support the applications generally, so, unless its a systemic issue, you're not
going to get much useful help form the T.S. team....
While I understand the motivation behind the argument "you broke it, you fix it" -- unfortunately, unless its a system issue, it comes down to "you installed it, you maintain it".
We know there are going to be issues flowing out of the upgrade ... surely we can all agree that the "best/most timely" solution is what you want ... and in many cases, for better or worse, that's going to mean finding out how to do it yourself.
Croc Hunter
8-24-07, 12:59 PM
You raised many valid points and I agree, we the customer are ultimately responsible for anything we place in our webspace here. I don't want an engineer to fix my gallery, they usually have no clue what Coppermine, Gallery etc even is.
So many here complain about "canned" responses from support. When I email, or call an official "Support" rep, 'Just ride it out and we'll fix it in time' is not good enough. This customer did the right thing. Contacted official support and were not given the correct response. I have a headset, Powweb pays these cluless offshore support reps when there is such a wealth of knowledge in your own backyard. Powweb was built on that cornerstone.
Somebody needs to step up and kick the actual support rep in this case. As many who are in the know here suggest, communication is key. A customer should not have to wait this long or goto such lengths to get a gallery "fixed".
Point is dmacminn: Their photo gallery is still not fixed.
My only curiousity is that bibijee states the DB crashed on the 20th and they worked with Coppermine Support. When was the ticket actually called in to PowWeb? There's no info on that in the thread.
Like I said, just curious.
troycawley
8-24-07, 02:52 PM
Unfortunately, we continue to open a fair number of tickets for things that we're not really the best people to have working on it ...
As the Forum is about people finding answers for things that aren't supported by Tech Support ...
The unfortunate reality is [...] problems with your applications/databases continue to be your ultimate responsibility and, you are the best person to address them...
...Don't wait for support ... TS don't support the applications generally, so, unless its a systemic issue, you're not going to get much useful help form the T.S. team....
This was a very eye-opening post, dmacminn. If one doesn' t realize that they have procured a "Wal-Mart" type of hosting following that post, s/he is not listening.
This is not meant to be inflammatory. I am not bashing Powweb...or Wal-Mart, for that matter. Both serve a very good purpose.
But I wouldn't run a business site (that requires rock-solid service and server-side tech support) on Powweb. Just as I wouldn't run a business on computers I bought from Wal-Mart.
Of course, nobody is suggesting that, but I just wanted to thank you for your candor. I truly appreciate your posts. Keep up the good work. I know it must be frustrating to try to help folks after the proverbial wasps' nest has been stirred.
Sorry if I was a bit off-topic, so...to try to get back on-topic:
This also illustrates the importance of backing up your databases! Obviously, you might not be able to rely on the tools available here. If you need that, then some other (more expensive) host would be better suited for your needs.
That doesn't help much, does it, bibijee? Well, hopefully you'll be gracious enough to post your ultimate solution here, so we poor saps can help ourselves when confronted with a similar problem...
Thanks for the discussion and everyone's input.
Croc Hunter, I will do as you suggested and get back to you. Thanks.
Doc C, I worked with Coppermine support on the 21st, emailed Powweb support on the 22nd and they got back to me on the 23rd.
Croc Hunter,
I can't access the database right now as the mysqladmin is giving a server error in the left frame.
After reading most of the discussion in this thread, I somehow am not very hopeful of a positive outcome ultimately. Do you think it would be quicker if I delete the Coppermine database and reinstall the whole program again? I will lose some data and it will be a lot of work but in the end I can be sure to restore my photo gallery.
What do you think?
I think Coppermine stores uploaded pictures in the albums\userpics directory. I know that I've downloaded the contents of those before when I moved a site from another.
I just re-uploaded the pictures after creating new IDs for the users.
Croc Hunter
8-25-07, 01:07 AM
Croc Hunter,
I can't access the database right now as the mysqladmin is giving a server error in the left frame. ..[sanip].. What do you think?I've had the same problem over the last week. I kept trying every 10-20 mins until I did get the left frame to work correctly. I wouldn't delete/reinstall just yet. All I can suggest is to keep trying until you get the left frame.
HalfaBee
8-25-07, 01:47 AM
I gave up and installed the latest version of phpmyadmin, that fixed the left pane problem.
The version in ops seems to work ok now.
HalfaBee, could you give a hint as to how to do that? Thanks.
Croc Hunter, I'll wait and try to have a go at repairing the tables before resorting to drastic measures. Thanks.
I was able to access database just now. Tried repairing all the tables. All tables were repaired with an OK message except for the crashed 'pictures' table. The message in front of it said 'Table is already up to date'. And my photo gallery is still not working. I think I will look at other options now.
HalfaBee
8-25-07, 04:46 AM
Can you restore the table from a backup?
You can download the current phpmyadmin from www.phpmyadmin.net
omegaman66
8-25-07, 04:53 AM
The update killed my gallery2 installation after running for a very very long time. I had had to bite the bullet and reinstall. Switched to coppermine. I think coppermine is better myself.
Well, I dropped the database and re-installed coppermine, uploaded my photos to the gallery and my photo gallery is up and running again. I just need to customize the theme now.
Thanks everyone.
bibijee, now that you've got it fixed make sure to back up those folders I mentioned. It makes it easier to fix things. Just MHO.
I will, Doc C. Learned my lesson the hard way:)
vBulletin v3.6.0, Copyright ©2000-2009, Jelsoft Enterprises Ltd.