Opened 12 years ago

Closed 4 years ago

Last modified 4 years ago

#19590 closed defect (worksforme)

selfupdate fails with "unknown group 501"

Reported by: ali_kaylan@… Owned by: macports-tickets@…
Priority: Normal Milestone:
Component: base Version: 1.7.0
Keywords: Cc: abhishek.dwaraki@…, zahanm@…

Description (last modified by blb@…)

after installing the software with the finder and executing:

sudo port -d selfupdate

installation fails with:

[ ! -f /opt/local/etc/macports/mp_version ] || rm -vf /opt/local/etc/macports/mp_version
===> making install in doc
/usr/bin/install -c -d -o root -g 501 -m 755 /opt/local
/usr/bin/install -c -d -o root -g 501 -m 755 /opt/local/etc/macports
cat prefix.mtree | /usr/sbin/mtree -U -e -p /opt/local > /dev/null
mtree: line 6: unknown group 501
make[1]: *** [install] Error 1
make: *** [install] Error 1

Change History (11)

comment:1 Changed 12 years ago by blb@…

Component: portsbase
Description: modified (diff)

Odd that a root install would be using a user group (501); how did you first install MacPorts, DMG, from source, something else?

comment:2 Changed 12 years ago by blb@…

Cc: abhishek.dwaraki@… added

Cc reporter of dup #19690.

comment:3 Changed 12 years ago by blb@…

Currently, the selfupdate procedure uses the current owner of the install prefix (/opt/local by default) to be the owner of the updated install (see macports.tcl).

Perhaps there should be a check to make sure these ids exist first, since apparently some systems don't have a group 501?

comment:4 Changed 12 years ago by zahanm@…

Cc: zahanm@… added

Cc Me!

comment:5 Changed 12 years ago by zahanm@…

I'm new to Macports. I installed it from the DMG I think. How do I correct this. Do I need to change some permissions or something?

comment:6 Changed 12 years ago by zahanm@…

Also, I just checked the 'port' executable in /opt/local/bin/, the permissions on that file (when seen in the finder's 'get info' window, shows that 'everyone' has read only access. The strange part is that the 'system' user (I presume that is the root user) also has read only permissions.

The other executables in the folder (installed using Macports) have permissions for the 'everyone' user set to read only, but 'system' is always read and write. Weird.

comment:7 Changed 12 years ago by zahanm@…

Okay, I've been doing some digging around regarding UNIX file permissions. There are sporadic folders in /opt/ that are within the group '501'.

Solved the problem. There is no '501' group on my machine (running Leopard 10.5.8/10.5.7 at time of installation). I changed the group (using sudo chgrp) of opt/local to 'admin'. Selfupdate worked, and all the installed files are now in the 'admin' group.

Apparently talking to no one in particular is therapeutic and problem-solving. =)

comment:8 Changed 11 years ago by nate@…

I had the same problem and chgrp -R admin /opt/local worked for me. Thanks!

comment:9 Changed 11 years ago by jmroot (Joshua Root)

Keywords: "unknown group" 501 removed
Milestone: MacPorts Future
Summary: selfupdate failsselfupdate fails with "unknown group 501"

comment:10 Changed 4 years ago by raimue (Rainer Müller)

Resolution: worksforme
Status: newclosed

comment:11 Changed 4 years ago by jmroot (Joshua Root)

Milestone: MacPorts Future
Note: See TracTickets for help on using tickets.