What is the meaning of those numbers in the second column after typing "ls -l"? [duplicate]
Solution 1:
That's the number of hard links to the file or directory. For files, this will usually be 1
, unless you've created additional hard links to it with ln
.
For directories, it's 2 + the number of subdirectories. This is because a directory can be referred to either by its name in the parent directory, .
in itself, or ..
in each subdirectory.
Solution 2:
This indicates the number of hard links. This article explain the output of the ls -l
command in more detail.