Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

setting mamp ports to 80 and 3306

I have both apache and mySQL running with the default MAMP ports (8888 and 8889 respectively) and everything seems to work, but when I switch the ports to 80 for Apache and 3306 for mySQL, the mySQL server is unable to restart.

I am trying to setup MAMP to run on these ports because apparently this is optimal for developing in dreamweaver... Thus, given that I would like to have the ideal dev environment for dreamweaver, is there a way around using the 3306 port? Or, what could the potential problems be?

Thanks

like image 973
thebiglebowski11 Avatar asked Feb 21 '12 03:02

thebiglebowski11


3 Answers

Just in case anyone is having the same problem, here is how I fixed it:

I opened the Activity Monitor program and selected "All Processes"
Next I search for "mysqld" in the search text field. There is a good chance that you have an instance of mysql running and you have to find it and hit quit process.
Restart MAMP and you should be all set.

like image 59
thebiglebowski11 Avatar answered Sep 20 '22 11:09

thebiglebowski11


i posted my solution here.. but will it annoy the editor gods to re-post? i found this works so clearly and consistently that it's worth evangelizing.

fix courtesy of Abhinav Sood.

  1. Launch MAMP. Open Terminal by typing terminal into Spotlight (Command + Space).

  2. Open MAMP Preferences (Command + , ) and click on Reset MAMP Ports (Port 8888 and Port 8889 for Apache and MySQL respectively). Click on OK.

  3. Switch to the terminal. Type sudo apachectl stop to shutdown the system Apache.

  4. Restart MAMP.

  5. Open MAMP Preferences once again and click on Set to Default Apache and MySQL ports. This will set the Apache and MySQL ports to 80 and 3306 respectively.

  6. Switch to the terminal. Type sudo apachectl restart to restart Apache.

  7. Switch back to MAMP and click on Open Start Page (or go to http://localhost/MAMP/?language=English in your browser)

And you’re done.

like image 20
mazal Avatar answered Sep 19 '22 11:09

mazal


I configured httpd.conf. In that file just replace:

Listen 80

for

Listen localhost:80

restart mamp. It worked for me.

like image 43
Francisco Albert Avatar answered Sep 17 '22 11:09

Francisco Albert