Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

My macbook recently died and I am currently trying to figure out how to copy my data.

What I did was, I took out the hard drive, put it in an enclosure and plugged it in to my other laptop that runs linux.

The problem is, I cannot copy files from the hard drive due to file permissions. I tried to access the hard drive as root. But I still cannot copy files.

How do I remove file permissions from the harddrive?

share|improve this question
    
Do you get a permission denied error or something else (i.e. does it look the same when you try to copy as regular user and root, what is/are the message(s)?)? Specific text may be helpful. –  nerdwaller Jul 1 '13 at 20:52
    
@nerdwaller The error message says "Error while copying "fileName". When I click on more details it says " Error opening file: Permission denied" –  user2540416 Jul 1 '13 at 20:54
2  
What ls -l show (what I am getting at is permissions, owner, & group)? Does it allow you to chown? –  nerdwaller Jul 1 '13 at 21:42
    
how is it being mounted? –  Logman Jul 1 '13 at 22:42
    
Seems to me you want to add permissions, not remove them. –  Daniel R Hicks Jul 1 '13 at 22:53

1 Answer 1

Assuming that your file system is HFS or similar to other Unix filesystem, what you want to do is reset the permissions so that they are accessible. You can't remove permissions, but you can make them more accessible, with security implications of course.

Try the following to add read and execute permissions to all the subdirectories:

sudo find /path/to/external/drive -type d -print0 | sudo xargs -0 chmod ugo+rx

Now all the directories should be readable by all users. The original owner and write bit will be preserved.

Do a similar thing to make all the files readable by everyone and perserving the write/execute bits as well as original owner/group:

sudo find /path/to/external/drive -type f -print0 | sudo xargs -0 chmod ugo+r
share|improve this answer
    
gparted says that the path to the HFS+ parttion is /dev/sdc2. But when I typed in the first command you gave me in the terminal, it says that /dev/sdc2 is not a directory. –  user2540416 Jul 1 '13 at 23:45
    
@user2540416: You have to use the mount point. Type mount (if not found, try /etc/mount) and look for the line than mentions /dev/sdc2. (But surely you already know what the mount point is, if you were able to see the files.) –  Scott Jul 2 '13 at 0:20

Your Answer

 
discard

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.