Examples of displaying access permissions

1. To display the permissions on a single file:

    ls -l file1
    -rw-r--r--  2 unixjohn     3287 Apr  8 12:10 file1

This displays the following information about the file file1 .

    -rw-r--r--   - access permissions
    2  	          - number of links to this file
    unixjohn 	 - owner
    3287          - size in bytes
    Apr  8 12:10 - date and time last modified

2. To display the permissions on the contents of a directory:

   ls -l prototype

This displays the same information as in example 1 above for each file and directory in the directory prototype.

3. To display the permissions on each file and directory in your current directory:

    ls -l
    -rw-------  1 erpl08       4307 Jun 17 10:00 FAQ.xdh
    drwx------  2 erpl08       1024 Jun 17 10:00 SCCS
    -rw-------  1 erpl08      15119 Jun 17 10:00 commands.xdh
    -rw-------  1 erpl08        266 Jun 17 10:00 concepts.xdh

This displays the following information about every file and directory.

    d            - this is a directory
    rwx------   - access permissions
    2            - number of links
    erpl08      - owner
    1024         - size in bytes
    Jun 17 10:00 - date and time last modified

Top document