LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 07-22-2016, 09:20 AM   #1
perfection
Member
 
Registered: Nov 2015
Distribution: Slackware64-Current
Posts: 54

Rep: Reputation: Disabled
Question Basic doubt command LS (Does anyone know the meaning of totals ls command?)


Does anyone know the meaning of totals ls command?
Because:
1) is not the amount of files
2) is not the sum of Bytes
3) is not the sum of the numbers in the second Column
4) is not the size of these folders

Code:
bash-4.3# ls -l
total 48
drwxr-xr-x  5 nik root  4096 Jul 17 07:07 ARTICLES/
drwxr-xr-x  2 nik root  4096 Jul 12 21:38 ARTICLES\ SECUNDARY/
drwxr-xr-x  4 nik root  4096 Jul 19 13:27 DRIVERS/
drwxr-xr-x 10 nik root  4096 Jul 17 07:05 GRAPHICS\ AND\ SOUNDS/
drwxr-xr-x  8 nik root  4096 Jul 19 14:45 THINGS\ AND\ PROGRAMMING/
drwxr-xr-x 11 nik root  4096 Jul 21 18:30 MAINTENANCE/
drwxr-xr-x  4 nik root  4096 Jul  3 20:30 NETWORK\ AND\ INTERNET/
drwxr-xr-x  2 nik root  4096 Jul 14 04:07 NO\ USE/
drwxr-xr-x  2 nik root  4096 Jul  5 01:41 Nepomuk\ e\ Akonadi/
-rw-rw----  1 nik users 5564 Jul 19 08:19 Report\ Programs.htx
drwxr-xr-x  7 nik root  4096 Jul 21 17:34 SO/

bash-4.3# ls -la
total 60
drwxr-xr-x 12 nik root  4096 Jul 19 08:19 ./
drwxr-xr-x  9 nik root  4096 Jul 19 16:04 ../
-rw-rw----  1 nik root    64 Jul  1 03:46 .directory
drwxr-xr-x  5 nik root  4096 Jul 17 07:07 ARTICLES/
drwxr-xr-x  2 nik root  4096 Jul 12 21:38 ARTICLES\ SECUNDARY/
drwxr-xr-x  4 nik root  4096 Jul 19 13:27 DRIVERS/
drwxr-xr-x 10 nik root  4096 Jul 17 07:05 GRAPHICS\ AND\ SOUNDS/
drwxr-xr-x  8 nik root  4096 Jul 19 14:45 THINGS\ AND\ PROGRAMMING/
drwxr-xr-x 11 nik root  4096 Jul 21 18:30 MAINTENANCE/
drwxr-xr-x  4 nik root  4096 Jul  3 20:30 NETWORK\ AND\ INTERNET/
drwxr-xr-x  2 nik root  4096 Jul 14 04:07 NO\ USE/
drwxr-xr-x  2 nik root  4096 Jul  5 01:41 Nepomuk\ e\ Akonadi/
-rw-rw----  1 nik users 5564 Jul 19 08:19 Report\ Programs.htx
drwxr-xr-x  7 nik root  4096 Jul 21 17:34 SO/
 
Old 07-22-2016, 09:42 AM   #2
Habitual
LQ Addict
 
Registered: Jan 2011
Location: Youngstown, Ohio
Distribution: LM17.1/Xfce4.11.8
Posts: 7,195
Blog Entries: 10

Rep: Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985Reputation: 1985
blah.
Chaps my hide that I don't know. Sorry!

Last edited by Habitual; 07-22-2016 at 09:45 AM.
 
Old 07-22-2016, 10:02 AM   #3
michaelk
Moderator
 
Registered: Aug 2002
Posts: 14,963

Rep: Reputation: 1530Reputation: 1530Reputation: 1530Reputation: 1530Reputation: 1530Reputation: 1530Reputation: 1530Reputation: 1530Reputation: 1530Reputation: 1530Reputation: 1530
From the ls info pages.
Quote:
For each directory that is listed, preface the files with a line
`total BLOCKS', where BLOCKS is the total disk allocation for all
files in that directory. The block size currently defaults to 1024
bytes, but this can be overridden (*note Block size:. The
BLOCKS computed counts each hard link separately; this is arguably
a deficiency.
You can get the number of blocks for each file via the -s option.
 
1 members found this post helpful.
Old 07-22-2016, 10:19 AM   #4
hydrurga
Senior Member
 
Registered: Nov 2008
Distribution: Linux Mint 18 MATE
Posts: 1,214

Rep: Reputation: 345Reputation: 345Reputation: 345Reputation: 345
Some interesting comments on it here: http://stackoverflow.com/questions/7...ine-after-ls-l
 
1 members found this post helpful.
Old 07-22-2016, 02:29 PM   #5
perfection
Member
 
Registered: Nov 2015
Distribution: Slackware64-Current
Posts: 54

Original Poster
Rep: Reputation: Disabled
Thumbs up

Quote:
Originally Posted by michaelk View Post
You can get the number of blocks for each file via the -s option.
Quote:
Originally Posted by hydrurga View Post
Some interesting comments on it here: http://stackoverflow.com/questions/7...ine-after-ls-l
Thanks for these 2 answers, were great!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Please interpret the meaning of this command murali2489 Linux - Newbie 5 03-23-2015 07:03 AM
What is meaning of top command redhatwannabe Linux - Server 1 02-27-2014 01:42 AM
[SOLVED] Trying to find meaning of command with ½ waddles Slackware 5 09-19-2013 04:28 PM
how Command interpreter understand the meaning of command tushar_pandey Linux - Newbie 5 08-21-2012 05:25 PM
command meaning ramrann Linux - Newbie 2 10-18-2005 02:56 PM


All times are GMT -5. The time now is 04:51 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration