Results 1 to 4 of 4

Thread: Change permission on a file

  1. #1
    Join Date
    Jul 2008
    Beans
    2,732

    Change permission on a file

    Hi good folks,

    I used chmod to change permission of a file to work on. Now I want to change it back but I do seem to be having problems.

    rwxr-xr-x was the file

    I used chmod 751 to change it back but get rwxr-r-x

    Thanks

  2. #2
    Join Date
    Jan 2010
    Location
    Sydney, Australia
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Change permission on a file

    do you want to change it back to rwxr-xr-x ?
    i think you should use 755 instead of 751.

    Code:
    fego@production:~$ touch test.dat
    fego@production:~$ ll test.dat
    -rw-r--r-- 1 fego fego 0 Jan 19 23:58 test.dat
    fego@production:~$ chmod 755 test.dat
    fego@production:~$ ll test.dat 
    -rwxr-xr-x 1 fego fego 0 Jan 19 23:58 test.dat*
    “Progress is made by lazy men looking for easier ways to do things”
    — Robert A. Heinlein

  3. #3
    Join Date
    Mar 2010
    Location
    Squidbilly-Land
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Change permission on a file

    Something doesn't look correct.
    Please copy/paste the output of ls -l {file} before and after changing the permissions. Also include the exact, copy/pasted, commands used.

  4. #4
    Join Date
    Jul 2008
    Beans
    2,732

    Re: Change permission on a file

    Thanks folks it was 755 instead of 751.
    I will mark this as solved.

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
  •