On Mon, Aug 17, 2009 at 11:38 AM, Manish Katiyar <mkatiyar@xxxxxxxxx> wrote:
This is the starting point which I am looking for , you pointed exactly the same ...
Any document which describes above in details will be great ....
I reached here , already downloaded the source for e2fsck package and playing with it ....
I can read the superblock content(will write small module) using superblock operation pointed :
http://lxr.linux.no/#linux+v2.6.30.4/fs/ext3/super.c
You answered what i needed at this time ... Thanks
On Mon, Aug 17, 2009 at 11:06 AM, ajit mote<mail2blackmen@xxxxxxxxx> wrote:Each filesystem deals in the granularity of "block size" which is
>
> Hello,
>
> I would like to know how file system structures are mapped to hard disk
> sector.
generally configurable (typically 4K) during fs creation time. So each
block maps to 8 sectors (which are generally 512 bytes). Now given a
block number you can multiply it by 8 to get your hard disk sector.
This is the starting point which I am looking for , you pointed exactly the same ...
Any document which describes above in details will be great ....
Filesystem is created using a userspace binary (mke2fs for example in
> My goal is to understand how file system is created on block device
> and how superblocks are mapped to hard disk sectors.
case of ext2). Appropriate datastructures are written at appropiate
places during the FS creation time. See the sources of mkfs.c in
e2fsprogs.
I reached here , already downloaded the source for e2fsck package and playing with it ....
Superblock will have a predefined block number where it resides. From
the above calculation you can know which sector to read.
I can read the superblock content(will write small module) using superblock operation pointed :
http://lxr.linux.no/#linux+v2.6.30.4/fs/ext3/super.c
I am not sure if that answers your question correctly :-) . If not
>
> I am not sure whether I stated the problem precisely or not but if I did not
> described it properly then let me know.
please let me know.
You answered what i needed at this time ... Thanks
Thanks -
Manish
--
>
> This is just an understanding sort of issue which I am looking for teaching
> purpose.
>
> Note:
> Please free to change the subject line if not proper.
>
> --
> Thanks & Regards,
> Ajit Subhash Mote
>
>
Thanks -
Manish
--
Thanks & Regards,
Ajit Subhash Mote