matthewstorey.co.uk
In this section Access FAT32 Partitions | Commands | Enabling DMA | Links | File Locations | Other Settings | File Permissions | Run Levels | Services | Using Truetype Fonts

File Permissions

In Linux, file permissions are expressed in a 3 digit octal (base 8) number.
These numbers stand for the following permissions:

When listing the file permissions ('ls -l'), you will notice that there are 10 file attribute characters:

    total 11
    drwxr-xr-x        3 ROOT    SYS1    0 Mar 12 19:32 tmp
    drwxrwxrwx        4 ROOT    SYS1    0 Mar 12 19:32 usr
    drwxr-xr-x        2 ROOT    SYS1    0 Mar 12 19:32 bin
    -rwxr--r--        1 ROOT    SYS1  572 Mar 12 19:32 foo
    -rwxr--r--        1 ROOT    SYS1  640 Mar 12 19:33 abc

The first one indicates the type of file, this is either:

The rest describe the 3 digit access mentioned above for difference user groups and can be a combination of:

The first set of 3 digits is the access for the file owner, the second set of 3 digits is the access for the file group and the last set of 3 digits is the access for anyone else.

So for example, file access of 600 (shown as '-rw-------'), means that the file owner has read and write access, but no-one else has any access.

Back to top