HELP! Deleted "wheels" user - how do I fix?

Hello,


I am running OS X Lion 10.7.4...


So I just did a big clean up on my hard drive of old files, and wanted to see how much space I now have left on my HD - I right-clicked on Macintosh HD > Get Info.


Under Sharing & Permissions I noticed a strange User listed named "wheels". Afraid that someone had accessed my computer or was somehow sharing on my network, I went ahead like an idiot and deleted the "wheels" user without first researching what it was all about.


After deleting "wheels", I went to Google to read up on it and realized I've apparently made a big mistake, and that the "wheels" user is somehow significant.


My computer appears to be operating fine so far - though through reading up on it, deleting "wheels" can cause some big problems. I've been trying to find a way to restore the "wheels" account and have had no luck so far.


I tried a suggestion to restart holding CMD+R and Repair Disk Permissions, which I did - upon reboot the computer seems to be functioning fine but the "wheels" account is still gone.


How can I fix my stupid mistake? I realize I shouldn't have deleted it - but now it's done. How can I restore "wheels"?


Any help would be much appreciated!!



Thanks

Posted on Jun 7, 2012 8:10 PM

Reply
20 replies

Jun 8, 2012 6:26 AM in response to dg5to

Maybe I didn't read your question carefully enough. I thought you had changed the permissions of the boot volume by deleting the wheel (not "wheels") group from the Sharing & Permissions list. Apparently that's not what you did.


There is a built-in group named "wheel," but there is no user named "wheel" or "wheels." If you deleted the wheel group, you need to put it back. If you deleted a user that had been added, you don't have to put it back, unless it's needed by some third-party software you installed.

Jun 8, 2012 8:29 AM in response to dg5to

I have an expendable Lion test clone that I use for tinkering, and I tried "removing" wheel from the boot disk permssions by highlighting it in the Get Info window and then clicking the minus sign.


Before:

User uploaded file

.

in Terminal:

$ ls -ldeO /

drwxr-xr-x 34 root wheel - 1224 Jun 2 18:59 /



After:

User uploaded file


in Terminal:

$ ls -ldeO /

drwx---r-x 34 root wheel - 1224 Jun 2 18:59 /


So the wheel group itself was still intact and was still the group owner; all that happened was that its permissions were changed from "read only" to "no access".


I first tried repairing permssions with Disk Utility, and this did not fix it.


So I then tried correcting the permssions with Terminal, using


$ sudo chmod 755 /


However the result was:

sudo: can't open /private/etc/sudoers: Permission denied

sudo: no valid sudoers sources found, quitting


Uh oh!

I thought I was in a Catch-22 situation - can't fix the wheel permissions without sudo; can't run sudo with bad wheel permissions!


I found a couple of solutions:

1) Use BatChmod - drag the icon for the boot disk into the File field, and recheck the R and X boxes for the wheel group. Don't check Apply to enclosed folders and files!) The subsequent password authentication dialog still worked.


2) I had previously enabled a root password, and was able to use it to get a root shell without using sudo, after which I could correct the wheel permissions directly:

$ su

Password:

sh-3.2# chmod 755 /

sh-3.2# exit

exit

$ ls -ldeO /

drwxr-xr-x 34 root wheel - 1224 Jun 2 18:59 /


sudo now worked again as well:

$ sudo ls -ldeO /

Password:

drwxr-xr-x 34 root wheel - 1224 Jun 2 18:59 /


Using

chmod 755 /

in single-user mode would presumably have worked as well.


The BatChmod solution is the easiest to use.

Jun 8, 2012 6:56 AM in response to Linc Davis

I deleted a built-in group I believe.


I hadn't ever added any users, so it must be the group named "wheel". How can I put it back?


My computer is running fine by all appearances ... so I'm not sure what effect it had.


I had right-clicked my Macintosh HD icon, chose Get Info... In the Macintosh HD Info window, at the bottom under Sharing & Permissions I removed "wheel" (I thought it was plural) from the list... now I just have "system" and "everyone"


So how do I go about putting it back then? Or do I even need to?

Jun 8, 2012 7:21 AM in response to dg5to

Open the Terminal and enter the following command:


sudo chown :wheel /


Enter your password when prompted, and then you should restore the wheel group to the filesystem root. If you only removed the wheel entry from the one info window on your hard drive then this is all that needs to be done; however, if you have propagated the permissions to enclosed folders then you will have to take additional steps.

Jun 8, 2012 7:47 AM in response to Topher Kessler

I just tried, these are my results:


daniels-imac:~ daniel$ sudo chown :wheel /

sudo: can't open /private/etc/sudoers: Permission denied

sudo: no valid sudoers sources found, quitting

daniels-imac:~ daniel$


When I originally deleted it - all I did was press the lock icon to unlock, then highlighted wheel and pressed the - button... I didn't do any other actions.


??

Jun 8, 2012 9:48 AM in response to jsd2

AMAZING! Thank you kindly... the BatChmod solution worked for me - after dragging my Macintosh HD icon to the File: field in BatChmod, and check marking R and X boxes, pressing Apply and entering my password... the wheel group is listed again under Sharing Permissions as "Read only" in the Get Info dialog for my Macintosh HD drive. Thanks again! 🙂

Aug 20, 2012 9:13 PM in response to dg5to

Thank you to all who contributed to this chain. My son filled up my hard drive on my iMac with some homemade movies to the point it would not function properly. While looking to make sure that I limited everyone's access to the admin account & doing some other clean up, I deleted the "wheel" user access. I could not get the iMac to boot (it would freeze at a grey screen with a cursor, but nothing else). I did not want to wipe the HD & start over as I wanted to archive some of the files, so the quest to fix this mess was on.


Repairing permissions from a remote start up disk did not work & I could not get any of the fixes sugested for the single user mode to work either. I also initally couldn't use the fix suggested by jsd2 becuase I couldn't get to the BatChmod fix (the machine would never boot up) and I did not have a root password set (so I couldn't get to the sudo function). I tried my OS 10.5 disk as a boot disk, which under its utility functions has a reset passwords/access functions for users (even a root/system refernce) not accessible under 10.7 - but that didn't work either. I even tried to reinstall OS 10.7, but that failed as well becuase I didn't have enough disk space (my iniital problem). Final solution: deleted the windows partition on the HD, reformatted it as a mac partition, installed 10.5, installed BatChmod on that partition & followed jsd2's instructions. All is well (after many hours of frustrations). Short of erasing the disk, about the only thing left I was going to try was to try to boot the iMac in target disk mode & try to fix it from there ...

Jul 26, 2014 9:40 AM in response to Andre Machado

I tried a few of these fixes (including reinstalling Mavericks), and they didn't work for me. This is what worked.


I created a new guest user. Set preferences to choose this user on start-up. Restarted my Mac. Renamed my old user in Prefs, and renamed my old user folder to match (using admin name and password for both). Changed my start-up user preferences back to my regular (renamed) account. Restarted. Wheel was back.


I lost my desktop set-up, and had to reimport my mail and mail settings, but it was painless for the most part.

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

HELP! Deleted "wheels" user - how do I fix?

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.