I'm trying to change the group of several files in Mac OS X using the group nogroup:

chown my_user:nogroup file.txt

Problem is that it does not change at all, although the nogroup is currently listed in /etc/group and Directory Service (I checked it with dscl . list /groups).

What can be happening?

EDIT: I wanted to do this because XAMMP user and group is nobody:nogroup, and I needed XAMMP's httpd server to be able to write in some directories. I ended up changing the group to _www, but curiosity made ask this question.

Thanks!

link|improve this question

feedback

migrated from serverfault.com Apr 28 '11 at 9:39

This question came from our site for system administrators and desktop support professionals.

1 Answer

up vote 1 down vote accepted

Because the GID of nogroup is (intentionally) -1, which is an illegal GID for chown.

Why do you want to do that?

link|improve this answer
However, you can do it with nobody group, which is -2. That's why I got surprised. I've edited the question to clarify my purpose – elitalon Mar 11 '11 at 9:23
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.