Skip to content

Detail usage of ls -l command



In Linux, the ‘ls’ command is used to list the contents of a directory. The ‘-l’ option is used with the ‘ls’ command to display the contents of a directory in a detailed format. This blog post will discuss the details of the ‘ls -l’ command in Linux.


ls -l


-rwxr-xr-x 1 root root 12028816 May 13 22:58 b
  • First field (1 character): File type
  • Second field (9 characters): Permissions
  • Third field (1 character): Number of hard links
  • Fourth field: Owner
  • Fifth field: Group
  • Sixth field: File size (in bytes)
  • Seventh field: Last modified time
- : Regular file
d: Directory file
b: Block device file
c: Character device file
l: Symbolic link
p: Pipe file
s: Socket file

  • Welcome to visit the knowledge base of SRE and DevOps!
  • License under CC BY-NC 4.0
  • Made with Material for MkDocs and improve writing by generative AI tools
  • Copyright issue feedback, replace # with @