Re: Map a disk LBA to filename?

Michal Soltys
2008-10-27T13:03:46Z

Carsten Aulbert wrote:
>
> Dave Chinner wrote:
>> Use xfs_bmap to find the location on disk of the extents in each
>> file. Recurse over the filesystem until you find the file that owns
>> the block that went bad.
>
> Sounds like a tedious but doable route to take.
>

Wouldn't something like (under xfs_db) :

getblock -b #block -n
ncheck -i #inode

where required #inode is reported by getblock

do the thing ?