Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How do I create a group with a specific GID and add a user to it on Mac OS X 10.5?

The problem is that macfuse is not smart enough to handle groups when it mounts, so I can't open files which on the remote site that do not belong to my user (though I should be able to open them due to group permissions).

Since I see those files as belonging to group "33" I need to create a group with gid=33 and hope that it fixes the problem.

share|improve this question
up vote 11 down vote accepted

If you're looking for a more easy to use GUI, I suggest download the Server Admin Tools for your appropriate version (in this case Mac OS X 10.5.7 Server Admin Tools). The program Workgroup Manager can provide a UI to manage users and groups.

The alternative will use dscl on the Terminal and does not require downloading any additional software.

To change Mac OS X's users and groups from the command line you want to use a command called dscl.

To create a new group (change groupName to your group name - avoid spaces, shortusername should be your short user name):

dscl . -create /Groups/groupName
dscl . -create /Groups/groupName name groupName
dscl . -create /Groups/groupName passwd "*"
dscl . -create /Groups/groupName gid 33
dscl . -create /Groups/groupName GroupMembership shortusername

If you want to use Workgroup Manager; you need to open the application and login onto localhost using your username and password. (This all assumes you're a local administrator). Once in the program:

  1. Click on the Groups tab on the left side. The icon with multiple people.
  2. Click New Group from the toolbar
  3. Enter a name, and set the Group ID: to 33
  4. Click on the Members tab, and then press the '+' button and drag and drop your user name into the list.
  5. Press Save, then quit the program.
share|improve this answer
omg that's a perfect answer, it worked, thanks! – o0'. Nov 23 '09 at 19:21

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .