Page 2 of 2 FirstFirst 12
Results 11 to 13 of 13

Thread: How to safely change permissions for folder/all subfolders & files?

  1. #11
    Join Date
    Jun 2007
    Location
    Chicago, IL
    Beans
    174
    Distro
    Xubuntu Development Release

    Re: How to safely change permissions for folder/all subfolders & files?

    Quote Originally Posted by steviefordi View Post
    Ok, if you log on as root (sudo actually) on the source machine, give read access to everyone:

    Code:
    cd /home/olduser
    sudo chmod -R o+r *
    You should now be able to copy files. You will however require execute permissions on directories in order to list the contents..

    Code:
    sudo chmod o+x <directory>
    will sort that out for you.
    Okay, thanks, but just to make sure I have this correct, will I need to do the second sudo chmod o+x on each top level directory I want to move? For example, sudo chmod o+x Pictures, sudo chmod o+x Documents, etc.
    12.04 Beta 2 of Ubuntu Studio is awesome sauce!"

  2. #12
    Join Date
    Aug 2008
    Beans
    132

    Re: How to safely change permissions for folder/all subfolders & files?

    You only need to do the second one if-

    • you need to list the contents (which I don't think you'll need for the copy)

    AND
    • You don't already have execute permissions set for everybody.


    If it turns out you do need to do it, you will have to do it for each top level directory. You can achieve this quickly with find:

    Code:
    find /home/olduser -type d -exec chmod o+x '{}' \;
    Which basically means - find all the directories from /home/olduser down and execute the chmod on each one.

    Cheers
    Steve.

  3. #13
    Join Date
    Jun 2007
    Location
    Chicago, IL
    Beans
    174
    Distro
    Xubuntu Development Release

    Re: How to safely change permissions for folder/all subfolders & files?

    Quote Originally Posted by steviefordi View Post
    You only need to do the second one if-

    • you need to list the contents (which I don't think you'll need for the copy)

    AND
    • You don't already have execute permissions set for everybody.


    If it turns out you do need to do it, you will have to do it for each top level directory. You can achieve this quickly with find:

    Code:
    find /home/olduser -type d -exec chmod o+x '{}' \;
    Which basically means - find all the directories from /home/olduser down and execute the chmod on each one.

    Cheers
    Steve.
    Great! Thanks a lot!
    12.04 Beta 2 of Ubuntu Studio is awesome sauce!"

Page 2 of 2 FirstFirst 12

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •