Installing Magento Commerce and MAMP on Leopard 10.5.6
Posted 16 April 2009 by Russ in Ecommerce, Other stuff. Tags: Magento Commerce, MAMP, OS X.
Running Magento Commerce on Mac OSX is straightforward once you’ve got MAMP installed. This article covers a couple of hurdles you might have to clear in the process.
As a front end developer, I love Magento Commerce. The way it handles the presentation layer of an online store is easy to work with once you’ve got to grip with the basics, and you can easily add your own modifications without having to edit a mass of files or find your store breaks when you upgrade.
Installation is pretty straight-forward and not much different to any other typical LAMP application, but I found that my out-of-the box LAMP setup on OS X Leopard 10.5.6 was missing a few of the PHP modules required to install the app. For example I had the most recent version of the GD image library installed but the Magento installer insisted I needed something more.
I’m not a Linux guy and poking around under the hood of my OS isn’t something I’m busting to do but I had a crack at installing the missing modules using Fink. This seemed more straight-forward than installing packages via the command line, but I still didn’t like it, so I turned to MAMP.
MAMP I discovered, is great if you’re looking for a friendly interface to your Apache, PHP and MySql setup. I downloaded and installed MAMP Pro as it allows me to run multiples sites locally on my Mac and once it had installed, I only had a couple of bits to change.
Installing MAMP Pro
As I had already configured LAMP on my Mac, MAMP was set to use the ports 8888 and 8889 for Apache and MySql respectively, instead of the default ports 80 and 3306. Not a major issue but I’d rather just slap local.mysite.com into my browser than worry about local.mysite.com:8888. Perhaps I’m just lazy.

Error with the MySql –skip-federated option
The second problem I had was more fundamental: MySql refused to start up, complaining about an issue with an unknown option in the log:
[ERROR] /Applications/MAMP/Library/libexec/mysqld: unknown option '--skip-federated'
The solution to this I found, was simple. This option is set in the /etc/my.conf file and can be safely commented out. To fix this, you need to look for the following lines and add a # character to comment out the option and restart MAMP.
# Disable Federated by default
# skip-federated
Error connecting through socket
The final issue I found was to do with the MySql socket. MAMP has it’s own MySql install that was clashing with the one installed in my OSX installation, even though that one was not running:
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock'
This was also easy to fix using the Terminal app. Simply login into your Terminal and run the following command:
sudo ln -s /Applications/MAMP/tmp/mysql/mysql.sock /tmp/mysql.sock
If you experience these issues installing MAMP, following these steps shouldsee you up and running with everything you need to install Magento Commerce.

