Problem to mysql
Hi,
How to resolve this? [huamin@CentOS65x64 ~]$ mysql ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) |
start mysqld
|
Sorry, I get this
[huamin@CentOS65x64 ~]$ start mysqld start: Unknown job: mysqld [huamin@CentOS65x64 ~]$ |
Code:
# as root user Code:
rpm -qa|grep -i mysql |
Any advice to this problem?
[huamin@CentOS65x64 ~]$ su - Password: [root@CentOS65x64 ~]# mysql -h localhost -P 3306 ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2) [root@CentOS65x64 ~]# As I now still encounter the above problem. |
Any help?
|
If you're using the -h host -P port method then specify the non-localhost IP address of the server. For example: -h 192.168.1.2 -P 3306
When using localhost mysql will generally try to connect via socket rather than tcp/ip |
Quote:
Bumping your own thread is fairly rude..doing it without providing ANY other information about your problem is pointless. You are NOT going to get help any faster by saying "Any help?". And you've already asked this in ANOTHER thread about MySQL: http://www.linuxquestions.org/questi...ql-4175542971/ ...where you said it was 'solved', and that you WERE able to get into the mysql console. So, which is it? Try reading the MySQL documentation first...the 'problems' you're having can be solved by following the documentation about how to start the service, and how to access it. If you run 'sudo -s', then type in "mysql", that should be all you need to do for a default installation. |
Many thanks all.
|
All times are GMT -5. The time now is 04:23 PM. |