Go Back   vb.org Archive > Community Discussions > Forum and Server Management
  #1  
Old 08-11-2009, 02:21 PM
greenspan greenspan is offline
 
Join Date: Feb 2009
Posts: 27
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Can't create table

Hi. I hope my post is in the right forum. Anyway, my site went down and got my backups from my host. I restored the files and DB. My site is running fine, however, I'm now getting frequent "vBulletin Database Error!" in my admin Email. Here's the message:

============================
Database error in vBulletin 3.8.3:

Invalid SQL:

CREATE TABLE IF NOT EXISTS taggregate_temp_1250002560 (
threadid INT UNSIGNED NOT NULL DEFAULT '0',
views INT UNSIGNED NOT NULL DEFAULT '0',
KEY threadid (threadid)
) ENGINE = MEMORY;

MySQL Error : Can't create table 'taggregate_temp_1250002560' (errno: 13)
Error Number : 1005
Request Date : Tuesday, August 11th 2009 @ 10:56:07 PM
Error Date : Tuesday, August 11th 2009 @ 10:56:07 PM
Script : http://www.mysite.com/forums/cron.php?rand=1250002564
Referrer : http://www.mysite.com/forums/showthread.php?t=2832
IP Address : 202.21.227.84
Username : Unregistered
Classname : vB_Database_MySQLi
MySQL Version :
============================
I'm guessing that it's a permission issue. The backup that I got was in the form of myd, myi and frm files. I pasted them into var/lib/mysql/<database> and has the permission of 755. I tried making it 660 but got more database errors. Can someone point me to the right direction? Thanks in advance.
Reply With Quote
  #2  
Old 08-11-2009, 02:33 PM
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Posts: 25,415
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

OS error code 13: Permission denied

MySQL can not create temporary tables. Please consult your host for a solution.

PS Transfering the databae by moving files is not the recommended method and can cause many issues like the one you are running into now. Was MySQL stopped (source & target) when the files where moved?
Reply With Quote
  #3  
Old 08-11-2009, 02:54 PM
greenspan greenspan is offline
 
Join Date: Feb 2009
Posts: 27
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks Marco for the quick reply.

I just dropped my host a ticket regarding this problem. I'm sorry I cannot understand your question about MySQL getting stopped. But what I did was I created a new database then a folder got shown in var/lib/mysql. I then pasted the database files there.
Reply With Quote
  #4  
Old 08-12-2009, 08:01 AM
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Posts: 25,415
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You can not just copy the files of a database while MySQL is running. MySQL should be stopped first. Also the files need to be tranfered without any conversions to a similar Operating System as the source server is using.

The only reliable method of backing up and restoring a database is with shell access via telnet or ssh. This is because backing up with a PHP script like that in the Admin CP or phpMyAdmin can result in PHP timeouts errors and an incomplete backup file. Please see the instructions here:

Backup:
http://www.vbulletin.com/docs/html/m...nce_ssh_backup

Restore:
http://www.vbulletin.com/docs/html/m...ce_ssh_restore

P.S. If you don't have shell access, some people have also reported success with these scripts:

MySQLDumper:
http://www.mysqldumper.de/en/index.php

MySQLHotxcopy:
http://www.vbulletin.com/forum/showt...t=mysqlhotcopy

Bigdump:
http://www.ozerov.de/bigdump.php
Reply With Quote
  #5  
Old 08-13-2009, 02:08 PM
greenspan greenspan is offline
 
Join Date: Feb 2009
Posts: 27
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks Marco for the tips. Yes, I have ssh and I'll make use of that next time. However, I'm still having a problem with the creation of tempo tables. My host said that they've assigned all privileges for the database user in my database but I'm still encountering the DB error. Can you tell me which specific area should I check? Maybe my host is missing something. Thanks.
Reply With Quote
  #6  
Old 08-13-2009, 02:20 PM
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
Posts: 25,415
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

You will need to check where MySQL creates it's temporary files, this is a setting in the MySQL configuration i think. Then check if MySQL has permissions in that directory (and if older files exist, permission to overwrite them).

Is the error message still exactly the same?
Reply With Quote
  #7  
Old 08-14-2009, 03:46 PM
greenspan greenspan is offline
 
Join Date: Feb 2009
Posts: 27
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Yes. The error is the same. Like this one:
MySQL Error : Can't create table 'taggregate_temp_1250265360' (errno: 13)

I relayed your response to my host. Hopefully, they can help. Thanks.
Reply With Quote
  #8  
Old 08-18-2009, 03:42 AM
greenspan greenspan is offline
 
Join Date: Feb 2009
Posts: 27
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

My host said that they did the changes, however, I'm still encountering the error. Just a question, are the tempo folders really stored as files in harddisk and not in the memory?
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 02:42 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04526 seconds
  • Memory Usage 2,218KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (8)post_thanks_box
  • (8)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (8)post_thanks_postbit_info
  • (8)postbit
  • (8)postbit_onlinestatus
  • (8)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete