Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

marcosdipaolo

macrumors newbie
Original poster
Apr 2, 2013
3
0
It turns out that today i started trying MAMP PRO for Postfix SMTP.
But i had and have a nasty problem.
There's no way MAMP PRO 4.2.1 is allowed to overwrite the hosts file, and it needs to, so MAMP PRO doesn't work.
I found no clear answer in the internet and i tried already couple of solutions with no success, like recreating the file, erasing or commenting the 127.0.0.1 localhost line, among others.
Any ideas around?
2BF.png
 
Last edited:
The /etc directory (actually a link to /private/etc/) and hosts are owned by root and so you need to use sudo commands to edit it, inheriting root permissions for the file. It may also be protected by SIP (aka "rootless") in newer Macs.

Try editing it manually using sudo vi etc/hosts. If the installer isn't configured to use sudo for the command (which would prompt for our administrative account password), it would stand to reason this would cause the issue.
 
It turns out that today i started trying MAMP PRO for Postfix SMTP.
But i had and have a nasty problem.
There's no way MAMP PRO 4.2.1 is allowed to overwrite the hosts file, and it needs to, so MAMP PRO doesn't work.
I found no clear answer in the internet and i tried already couple of solutions with no success, like recreating the file, erasing or commenting the 127.0.0.1 localhost line, among others.
Any ideas around?
2BF.png

I am running MAMP Pro 3.5.2 (have not upgraded to latest yet) and it has never had a problem allowing it to use the hosts file on my Mac. I can launch the app, but then when I click the "Start" button to start servers it prompts to "Authorize to allow MAMP PRO to perform tasks that need admin rights. Type your password to allow this". This prompt is obviously what allows the application to modify etc/hosts. My hosts has the following ownership and permissions:

-rw-r--r-- 1 root wheel 255B Jan 3 23:17 hosts

Sounds like they may have a problem with the 4.x versions of MAMP Pro? I'll be following this discussion and am now glad that I've been lazy and not upgraded yet.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.