views:

96

answers:

1

Hi,

I'm told to write a program in 'C' to print the contents of the 'super block'. Can anybody tell me how to read the contents of the super block. Which system call can be used to do so?

Thanks.

A: 

I guess what they want you to do is precisely to find this.

Hint: Googling "superblock linux" and pressing "I'm feeling lucky" got me straight to the first links to the answers. (Yes, there are several :) )!

Hint hint: If the fs is extN, there is a catch!

filofel
Ok! Thanks, I'll try it! :)
Supereme
Another hint: I don't think there is a syscall to read the superblock, but once you have figured out where the superblock is and what structure(s) it contains, starting by opening the raw disk partition containing the superblock will help!
filofel