Sign up ×
Ask Different is a question and answer site for power users of Apple hardware and software. It's 100% free, no registration required.

On my computer I have two accounts: geoff and admin. I want to do gacutil.... Doing it in account geoff (where I need it to be done) I get the message:

gac directories could not be created, possibly permission issues.

When I login as admin this seems to work fine.

So I go back to the geoff account and try sudo gacutil... and putting the password for geoff but it tells me that geoff is not in the sudoers file.

So it seems that I either have to get geoff in as a sudoer (how?) or else get my admin account to do the gacutil on geoff's behalf (is this possible?).

share|improve this question
Consider also this answer: – n1000 Jan 28 at 8:17

2 Answers 2

up vote 6 down vote accepted

Rather than give geoff sudo privileges, consider adding the account to the admin group so that it inherits the admin group sudoer privileges. This would be the more correct way to do things.

To add geoff to the admin group you'll need to run the following as the admin account:

sudo dseditgroup -o edit -a geoff -t user admin

You may also want to consider putting geoff in the wheel group too:

sudo dseditgroup -o edit -a geoff -t user wheel

The wheel group is a BSD-ism, where OS X has its roots. In traditional BSD systems the wheel group was used to keep a collection of users who were allowed to become superusers using the su command. It's not strictly necessary to be in both admin and wheel but anyone setup as as "Administrator" on the machine through the UI for adding a user is in both so it can't hurt to replicate that setup.

share|improve this answer
This is an interesting suggestion but be aware that this may allow the user to access more then just sudo. For instance, adding a user to the admin group would allow write access to the /Applications/ directory, which could lead to security issues or the accidental modifications. – James McMahon Nov 3 at 18:43

To add a user to sudoers, as admin do:
sudo visudo

Then scroll down to
# User privilege specification
root ALL=(ALL) ALL
%admin ALL=(ALL) ALL

place the cursor at the next (empty) line, and press a (for append). Then type
shortname ALL=(ALL) ALL

where shortname is the short name for the user that you are adding to sudoers (there should be TAB between the short name and ALL). After that press ESC (to exit append mode). Then type :wq and then Enter to quit visudo, saving the changes.

share|improve this answer
After loggin in as admin, I tried visudo and I get Permission denied. – Geoff Dec 30 '12 at 14:47
Sorry, should be sudo visudo (as admin). I edited the answer with the change. – lupincho Dec 30 '12 at 16:20
I added following ur steps root ALL=(ALL) ALL %admin ALL=(ALL) ALL "Syammala Naidu" ALL=(ALL) ALL , where as Syammala Naidu is the user i want to add to sudoers. I rebooted and logged in to Syammala Naidu and gave sudo -i and password. It is telling user not in sudoers file, incident Reported – Phani Naidu Jun 10 at 6:13
@PhaniNaidu: you need to add the short username – lupincho Jun 23 at 17:13

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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