Page 1 of 1

Resize Inode

Posted: Thu Jun 07, 2012 9:37 am
by iansjack
I've Googled, searched the Wiki and forums and come up with northing about this question, so I hope that I've done my homework.

I'm implementing an ext2 filesystem driver and when testing it I've come across the "resize inode". When I write a file and then do fsck it shows that there is a problem with this entity. For the time being I have taken the easy way out and have created my filesystem without a resize inode, which also provides more free blocks, but I'm curious to know how it works. I know that it's inode 7, but more than that is a mystery. Does anyone have a simple explanation, or a pointer to one? If not then I guess it's a question of studying the Linux source code or trying to reverse engineer by studying what happens to that particular inode as files are created/destroyed on a Linux system.

It's not that important, but I hate not knowing how things work.

Re: Resize Inode

Posted: Thu Jun 07, 2012 10:53 am
by iansjack
I don't think so. I think that refers to the possibilty of a fs having an inode size different from the "standard" 128 bytes. The resize inode, as far as I can make out, is something that allows one to dynamically resize the fs. Since it reserves quite a few extra blocks I expect that these somehow keep track of information about the fs and the inode tracks them. But how it works is a mystery. There are not many subjects that Google fails to give any information on.

The default in my Fedora 17 is to include this inode when creating an ext fs so I'm guessing that many of us have one but have no idea how it works!