I went to log on to one my my sites & got the following message. I actually get logged on and when I type in the url again, I am logged in and my admin menu is there. I don't want to do anything until I can fix the problem. Any suggestions?
I am using Drupal 6.
Thanks for any help.
Hewie
Warning: Table './seminol2_mgsdrupal/watchdog' is marked as crashed and should be repaired query: INSERT INTO watchdog (uid, type, message, variables, severity, link, location, referer, hostname, timestamp) VALUES (1, 'php', '%message in %file on line %line.', 'a:4:{s:6:\"%error\";s:12:\"user warning\";s:8:\"%message\";s:532:\"Table './seminol2_mgsdrupal/watchdog' is marked as crashed and should be repaired\nquery: INSERT INTO watchdog\n (uid, type, message, variables, severity, link, location, referer, hostname, timestamp)\n VALUES\n (1, 'user', 'Session opened for %name.', 'a:1:{s:5:\"%name\";s:5:\"admin\";}', 5, '', 'http://www.seminolemastergardenershow.org/user', 'http://www.seminolemastergardenershow.org/user', '99.170.247.253', 1276862391)\& in /home/seminol2/public_html/includes/database.mysqli.inc on line 128
Warning: Table './seminol2_mgsdrupal/watchdog' is marked as crashed and should be repaired query: INSERT INTO watchdog (uid, type, message, variables, severity, link, location, referer, hostname, timestamp) VALUES (1, 'php', '%message in %file on line %line.', 'a:4:{s:6:\"%error\";s:7:\"warning\";s:8:\"%message\";s:138:\"Cannot modify header information - headers already sent by (output started at /home/seminol2/public_html/includes/database.mysqli.inc:128)\";s:5:\"%file\";s:47:\"/home/seminol2/public_html/includes/session.inc\";s:5:\"%line\";i:99;}', 3, '', 'http://www.seminolemastergardenershow.org/user', 'http://www.seminolemastergardenershow.org/user', '99.170.247.253', 1276862391) in /home/seminol2/public_html/includes/database.mysqli.inc on line 128
Warning: Table './seminol2_mgsdrupal/watchdog' is marked as crashed and should be repaired query: INSERT INTO watchdog (uid, type, message, variables, severity, link, location, referer, hostname, timestamp) VALUES (1, 'php', '%message in %file on line %line.', 'a:4:{s:6:\"%error\";s:7:\"warning\";s:8:\"%message\";s:154:\"session_regenerate_id() [function.session-regenerate-id]: Cannot regenerate session id - headers already sent\";s:5:\"%file\";s:47:\"/home/seminol2/public_html/includes/session.inc\";s:5:\"%line\";i:102;}', 3, '', 'http://www.seminolemastergardenershow.org/user', 'http://www.seminolemastergardenershow.org/user', '99.170.247.253', 1276862391) in /home/seminol2/public_html/includes/database.mysqli.inc on line 128
Warning: Table './seminol2_mgsdrupal/watchdog' is marked as crashed and should be repaired query: INSERT INTO watchdog (uid, type, message, variables, severity, link, location, referer, hostname, timestamp) VALUES (1, 'php', '%message in %file on line %line.', 'a:4:{s:6:\"%error\";s:7:\"warning\";s:8:\"%message\";s:138:\"Cannot modify header information - headers already sent by (output started at /home/seminol2/public_html/includes/database.mysqli.inc:128)\";s:5:\"%file\";s:46:\"/home/seminol2/public_html/includes/common.inc\";s:5:\"%line\";i:345;}', 3, '', 'http://www.seminolemastergardenershow.org/user', 'http://www.seminolemastergardenershow.org/user', '99.170.247.253', 1276862391) in /home/seminol2/public_html/includes/database.mysqli.inc on line 128
Comments
You need to repair the mysql table
Hewie,
You need to repair that table in mysql. Do you have access to phpmyadmin or other database access tool? If so there should be an option to choose that table or the whole database and run a repair on it. I would backup the whole thing first before doing any operations at the db level. Luckily it is your watchdog table so if it has to be emptied it will not affect your site.
www.rightsprocket.com
DB Problems
Something bad has happened to your mysql database. Lets just hope it's confined to the watchdog table. You do have a few options.
1) (preferred) Using a tool like phpMyAdmin "repair" the table. In phpMyAdmin go into the table and then click on operations. There should be a repair option somewhere on that page (it's changed locations between phpMyAdmin versions).
2) (If #1 doesn't work) Remove the watchdog table (destroying all data in it - not a big deal since it's just system generated log data) and re-create the table. This option is usually my last resort if the table is too badly hosed and I don't require the data that's inside of it.
Corrupted Watchdog Table
Thanks for the tip.
I had a login problem 'website experienced error, please try again later'.
Your advice to clear the watchdog table worked and I am able to log in again. The alternative may have been a restore of the entire MySQL database, and the loss of several hours work.
Contact your host
Database repairs can be very tricky and trying things that you are not comfortable with with mysql can be highly dangerous. I would contact your webhost and see if they can assist with a repair as they should have experience with that.
The best way to learn
The best way to learn something is to break and then have to fix it. Back up your database and try it. If you completely destroy it, you can always at least restore it to the point before you broke.
I like it... Though I have
I like it... Though I have seen a db backup fail if there is a crashed table so caution is key.
Contacted Host Tech Support
Thanks. I am in unknown territory. I contacted the tech support of the hosting company to see if they can help.
I can't backup using Backup & Migrate. I get a similar error message. Is there another way to back it up?
Fixed
The hosting company tech support fixed the problem. I have asked what he did and am awaiting a reply. Thanks everyone for your input. You all were right on. Gotta love the Drupal Community! See at the meeting tomorrow.
Follow-up
The hosting company's tech sent me this message: "You can fix your database only using special tools, or you can order "SSH service" and fix your database using command: mysqlcheck -r db_name
Thank you."
The hosting company was selected by the client before hiring me. It's http://www.justhost.com
They did fix it and quickly.
Oh mysqlcheck -r how I love
Oh mysqlcheck -r how I love you... I don't know how many databases I saved using that command when I worked for a hosting company in town.
I use justhost, is this
I use justhost, is this "mysqlcheck -r db_name" what you were mentioning before through phpmyadmin Andrew? I think justhost gives everyone phpmyadmin access. I'm not sure about ssh though. I can't seem to find documentation for that command.
phpmyadmin
The phpMyAdmin interface runs a REPAIR TABLE
watchdogcommand which should be able to repair the index if your table (usually what is broken). Here's a link to more information than anybody would ever want to know (unless they are a db admin): http://www.felipecruz.com/repair-mysql-database.php (Hop down to the "Repairing tables" section.)SSH Service
I did some checking. JustHost says : You can purchase SSH for your account at any point through your cPanel account. Simply click on SSH in the Optional Account Addons and then click 'Add Extra'. SSH costs $19.95 per year.
From another site, I found this:
"SSH stands for Secure Shell access, which is a command prompt access (shell access) over an encrypted communications channel. There are several ways to establish a command prompt session on to your website hosting account. CPanel provides you with an browser based SSL Shell program that allows you to establish a command prompt session.
Note: If you are not familiar with Linux based shell commands you may not want to attempt anything in the shell, as it can create potential problem to the server or your hosting account if things are not done correctly. "
It's probably a piece a cake for some of you, but for me, I am glad that Tech Support was able to fix things for me.
Paying for SSH
I am personally against paying for SSH on any service. To set it up on an account on a cPanel server all the host needs to do is login to the server and click literally 3 times and ssh is enabled. SSH for $19.95 a year is absurd.
EDIT: Wait... 4 clicks and some wheel on the mouse.
Error message when logging on to one of my sites
Warning: Error while sending QUERY packet. PID=3248 in E:\wamp\www\nianow\includes\database.mysql.inc on line 115
Warning: MySQL server has gone away query: INSERT INTO watchdog (uid, type, message, variables, severity, link, location, referer, hostname, timestamp) VALUES (0, 'php', '%message in %file on line %line.', 'a:4:{s:6:\"%error\";s:12:\"user warning\";s:8:\"%message\";s:1819084:\"Got a packet bigger than 'max_allowed_packet' bytes\nquery: UPDATE cache_menu SET data = 'a:2:{s:4:\"tree\";a:843:{i:1;a:2:{s:4:\"link\";a:37:{s:14:\"load_functions\";s:0:\"\";s:16:\"to_arg_functions\";s:0:\"\";s:15:\"access_callback\";s:1:\"1\";s:16:\"access_arguments\";s:6:\"a:0:{}\";s:13:\"page_callback\";s:16:\"filter_tips_long\";s:14:\"page_arguments\";s:6:\"a:0:{}\";s in E:\wamp\www\nianow\includes\database.mysql.inc on line 135
Please help me with this Error.
Pls.... Pls..... Pls....!
Thanks in Advance....!
laxman