Install MAMP by downloading it from the MAMP website and using their easy to follow instructions.
Use MAMP’s version of PHP and MySQL
You can use these default configurations but there are limitations.
To use the MAMP PHP and MySQL make an alias for each in your Bash Profile.
/Users/<user directory>/.bash_profile for editing. If you don’t have a
.bash_profile file, create one.
To add an alias to the stack’s PHP
bin directory, add the following to the
# Alias the path to the MAMP PHP interpreter. # Run 'phpmamp --help' to test. alias phpmamp='/Applications/MAMP/bin/php/php5.3.6/bin/php'
.bash_profile file. If Terminal is currently open, restart it so the alias will take effect, then test your results by using the alias. In terminal execute:
Now you can use the new
phpmamp alias in place of
php in your scripts.
Manually Start MAMP’s Apache server.
If Apache is failing to start from the MAMP UI window, start MAMP’s Apache manually on the command line to check error messages:
Manually stop MAMP’s Apache with:
Per the Knowledge Base at MAMP for “Apache will not start – Yosemite Beta”:
Rename the file envvars located in
/Applications/MAMP/Library/bin to _envvars, and or comment-out the following lines from within the file like so:
#DYLD_LIBRARY_PATH="/Applications/MAMP/Library/lib:$DYLD_LIBRARY_PATH" #export DYLD_LIBRARY_PATH
MySQL Fails to Start
InnoDB: Unable to lock ./ibdata1 from error log at