vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   MySQL Database Backup Problem (https://vborg.vbsupport.ru/showthread.php?t=76848)

Deaths 02-22-2005 04:33 PM

MySQL Database Backup Problem
 
I'm changing hosts, but to change hosts, I ofcourse need to save my database, then re-upload it.

The problem is, is that when I download the .sql file, and I upload it to my new host using phhMyAdmin, it first adds all the tables and fields, and then says the database is empty...
So, it basicly deletes itself again...

Does anyone know what to do?
I tried copy-pasting the content of the .sql file, but it's way too big :(.

Help would be appreciated.

tnguy3n 02-22-2005 05:04 PM

if you have shell access on new host. Use this following command:
Code:

mysql -u username -p vbforumdb < /home/path/to/db.sql
of course, you must have your database uploaded to the new server.

Deaths 02-22-2005 05:09 PM

Thanks, I'll try it.

The problem might be that I'm importing from a Cpanel host, to a Confixx Pro host. (Name problems).

Marco van Herwaarden 02-23-2005 02:30 AM

Are you sure that your backup contain both structure and DATA?

You could check this quickly by looking into the sql file with an editor, or by checking the filesize.

Deaths 02-23-2005 11:01 AM

Filesize: 13.7 MB.

Stats:
Members: 25
Threads: 183
Posts: 1,302

I think that's the full DB...
I've downloaded the backup using the vB backup system now, I'll check if that one works.

Michael Morris 02-23-2005 11:27 AM

For a database that small you can use mysql dump to move the data from one machine to the new. Just make sure the old machine will allow a root connection from the new.

Get both machines online at the same time and figure out their IP's, then type this command on the old machine

Code:

mysqldump --opt db_name | mysql --host=remote_host -C db_name
You will probably need to use the --user and --password switches on both servers in the command to log in.

Code:

mysqldump --user --password db_name | mysql --host=remote_host --user --password -C db_name
So, for example

Code:

mysqldump --user=root --password=YeahRightImShowingYouMyPassword testdb | mysql --host=0.0.0.0 --user=root --password=AsAbove -C testdbonnewserver

R@ptor 02-24-2005 10:34 AM

When I use the "restore My SQL" in the cpanel mine does the same thing....
My only problem is I'm not familiar with "shell access"....
I D/L my DB to my home PC as well as a copy of my home dir.

Maybe I did everything wrong.... but I too am moving from one provider to another.
Here is what I did:
I dowloaded a back up of my sql and home dir to my home PC via Cpanel-
Then I loaded a fresh install of VB on my new host -
I then tried to retore mysql....but no go- I'm stuck

When I too use the "resore my sql" feature it tells me the file is empty and does nothing......
Can someone point me in the right direction....my time on my current provider is running out...FAST.

I forgot to add my DB is 160Mb


All times are GMT. The time now is 08:20 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.00990 seconds
  • Memory Usage 1,722KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (4)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (7)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.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
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete