-   Red Hat (
-   -   how to calculate the bytes-per-inodes value? (

z@ki 02-17-2010 12:53 PM

how to calculate the bytes-per-inodes value?
Hi all

I am a brand new member :cool:

here is my question :

in a RedHat configuration :

i need to be sure that a partition has been formatted with those parameters :

mkfs.ext3 -O dir_index -i 1024000 -L /data2 -T largefile4 /dev/sdc1
but i can't succed to calculate back the value of bytes-per-inodes value (-i parameters) = 1024000

i have tried to divide value obtained with df and df -i without sucess.
i also have tried with the "tune2fs -l /dev/sdc1" command to obtain values to calculate

the goal is to make some checkout on already installed configs

Is there a way to calculate this value ?

example :
df gives me :

Sys. de fich.        1K-blocs      Occupé Disponible Capacité Monté sur
/dev/sdc1            244070584  65215268 166649132  29% /data2

df -i gives me:

Sys. de fich.        Inodes  IUtil.  ILib. %IUti. Monté sur
/dev/sdc1            298080  29083  268997  10% /data2

tune2fs -l /dev/sdc1 gives me :

tune2fs 1.39 (29-May-2006)
Filesystem volume name:  /data2
Last mounted on:          <not available>
Filesystem UUID:          9c66e9ab-b6bb-4cd4-9bb5-18a6592f91d4
Filesystem magic number:  0xEF53
Filesystem revision #:    1 (dynamic)
Filesystem features:      has_journal resize_inode dir_index filetype needs_recovery sparse_super large_file
Default mount options:    (none)
Filesystem state:        clean
Errors behavior:          Continue
Filesystem OS type:      Linux
Inode count:              298080
Block count:              61030927
Reserved block count:    3051546
Free blocks:              51754162
Free inodes:              268998
First block:              0
Block size:              4096
Fragment size:            4096
Reserved GDT blocks:      1009
Blocks per group:        32768
Fragments per group:      32768
Inodes per group:        160
Inode blocks per group:  5
Filesystem created:      Fri Jul 24 15:02:05 2009
Last mount time:          Tue Aug 25 17:56:33 2009
Last write time:          Tue Aug 25 17:56:33 2009
Mount count:              6
Maximum mount count:      38
Last checked:            Fri Jul 24 15:02:05 2009
Check interval:          15552000 (6 months)
Next check after:        Wed Jan 20 14:02:05 2010
Reserved blocks uid:      0 (user root)
Reserved blocks gid:      0 (group root)
First inode:              11
Inode size:              128
Journal inode:            8
Default directory hash:  tea
Directory Hash Seed:      3a5b08b6-8bd2-4639-a9a4-4063710bb1ac
Journal backup:          inode blocks

any idea?

DrLove73 02-17-2010 06:03 PM

Only if people would spend time searching the web before posting!

z@ki 02-24-2010 11:33 AM

Hi DrLove73

as a matter of fact, i posted because my searches on Google were unfruitful...

the page you indicate concerns commands that are suitable for Solaris but not for Red Hat

mkfs -m is not the same option signification in red hat
and df -g doesn't exists under RH

thank you anyway for your reply :hattip:

only if people would spend time reading the whole post before replying!

DrLove73 02-24-2010 03:17 PM

Well, I rarely touched this problematic before, but wished too help if I can. I looked promising. 7 days latter no one else responded, so I guess your only option is to contact who ever build df or mkfs.

I guess your last paragraph was well deserved. You would be surprised how many people just do not care to look for them selves. Sorry.

All times are GMT -5. The time now is 06:42 PM.