Jump to content


Corporate Sponsors


Latest News: (loading..)

Xpajun

Member Since 13 Dec 2007
Offline Last Active Apr 25 2012, 07:02
****-

Topics I've Started

MySQL socket error?

23 August 2011, 13:04

I'm getting the following error (on and off I think but in batches - multiple attempts at a time) in my error log - anyone come across it and has a cure?


 PHP Warning:  mysql_connect() [<a href='function.mysql-connect'>function.mysql-connect</a>]: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (11) in /******/*******/public_html/includes/functions/database.php on line 19


Line 19 is 2nd $$link:
    if (USE_PCONNECT == 'true') {
      $$link = mysql_pconnect($server, $username, $password);
    } else {
      $$link = mysql_connect($server, $username, $password);
    }