php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #2453 MySQL connection failed:Can`t connect to local
Submitted: 1999-10-06 10:41 UTC Modified: 1999-10-06 11:18 UTC
From: station7 at hotmail dot com Assigned:
Status: Closed Package: MySQL related
PHP Version: 3.0.9 OS: Linux
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: station7 at hotmail dot com
New email:
PHP Version: OS:

 

 [1999-10-06 10:41 UTC] station7 at hotmail dot com
Trying to connect to MySQL with PHP, get error:

MySQL Connection Failed: Can't connect to local 
MySQL server through socket '/var/lib/mysql/mysql.sock'
(111)

MySQL works fine on own.  PHP works.  But can`t
connect to MySQL with PHP.

running MySQL 3.22.22, PHP 3.0.9, Apache 1.3.6

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [1999-10-06 11:18 UTC] rasmus at cvs dot php dot net
Your MySQL client library and your installed MySQL server don't agree on where the MySQL socket is located.
In recent versions of PHP you can specify the location of this Unix Domain socket in the mysql_connect() call.
See http://www.php.net/manual/function.mysql-connect.php3
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 26 04:01:30 2024 UTC