Skip to content

1.6 File Permissions

Tomato6966 edited this page Jun 29, 2021 · 1 revision

Change Permissions for a File / Directory

chmod +rwx FILENAME
chmod -rwx FILENAME

Linux chmod example

        PERMISSION      EXAMPLE
     U   G   W
    rwx rwx rwx     chmod 777 filename
    rwx rwx r-x     chmod 775 filename
    rwx r-x r-x     chmod 755 filename
    rw- rw- r--     chmod 664 filename
    rw- r-- r--     chmod 644 filename

NOTE: Use 777 sparingly!

        LEGEND
        U = User
        G = Group
        W = World
    r = Read
    w = write
    x = execute
    - = no access
Clone this wiki locally