Add Book to My BookshelfPurchase This Book Online

Appendix B - Accessing Filesystem Data Structures

UNIX Systems Programming for SVR4
David A. Curry
 Copyright © 1996 O'Reilly & Associates, Inc.

Summary
Reading a filesystem's data structures directly off the disk is not inherently difficult, but is hindered by the fact that there is very little documentation available on the structures used to implement the filesystem. A number of the fields in these structures are stored in various units (e.g., filesystem blocks), and must be converted to other units (e.g., disk blocks) to be used. The units used, as well as the formulas to convert them, are not generally documented.
There is nothing “wrong” with reading a filesystem in this way; indeed, sometimes it is necessary. However, it is a relatively non-portable approach, and also requires privileged processes. Both of these concerns must be addressed when making any decision about going through the kernel or reading the filesystem directly.

Previous SectionNext Section
Books24x7.com, Inc © 2000 –  Feedback