Can't save files in my own directory due to insane permission error
I was working on my mac and saved a file. Continued to work on the file. One hour later, when I tried to save that file, I saw the message "The document could not be saved. You don't have permission". What??? Now I see I cannot save any of my files. I can open them, but I cannot save. Any file. But this is selective. TextEdit can save the files, Mail.app can open emails and save attachments. Xcode can create and save new projects, but I cannot modify them, or I will see the error if I try to save.
This is what I have tried to do:
-
chown
,chmod -R 755
, etc. on the directory containing my projects doesn't help. - Disk Utility > Repair Permissions doesn't help.
- Reinstalling the app, clearing their .plists, etc. doesn't help.
- I can create a new project or document with these apps (Xcode and Photoshop for example, just to name a few) and it saves the file on my documents directory, but if I change the document and try to save, I see the error.
- I have rebooted the computer and also turned it off and on.
- I did a safe mode boot and scanned the disk using /sbin/fsck -fy and no issues were found.
- I have deleted all caches and application support files.
- I did a chmod -R -N ~ on my documents directory, suspecting that some ACLs could be the guilty. No change.
- I did a recursive chown to take ownership of my own files. The ownership was correct before, but I just did it again to clean anything that could be wrong.
- I reinstalled both apps and nothing.
What more I can? Cry?
Thoughts? Thanks
Solution 1:
I had the same problem. I tried what Matt Love has suggested and still had the problems. I then downloaded Cocktail and ran permission repair, rebooted and all worked again.
Solution 2:
If I understand your question correctly, you're attempting to reset the permissions on a user's home directory. This is easily accomplished by resetting ACLs on the desired home directly by using the Reset Password utility in the Recovery Partition:
Restart your computer from the recovery partition (if running Lion) or the gray disk (if not running Lion).
Open Disk Utility and run a permissions repair on your startup volume.
After this is complete, close Disk Utility and open Terminal from the Utilities menu.
Type in
resetpassword
and select your user account (NOT System Administrator/root) from the drop down menu.Click the Reset button at the bottom of the window in the Reset home folder permissions and ACLs section.
Quit the Password Utility and go back to the main recovery screen. On your keyboard, hit ⌘ + Q and restart your computer.
It's very important that you don't hold down the power button to exit the recovery session, or the ACL reset won't occur.
Let us know how it goes.