Results 1 to 4 of 4

Thread: Set permissions for a "root" controlled folder.

  1. #1
    Join Date
    Jun 2012
    Beans
    Hidden!

    Unhappy Set permissions for a "root" controlled folder.

    Hey guys!

    As I mentioned, in one of my threads, I'm an Android dev, know my way around Windows, Android but still quite new to the Ubuntu interface...

    I downloaded the source code of Android, it's in my home folder, and it's controlled by root, for some reason. I know I can change this in Terminal, but can someone tell me the rest? All I'm 100% sure about is
    Code:
    sudp -i
    chmod
    And that's all I'm sure about. Yes, I do know, that I can use
    Code:
    sudo chmod
    LG Simon

    EDIT: The folder path is: /home/simon/WORKING_DIRECTORY
    Last edited by Beatsleigher; June 9th, 2012 at 06:12 PM.

  2. #2
    Join Date
    Jun 2011
    Location
    United Kingdom
    Beans
    Hidden!
    Distro
    Lubuntu Development Release

    Re: Set permissions for a "root" controlled folder.

    Code:
    sudo chown -R $USER:$USER ~/WORKING_DIRECTORY
    should work.

  3. #3
    Join Date
    May 2012
    Location
    UK
    Beans
    613

    Re: Set permissions for a "root" controlled folder.

    Code:
    sudo chmod 777 -R /home/simon/WORKING_DIRECTORY
    will give all permissions read and write access, you should later be able to edit this within nautilus, by right-clicking directory or file and go to properties etc or continue using the command line method:

    first number is Owner
    second number is Group
    third number is anyone else

    0 – no permission, this person cannot read, write or execute
    1 – execute only
    2 – write only
    3 – execute and write only (1 + 2)
    4 – read only
    5 – execute and read only (1 + 4)
    6 – write and read only (2 + 4)
    7 – execute, write and read (1 + 2 + 3)
    -R - means to all folders and files within
    Last edited by black veils; June 12th, 2012 at 10:54 AM.

  4. #4
    Join Date
    Dec 2009
    Beans
    5,506

    Re: Set permissions for a "root" controlled folder.

    The only problem with a "chmod 777 -R" is that the octal mode isn't smart enough to differentiate between a folder and a file so you end up with all files being executable.

    If you do it this way:
    Code:
     sudo chmod -R a+rwX  /home/simon/WORKING_DIRECTORY
    Then all Folders will be 777 and all files will be 666 unless the file was executable to begin with - that's what the big "X" does.

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
  •