public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
* Re: Doubt about allocation of extents
       [not found] <BLU169-W94914B167C788ACAB92562E1060@phx.gbl>
@ 2015-03-12 12:04 ` Brian Foster
  0 siblings, 0 replies; only message in thread
From: Brian Foster @ 2015-03-12 12:04 UTC (permalink / raw)
  To: Dhruvesh Rathore; +Cc: sandeen@sandeen.net, hch@lst.de, xfs

(cc xfs)

On Thu, Mar 12, 2015 at 02:03:25AM +0000, Dhruvesh Rathore wrote:
> Hi,
> I have a question about allocation of existing extents to another file, and whetherit is possible ?
> A recently created file (temp) can have new extents created using lseek64()and the XFS_IOC_RESVP64.These empty extents can be populated by copying the data blocks from another file.(The above is mostly done in xfs_fsr, the online defragmenter of XFS).
> My question is that can i assign an existing populated extent held by another file, to thisnewly created temp file ?
> Any suggestions for the same will be appreciated :)

I think what you're describing is a clone or reflink type operation that
allows extents to be referenced by multiple files at once (e.g., writes
break the references via cow, etc.). Either that, or an extent move
operation that IIUC is something that extN supports. I suspect the
latter is more what you want if the target is defrag. XFS does not
support either at this time, though I think Dave is designing something
that might facilitate reflink down the road.

The only related operation I'm aware of for XFS right now is the swap
extents operation, which swaps the extents between two inodes. xfs_fsr
uses this along with a data copy to defragment files.

Brian

> Regards,Dhruvesh  		 	   		  

_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2015-03-12 12:05 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <BLU169-W94914B167C788ACAB92562E1060@phx.gbl>
2015-03-12 12:04 ` Doubt about allocation of extents Brian Foster

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox