By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,948 Members | 852 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,948 IT Pros & Developers. It's quick & easy.

Revisiting mysqldump ==> restoration problem

P: n/a

I did a server upgrade and at the same time did a mysql update from
4.0.12 to Ver 12.22 Distrib 4.0.16. Essentially, moving from one machine
to another. The dump consists of a cluster of databases, not just one
and a few Tables.

Now I'd like to restore the Database(s) ===>

mach1# mysql --version
mysql Ver 12.22 Distrib 4.0.16, for portbld-freebsd4.9 (i386)

I attempted to restore the DB with

mysql> LOAD DATA INFILE /usr/home/adam/Temp_storage/mysqldump/dump_all;

and got the following Error message ==>

ERROR 1064: You have an error in your SQL syntax. Check the manual
that corresponds to your MySQL server version for the right syntax to
use near '/usr/home/adam/Temp_storage/mysqldump/dump_all' at line 1

Inspection of the dumped file ==>

head /usr/home/adam/Temp_storage/mysqldump/dump_all
-- MySQL dump 9.07
-- Host: localhost Database:
-- Server version 4.0.12-log

-- Current Database: bpndb
I received several pieces of advice which I followed but with little
success. Currently the dump_file (copy of) has been modified w/ sed to
remove all comment lines, for instance all of those above, all "--",
all "---------------------------------------------------------", all "--
Current Database:xxxxxxxx", etc.

So the file is a bare bones file of CREATE, INSERT command line type
instructions. How can I pass these back into the new mysql? And as we
are at it, how does one restore the original dumpfile into the new
mysql? I am sure someone has been faced with the problem of moving a DB
cluster from one machine to another.

Could someone advise

-- Adam --
Jul 20 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.