LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 03-21-2006, 09:57 AM   #1
gentoo_user
LQ Newbie
 
Registered: Feb 2006
Posts: 11

Rep: Reputation: 0
two problems in mysql


hii all
yesterday , i copied the configuration files of mysql in pc to another pc ,
i copyied /etc/mysql/*
and /var/lib/mysql/*
because i needed to theses configuration in the other pc.
when the copy finish , i try to enter the mysql , then messege display :
"ERROR 2002 (HY000) : CanT connect to local MySql server through socket '/var/run/mysqld/mysql.sock' (111)"
so , what is the solution ,
another thing , when i want remove mysql , i type :
emerge -c mysql (or with version )
the message dislay : " >>clean : No packages selected for removal "
how i can remove this .
thanxs for thelp .
 
Old 03-21-2006, 10:57 AM   #2
zeitounator
Member
 
Registered: Aug 2003
Location: Montpellier, France, Europe, World, Solar System
Distribution: Debian Sarge, Fedora core 5 (i386 and x86_64)
Posts: 262

Rep: Reputation: 30
Quote:
Originally Posted by gentoo_user
hii all
yesterday , i copied the configuration files of mysql in pc to another pc ,
i copyied /etc/mysql/*
and /var/lib/mysql/*
because i needed to theses configuration in the other pc.
when the copy finish , i try to enter the mysql , then messege display :
"ERROR 2002 (HY000) : CanT connect to local MySql server through socket '/var/run/mysqld/mysql.sock' (111)"
so , what is the solution ,
This is most probably because mysql server is not started.

To copy over a mysql installation in the way you're trying, this is the good sequence (pc1 is the one where mysql is installed, pc2 the one where you want to copy):
1- install on pc2 the same version of mysql (unsless you're looking for trouble...) that is on pc1 (upgrade mysql on pc1 if you need to and make sure everything runs smoothly)
2- stop the mysql servers on pc1 and on pc2
3- copy the files over as you just did
4- start mysql server on pc2 and test


There are other ways to copy databases from one server to an other. Using mysqldump might be easier and will work (to some extent) with different configuration options and different version of mysql.

Good luck.
 
  


Reply


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
ERROR 2002: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql. NoviceW Linux - Networking 17 09-17-2014 02:13 PM
ERROR 2002: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql. suziecorbett Linux - Software 8 10-09-2008 01:52 AM
Problems with MySQL on SuSE: Can't Connect (/var/lib/mysql/mysql.sock) neocookie Linux - Software 8 02-07-2008 11:48 PM
mysql error Can't connect to local MySQL server through socket '/var/lib/mysql/mysql. Dannux Linux - Software 3 03-24-2006 08:44 AM
DBD::MySQL + MySQL install problems. Elleroth Linux - Software 4 03-24-2006 06:53 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 12:52 PM.

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