Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 27 Jul 2007 16:04:13 -0400
From:      Kris Kennaway <kris@obsecurity.org>
To:        Andrew Falanga <af300wsm@gmail.com>
Cc:        User Questions <freebsd-questions@freebsd.org>
Subject:   Re: The output of ls
Message-ID:  <20070727200413.GA48670@rot26.obsecurity.org>
In-Reply-To: <340a29540707271257h69c89189w10917672cac7f3db@mail.gmail.com>
References:  <340a29540707271257h69c89189w10917672cac7f3db@mail.gmail.com>

Next in thread | Previous in thread | Raw E-Mail | Index | Archive | Help
On Fri, Jul 27, 2007 at 01:57:54PM -0600, Andrew Falanga wrote:
> Hi,
> 
> I'm wondering what the output means when one does an "ls -lR".  Here's
> some sample output from my home dir:
> 
> ./programs:
> total 900
> -rwxr-xr-x  1 afalanga  afalanga    5467 Sep 25  2006 4or6
> -rw-r--r--  1 afalanga  afalanga     606 Dec 20  2006 abc.cxx
> -rwxr-xr-x  1 afalanga  afalanga    8436 Dec 20  2006 abs
> -rw-r--r--  1 afalanga  afalanga     970 Dec 12  2006 bindtest.c
> -rwxr-xr-x  1 afalanga  afalanga    5666 Dec 12  2006 bt
> -rw-r--r--  1 afalanga  afalanga     654 Jun  5 08:12 filetest.cxx
> -rwxr-xr-x  1 afalanga  afalanga    5223 Nov 16  2006 foo
> -rw-r--r--  1 afalanga  afalanga     397 Nov 16  2006 foo.c
> -rw-r--r--  1 afalanga  afalanga     502 May 25 07:20 foo.cxx
> -rwxr-xr-x  1 afalanga  afalanga    8733 May 25 07:20 foocxx
> -rwxr-xr-x  1 afalanga  afalanga    9359 Jun  5 08:12 ft
> -rw-r--r--  1 afalanga  afalanga     172 Dec 20  2006 negtest.cxx
> -rwxr-xr-x  1 afalanga  afalanga    6986 Dec 20  2006 nt
> -rw-r--r--  1 afalanga  afalanga     100 Nov 16  2006 obj.c
> -rw-r--r--  1 afalanga  afalanga     796 Nov 16  2006 obj.o
> -rwxr-xr-x  1 afalanga  afalanga    6316 May 23 10:43 td
> -rw-------  1 afalanga  afalanga  327680 May 23 10:22 td.core
> -rwxr-xr-x  1 root      afalanga    5552 Jul 26  2006 test
> -rw-r--r--  1 afalanga  afalanga    1267 May 23 10:43 test.c
> -rw-r--r--  1 afalanga  afalanga     407 Jan 10  2007 test.cxx
> -rwxr-xr-x  1 afalanga  afalanga    8760 Jan 10  2007 testc
> -rw-------  1 afalanga  afalanga  430080 Jan  3  2007 testc.core
> -rw-r--r--  1 afalanga  afalanga     100 Jun  5 07:45 testtest.txt
> -rw-r--r--  1 afalanga  afalanga     185 Dec 15  2006 timetest.cxx
> -rwxr-xr-x  1 afalanga  afalanga    7008 Dec 15  2006 tt
> -rw-r--r--  1 afalanga  afalanga    1142 Sep 25  2006 v6.c
> -rw-r--r--  1 afalanga  afalanga      67 Jan  5  2007 willitwork
> 
> ./scripts:
> total 4
> -rw-r--r--  1 afalanga  afalanga   970 Oct 12  2006 newtables.sql
> -rwxr--r--  1 afalanga  afalanga  1777 Jun  1 10:59 test.tcl
> 
> 
> Right underneath the directory that is being probed at that point is a
> number, "total X".  What is X referring to?  Is it blocks, bytes,
> what?

RTFM ;-)

     The listing of a directory's contents is preceded by a labeled total num-
     ber of blocks used in the file system by the files which are listed as
     the directory's contents (which may or may not include . and .. and other
     files which start with a dot, depending on other options).

Kris



Want to link to this message? Use this URL: <http://docs.FreeBSD.org/cgi/mid.cgi?20070727200413.GA48670>