Last Updated: 29 Oct 2023

   |   

Author: 114.119.141.194

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Last revision Both sides next revision
server-tech:macosx:upgrading-mamp-pro [Feb 25, 2018 07:20 AM]
dordal
server-tech:macosx:upgrading-mamp-pro [Oct 24, 2023 09:21 PM]
110.249.201.168 removed
Line 1: Line 1:
 += Upgrading MAMP Pro =
  
 +Upgrading MAMP Pro can be a little complicated. Here's the procedure I used to upgrade from 3 to 4.1:
 +
 +  * If you've customized your ''httpd.conf'', ''php.ini'', etc. make sure to make a backup copy. Easiest way to do this is to go to ''File'' -> ''Edit Template...'' and copy the contents of each file. Depending on which version you're upgrading from/to, MAMP may or may not preserve your custom edits.
 +  * Make sure MAMP isn't running.
 +  * Download the new MAMP from https://www.mamp.info/en/downloads/
 +  * Run the installer. It should automatically figure out that you need to upgrade, and do that for you.
 +  * Load MAMP Pro and allow it to initialize its components.
 +  * The new version of MAMP Pro may come with new templates for ''httpd.conf'', ''my.cnf'', etc. It will ask you to save your existing ones somewhere else; do that and then use ''diff'' (or [[http://en.wikipedia.org/wiki/Apple_Developer_Tools#FileMerge|FileMerge]]) to migrate any changes. If it doesn't, you may want to check the new versions against the backup copies you made earlier just to make sure everything is there.
 +  * **NOTE: As of MAMP 4.X there is a new option 'Make this version of PHP available from the command line' which negates the need to do these manual linking steps.** That said, if you want to manually link your PHP binaries from my ''/usr/local/bin'' to the MAMP equivalents (rm's are only needed if you've done this linking before):<code>
 +sudo rm /usr/local/bin/php
 +sudo rm /usr/local/bin/phpize
 +sudo rm /usr/local/bin/php-config
 +sudo rm /usr/local/bin/pear
 +sudo ln -s /Applications/MAMP/bin/php/php7.1.0/bin/php /usr/local/bin/php
 +sudo ln -s /Applications/MAMP/bin/php/php7.1.0/bin/phpize /usr/local/bin/phpize
 +sudo ln -s /Applications/MAMP/bin/php/php7.1.0/bin/bin/php-config /usr/local/bin/php-config
 +sudo ln -s /Applications/MAMP/bin/php/php7.1.0/bin/bin/pear /usr/local/bin/pear
 +</code>
 +  * MAMP very annoying uses a different php.ini if you call it on the command line vs. calling it via apache. So I typically link the command line over to reference the apache one: <code>sudo rm /Applications/MAMP/bin/php/php7.1.0/conf/php.ini
 +sudo ln -s "/Library/Application Support/appsolute/MAMP PRO/conf/php.ini" "/Applications/MAMP/bin/php/php7.1.0/conf/php.ini"</code>
 +  * You'll probably want to link ''mysql'' as well:<code>sudo rm /usr/local/bin/mysql
 +sudo ln -s /Applications/MAMP/Library/bin/mysql /usr/local/bin/mysql 
 +</code>
 +  * You may need to [[installing-phpunit-on-mamp|reinstall phpunit]] or other software you've customized MAMP with.
 +  * That should be it. Test your sites out and see if they work.