[Top] [All Lists]

Re: Map a disk LBA to filename?

To: xfs@xxxxxxxxxxx
Subject: Re: Map a disk LBA to filename?
From: Dave Chinner <david@xxxxxxxxxxxxx>
Date: Thu, 30 Oct 2008 16:23:09 +1100
In-reply-to: <20081028093827.GA12133@kyra>
Mail-followup-to: xfs@xxxxxxxxxxx
References: <4905A3FB.6080709@xxxxxxxxxx> <20081027114945.GE4985@disturbed> <4905B48A.8010108@xxxxxxxxxx> <4905BC13.3030402@xxxxxxxxxxxxxx> <20081027233516.GG4985@disturbed> <4906BB32.8080403@xxxxxxxxxx> <20081028072105.GW4985@disturbed> <4906C164.6090704@xxxxxxxxxx> <4906D80F.9050500@xxxxxxxxxx> <20081028093827.GA12133@kyra>
User-agent: Mutt/1.5.18 (2008-05-17)
On Tue, Oct 28, 2008 at 10:38:27AM +0100, KELEMEN Peter wrote:
> * Carsten Aulbert (carsten.aulbert@xxxxxxxxxx) [20081028 10:14]:
> > Is it possible that blocks != bsized_blocks?
> xfs_bmap(8) talks in basic blocks (512 bytes).
> 660 div 8 = 82, so try:
>       blockget -b 82 -n

I think all of you need to know about the "convert" command ;)

e.g. to do the above conversion correctly:

xfs_db> convert daddr 660 fsb
0x52 (82)

The xfs_db man page tells you all the different formats that can
be converted between. The convert command automatically takes into
account the geometry of the filesystem where appropriate (e.g.
filesystem block size).


Dave Chinner

<Prev in Thread] Current Thread [Next in Thread>