Opened 15 years ago

Closed 15 years ago

#21494 closed defect (invalid)

Connect from PHP fails with mysql_connect succeeds with Mysqli or PDO

Reported by: pedronbvasconcelos@… Owned by: ryandesign (Ryan Carsten Schmidt)
Priority: Normal Milestone:
Component: ports Version: 1.8.0
Keywords: Cc:
Port: mysql5

Description

Connecting to mysql5 server from (system default) PHP5.3 fails with mysql_connect() but succeeds with Mysqli or PDO. Error log messages (socket and tcp): mysql_connect(): [2002] No such file or directory (trying to connect via unix:///var/mysql/mysql.sock) in […] mysql_connect(): [2002] Can't assign requested address (trying to connect via tcp://127.0.0.1:0) in [...]

System: OSX 10.6.1 on a Core Duo (32bit) MacBook Pro running MacPorts 1.8.0

Change History (4)

comment:1 Changed 15 years ago by pedronbvasconcelos@…

Cc: pedronbvasconcelos@… added

Cc Me!

comment:2 Changed 15 years ago by jmroot (Joshua Root)

Cc: pedronbvasconcelos@… removed
Keywords: mysql connect php removed
Owner: changed from macports-tickets@… to ryandesign@…
Priority: HighNormal

comment:3 Changed 15 years ago by pedronbvasconcelos@…

Please close this ticket. The problem seem to be related to Apache2 and not the port mysql5. Thank you.

comment:4 Changed 15 years ago by ryandesign (Ryan Carsten Schmidt)

Resolution: invalid
Status: newclosed

MacPorts mysql5's socket is not in /var/mysql/mysql.sock but in /opt/local/var/run/mysql5/mysqld.sock.

Note: See TracTickets for help on using tickets.