e2fsprogs Help.

tytso at mit.edu tytso at mit.edu
Sun Feb 28 05:56:48 UTC 2010


On Sat, Feb 27, 2010 at 11:52:38AM -0600, MirJafar Ali wrote:
> 
> Hope you will forgive me for asking some very simple question about
> e2fsprogs. I am very new to the kernel as
> well as file system programming.
> 
> My task is to collect superblock, inode, bitmap ( or free list)  information
> from ext2/ext3 filesysteam. After searching
> the google, I came to know about e2fsprogs, which I was able to install and
> use at least "dumpe2fs" utility. This
> utility do not provide timestamp of each allocated inode and I am thinking
> of modifying source code of e2fsprogs.

Um, this wouldn't be for a school assignment, would it?

Why are you being asked to do this?  What is the high level problem
are you trying to solve, or the high-level goal you are trying to
accomplish?


> My two questions are:
> 
> 1.   Is it correct to use "dumpe2fs" program and modify for timestamp ?

Probably not.  You might want to look at the "debugfs" program, which
is also included in e2fsprogs.  Reading the man pages would alos be a
good idea.

Do you realize that these programs were probably already installed on
your Linux system?  

> 2.   I could not understand the main purpose of e2fsprogs. Am I correct to
> assume that this program extract information
>      from the existing ext2/ext3 filesystem. 

E2fsprogs is a suite of programs that provide the userspace support
for the ext2, ext3, and ext4 file systems.  So mke2fs wil create a new
file system; debugfs is the program that allows you to look at and
manipulate low-level file system structures conveniently from
userspace (for debugging or developer convenience; users of file
systems shouldn't be using this for their everyday activities); e2fsck
is the filesystem consistency checker, and so on.

> Why there are ext2_inode
> datastructure defined in these programs ? Why couldn't
>      these programs read existing datastructures of inode ?
> 3.  Are these user level or kernel level programs ?

OK, now I'm *sure* this is for a school assignment.

> 4.  I want to have my own policies of allocatiing datablocks in some
> cylinder group instead of using ext2 default policy ? What
>     should I do for that ?

If you can't tell the difference between user and kernel level
programs, you're probably way out of your depth to be trying to do
this.  I suggest you talk to your professor or recitation
instructor....

						- Ted

>  I know, these must be silly questions, but I will learn from your
> response.  Mir.




More information about the Ext3-users mailing list