Bug #90843 MySQL server connect through socket issue
Submitted: 12 May 2018 7:23 Modified: 12 May 2018 8:39
Reporter: Saravanakumar LS Email Updates:
Status: Not a Bug Impact on me:
None 
Category:MySQL Server Severity:S3 (Non-critical)
Version:5.7 OS:Linux
Assigned to: CPU Architecture:Any
Tags: MySQL server connect through socket issue

[12 May 2018 7:23] Saravanakumar LS
Description:
We are unable to connect MySQL server from our application.  Our application and MySQL are running in Linux environment.  As analyzed, it shows below Error while try to connect mysql,

> mysql -u root -p

ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)

We fixed with below steps.

1.	Stop MySQL server.
2.	Take backup and Rename my.cnf file.
3.	Check mysqld folder is available in /var/run folder. 
4.	If it is not available then create directory and change ownership as mysql.
5.	Else check ownership of that folder. If it is other than mysql then change to mysql.
6.	Take backup of ib* files from /var/lib/mysql folder.
7.	Delete ib* files from /var/lib/mysql folder.
8.	Start mysql in safe mode.
9.	Access mysql and grant all privileges to root user and flush privileges.
10.	Stop MySQL server.
11.	Remove newly created ib* files in /var/lib/mysql folder.
12.	Copy and paste ib* backup files to /var/lib/mysql folder.
13.	Start mysql.

But we are unable to identify the root cause. MySQL was working fine in 2 weeks back. Issue has been identified by 2 days back.

Can you please let us know, what will be the root cause for this issue?

How to repeat:
Unable to find the root cause. Request to check and let us know the root cause of this issue.
[12 May 2018 8:39] MySQL Verification Team
We're sorry, but the bug system is not the appropriate forum for asking help on using MySQL products. Your problem is not the result of a bug.

Support on using our products is available both free in our forums at http://forums.mysql.com/ and for a reasonable fee direct from our skilled support engineers at http://www.mysql.com/support/

Thank you for your interest in MySQL.