Re: Question related to XFS sync , especially fsync

2 messages, 2 authors, 2008-01-17 · open the first message on its own page

Re: Question related to XFS sync , especially fsync

From: Andi Kleen <hidden>
Date: 2008-01-17 01:24:52

"Gopala Krishna" [off-list ref] writes:
we need to get information about
file like it's extent information and associated block numbers etc.
 To
extract these there is no system call 
Actually there is the FIOBMAP ioctl for data blocks. e.g. it's used by
boot loaders like lilo to create a block map to read a file without
knowledge of the file system. Should work on all file systems that
support lilo.

It won't give you information about metadata blocks though.

-Andi

Re: Question related to XFS sync , especially fsync

From: David Chinner <hidden>
Date: 2008-01-17 02:44:44

On Thu, Jan 17, 2008 at 02:25:00AM +0100, Andi Kleen wrote:
"Gopala Krishna" [off-list ref] writes:
quoted
we need to get information about
file like it's extent information and associated block numbers etc.
 To
quoted
extract these there is no system call 
Actually there is the FIOBMAP ioctl for data blocks. e.g. it's used by
boot loaders like lilo to create a block map to read a file without
knowledge of the file system. Should work on all file systems that
support lilo.
On XFS, you should use XFS_IOC_GETBMAPX. It's much faster
and returns lots more information than FIOBMAP. It can also
be used on the attribute fork of the inode, and it works on
directories as well.

Cheers,

Dave.
-- 
Dave Chinner
Principal Engineer
SGI Australian Software Group
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help