Results 1 to 4 of 4
What does total line refers in ls -l output ?...
- 07-24-2008 #1
total in "ls -l" command ????
What does total line refers in ls -l output ?
- 07-24-2008 #2
Code:[/E*Fare/Users/qabuild/aksutil/giga] $ ls -ltr total 24 -rw-rw-r-- 1 qabuild DENCCEFS 5 Jul 24 21:03 1 -rw-rw-r-- 1 qabuild DENCCEFS 5 Jul 24 21:03 2 -rw-rw-r-- 1 qabuild DENCCEFS 10428 Jul 24 21:28 ls-ltr drwxrwxr-x 2 qabuild DENCCEFS 4096 Jul 24 21:35 chand/ drwxrwxr-x 3 qabuild DENCCEFS 4096 Jul 24 21:35 pakoda/ drwxrwxr-x 3 qabuild DENCCEFS 4096 Jul 24 21:45 giga1/ [/E*Fare/Users/qabuild/aksutil/giga] $ du -ch ls-ltr 12K ls-ltr 12K total [/E*Fare/Users/qabuild/aksutil/giga] $ ls -ltra total 40 drwxrwxr-x 26 qabuild DENCCEFS 12288 Jul 24 21:03 ../ -rw-rw-r-- 1 qabuild DENCCEFS 5 Jul 24 21:03 1 -rw-rw-r-- 1 qabuild DENCCEFS 5 Jul 24 21:03 2 -rw-rw-r-- 1 qabuild DENCCEFS 10428 Jul 24 21:28 ls-ltr drwxrwxr-x 2 qabuild DENCCEFS 4096 Jul 24 21:35 chand/ drwxrwxr-x 3 qabuild DENCCEFS 4096 Jul 24 21:35 pakoda/ drwxrwxr-x 3 qabuild DENCCEFS 4096 Jul 24 21:45 giga1/ drwxrwxr-x 5 qabuild DENCCEFS 4096 Jul 24 21:51 ./ [/E*Fare/Users/qabuild/aksutil/giga] $
total in first case is 24...which is 4 for chand folder, 4 for pakoda folder, 4 for giga1 folder and 12 for ls-ltr file (note: 10428 bytes of file will not fit in 4+4 KB of 2 blocks that's why 3 blocks of 4 KB) i.e. 12 KB.
Thus, 12, 4+4+4= 24.
now, how come it's reflecting 40 ???? with "a" option with ls command.
- 07-26-2008 #3Linux User
- Join Date
- May 2008
- Location
- NYC, moved from KS & MO
- Posts
- 251
ls -la lists files (including directories) names that start with . (dot) while ls -l does not.
- 07-27-2008 #4Linux Engineer
- Join Date
- Feb 2005
- Posts
- 1,044
And the -A option supresses the display of current (.) and parent (..) directories.


Reply With Quote