MySQL Forums
Forum List  »  Quality Assurance

MySQL server through socket '/var/lib/mysql/mysql.sock' (11)
Posted by: Austin Kenny
Date: April 26, 2012 02:47PM


If any one can help that would be great!

I saw this post however I cant get a solution.....,218638,218638

I am running a JMeter test 1000 HTTP requests (1000 threaded loop going to the home page -> Category Page -> Product page)
Hitting my website (X-Cart ecommerce website)

The site grinds to a halt and I am getting a warning message returned from X-CART logs and it looks as if there is a socket connection limit is reached from X-Cart to the MySQL database:

Warning: mysql_select_db() [<a href='function.mysql-select-db'>function.mysql-select-db</a>]: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (11) in /var/www/html/include/func/func.db.php on line 47

Currently in config.php in x-cart the details to the database are setup as localhost.

# SQL database details
# This section sets up a connection between X-Cart shopping cart software
# and your MySQL database. If X-Cart is installed using Web installation, the
# variables of this section are configured via the Installation Wizard. If you
# install X-Cart manually, or if, after X-Cart has been installed, your MySQL
# server information changes, use this section to provide database access
# information manually.
$sql_host ='localhost';

However if i change this to or the IP address of the machine the site fails altogether.

If someone could please help or point me in the right direction, i would be very greatful


Options: ReplyQuote

Written By
MySQL server through socket '/var/lib/mysql/mysql.sock' (11)
April 26, 2012 02:47PM

Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.