thoughton:digitallife banner
about downloads imagery work
-- How To... --

Upgrade to Tiger, PHP and MySQL broken


I quickly noticed after upgrading to OS X 10.4 that PHP includes were not executing and MySQL queries were once again producing the dreaded 'cannot connect' error message which 10.3.9 had introduced:
Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
:mad:
Fixing the broken PHP was easy. I simply installed Mark Liyange's PHP 5.0.4 package. Tiger ships with 4.3.10.

For the MySQL error, for reasons I have not yet looked into the previous solution (repairing the ownership of the /usr/local/mysql/data folder) did not fix the problem. And trying to load mysqld in the Terminal showed that it not have permission to access the /usr/local/mysql/data folder. Since changing its ownership to the 'mysql' user did not help, I tried changing to it my user account instead (in my case the command was sudo chown -R thoughton data/.) Bingo, that did the trick! Everything works again. :)

A word of caution, this is just a quick fix while learning the ins and outs of Tiger, I wouldn't be surprised if doing this has opened up some huge security hole - so do it at your own risk and always keep a backup.
Posted on 27 April 2005, to How To... | Mac OS X | Site News

Related entries

MySQL broken by 10.3.9? - 21 April 2005
Movable Type, here I come - 16 May 2004
Category icons in Movable Type - 11 July 2004
Movable Type 3.1 launched - 1 September 2004
Upgrading to Movable Type 3.11 - 4 October 2004
Smilies in Movable Type - 14 December 2004
Another Movable Type Captcha - 17 November 2004
Bayesian filtering on Movable Type - 14 November 2004
Postfix broken ... again - 22 March 2004

Comments

Hi,

I'm was having the same problem with MySQL.

The following commands seems to have dome the trick.

cd /usr/local/mysql
chown -R mysql data/

The startup item needs to be updated to be Mac OS X Tiger suitable:

This is what running the SystemStarter with flags -v -d to get verbose and debug info give:
SystemStarter[22136]: Checking MySQL 4.0.24-standard
SystemStarter[22136]: No antecedents
SystemStarter[22136]: Soft dependancies: {type = fixed-mutable, count = 0, capacity = 2, values = (
)}
SystemStarter[22136]: Best pick so far, based on failed dependancies (2147483647->0)
SystemStarter[22136]: Running command (22137): /Library/StartupItems/MySQL/MySQL start
SystemStarter[22136]: IPC message = {type = mutable, count = 3, capacity = 17, pairs = (
5 : {contents = "ProcessID"} = {value = +22137, type = kCFNumberSInt64Type}
11 : {contents = "ConsoleMessage"} = {contents = "Starting MySQL database server"}
18 : {contents = "Message"} = {contents = "ConsoleMessage"}
)}
SystemStarter[22136]: Starting MySQL database server
SystemStarter[22136]: Finished MySQL 4.0.24-standard (22137)
SystemStarter[22136]: none left

by: Shaun McDonald at May 11, 2005 1:33 PM

Subscribe to comments

Enter your email address in the box below to receive an email notification whenever a new comment is posted to this entry.

Email address:

Post a comment










Remember personal info?


Click a smiley!
:) ;) 8) :| :(
:P :X :? :mad: :D
:o :cry: :shock: :blush: :roll:



Security code
Please enter this security number in the space below (this prevents automated responses).



Category icon Sponsors