Error: port activate failed: Registry error: No port of e installed.

Ryan Schmidt ryandesign at macports.org
Wed Oct 13 04:39:58 PDT 2010


On Oct 12, 2010, at 18:34, dgentry at localbusinesswebsites.com wrote:

> I installed Xcode successfully.
> 
> When I ran "sudo port install apache2," I got:
> "sudo: /etc/sudoers is mode 0666, should be 0440
> Segmentation fault"

I wonder why your sudoers has the wrong permissions. It certainly needs to be corrected.


> I googled that result and then I ran "chmod 0440 /etc/sudoers."  The result was:
> "chmod: Unable to change file mode on /etc/sudoers: Operation not permitted."

You need root permission to change the permissions of the sudoers file. Ordinarily that would mean run "sudo chmod 0440 /etc/sudoers" but in this cas your sudo command doesn't work because the sudoers file has the wrong permissions. Catch 22.

If using Disk Utility's Repair Permissions command does not repair the permissions of /etc/sudoers you may have to "su root" and do it there. This means you'd need to enable your root account, which is not generally recommended, and you should disable the root account again afterward. Or you could change the permissions while booted to single user mode. These are rather advanced topics.


> I ran "port install apache2" and, quoting just the last several lines, I got:
> "--->  Staging apache2 into destroot
> Error: Target org.macports.destroot returned: shell command failed
> Log for apache2 is at: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_ports_www_apache2/main.log
> Error: Status 1 encountered during processing.
> To report a bug, see <http://guide.macports.org/#project.tickets>"


I expect this too will have failed because you did not have sufficient privileges and needed to have used "sudo port install apache2", except that your sudo command is broken because of the permissions on the /etc/sudoers file.





More information about the macports-users mailing list