[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: debugfs Question



On Apr 19, 2007  23:19 -0700, Aravindan Raghuveer wrote:
> My goal is to be able to read files on a ext3
> filesystem through the scsi generic (sg) driver. 
> I first use debugfs to extract the block addresses for
> every file. I then multiply the block address by 8
> [4K/ 512] to obtain the LBAs. I then use a progam
> sg_dd in the sg toolkit to read the data stored in the
> LBA obtained above. 

This is completely unsafe.  There is no reason why the data on disk
matches what is in memory due to many layers of indirection (RAM,
buffer cache, journal, etc).

Cheers, Andreas
--
Andreas Dilger
Principal Software Engineer
Cluster File Systems, Inc.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]