Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 03-27-2012, 08:06 AM   #1
Registered: Jan 2011
Location: Dhaka
Posts: 80

Rep: Reputation: 1
Mysql DB dump restore failed


I ran into a big trouble. I made mysql dump using version 5.0.77 without setting the compatibility mode (I wasn't aware of this problem). Actual mysql server is version 4.0.18. Today our database crashed. Lots of tables lost. While trying to restore the dump, it's returning error "ERROR 1193 at line 18: Unknown system variable 'character_set_client'". Is there any way we can restore the db?

Thanks a lot for you help.
Old 03-27-2012, 08:40 AM   #2
Registered: Jan 2011
Location: Dhaka
Posts: 80

Original Poster
Rep: Reputation: 1
I did this just now:

I restored the dump to a mysql server 5.0.77 and took dump from it with "--compatible=mysql40" option. But still mysql dump kept the "character_set_client" info. So unable to restore it. Damn! it's running production server and clients are all over me
Old 03-27-2012, 09:04 AM   #3
Senior Member
Registered: Oct 2003
Location: Bonaire
Distribution: Debian Wheezy/Jessie/Stretch/Sid, Linux Mint DE
Posts: 4,604

Rep: Reputation: 686Reputation: 686Reputation: 686Reputation: 686Reputation: 686Reputation: 686
Just a wild guess: MySQL < 4.1 doesn't use character_set_client. Can't you simply delete the lines with this set statement? Should be a simple sed statement.

Old 03-27-2012, 06:36 PM   #4
LQ Guru
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.9, Centos 7.3
Posts: 17,395

Rep: Reputation: 2395Reputation: 2395Reputation: 2395Reputation: 2395Reputation: 2395Reputation: 2395Reputation: 2395Reputation: 2395Reputation: 2395Reputation: 2395Reputation: 2395
What he said ^ ; mysqldump is an ASCII plain text file



Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Restore MySQL Dump File But I want it to restore with different names? helptonewbie Linux - Newbie 5 07-08-2009 05:09 AM
dump and restore ChrisAbela Slackware 0 05-08-2008 08:15 AM
Trying to restore mysql dump, error 1062: Duplicate entry mackdav Linux - Software 1 04-25-2006 03:02 AM
dump/restore moger Linux - Software 4 12-31-2002 04:34 AM
dump and restore nat Linux - General 1 04-26-2002 04:08 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 02:32 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration