[Gllug] ext3 options

salsaman salsaman at xs4all.nl
Tue Jan 17 22:23:29 UTC 2006


Emon wrote:

>Hi all
>
>I made a 11GB partition on my HDD (for storing stuffs like
>software,songs etc.) with ""cfdisk" and then did "mkfs.ext3" &
>checked the size with "df -m"
>
>It displays the size to be "10321".
>
>My first question is where has the (approximately) 900MB gone??
>
>Also I found this in "man mke2fs"
>
>*****************
>-m reserved-blocks-percentage
>Specify  the percentage of the filesystem blocks reserved for
>the super-user.  This avoids fragmentation, and allows
>root-owned daemons, such as syslogd(8), to continue to function
>correctly  after  non-privileged  processes are prevented from
>writing to the filesystem.  The default percentage is 5%.
>*****************
>
>Since I don't understand the function of "syslogd" (tried
>reading the man-pages, but that didn't help either) I am asking
>you guys, do I actually need to keep 5% (500MB approximately for
>11GB) of reserved-blocks??
>
>Thanks
>Emon
>  
>
I guess, since ext3 is a journalling fs, that most of this space is 
reserved for the journal. The rest will be for inodes for the filesystem.

The -i option to mke2fs says:

 -i bytes-per-inode
              Specify the bytes/inode ratio.   mke2fs  creates  an  
inode  for
              every  bytes-per-inode  bytes  of space on the disk.  The 
larger
              the bytes-per-inode ratio, the fewer  inodes  will  be  
created.
              This  value generally shouldn't be smaller than the 
blocksize of
              the filesystem, since then too many inodes  will  be  
made.   Be
              warned  that is not possible to expand the number of 
inodes on a
              filesystem after it is created, so be careful deciding 
the  cor-
              rect value for this parameter.

the -J parameter lets you tune the journal size:

 size=journal-size
                          Create  an internal journal (i.e., stored 
inside the
                          filesystem) of  size  journal-size  
megabytes.   The
                          size of the journal must be at least 1024 
filesystem
                          blocks (i.e., 1MB if using 1k blocks, 4MB  if  
using
                          4k  blocks,  etc.)   and may be no more than 
102,400
                          filesystem blocks.

if you don't specify it, the default is used.

That would explain the 400MB.

Then as you pointed out, 5% is "reserved space".


Regards,
Salsaman.
http://lives.sourceforge.net

-- 
Gllug mailing list  -  Gllug at gllug.org.uk
http://lists.gllug.org.uk/mailman/listinfo/gllug




More information about the GLLUG mailing list