Barry Naujok wrote:
On Fri, 29 Jun 2007 16:21:58 +1000, Just Marc <marc@xxxxxxxxx> wrote:
Hi Eric,
In my particular case, and I'm sure for many other people, files that
are stored never change again until they deleted. I hinted that
there could be a command line switch to turn this functionality on,
as it may not be perfect for everyone's use cases.
If nobody likes this still, I would appreciate some hints on how to
mark files as no-defrag from within fsr itself given that I only have
the file descriptor ... A hack like looking up the descriptor in
/proc/self/fd should work, but is linux specific and is too hackish
in my opinion. I'd like to at least have a nice simple patch for my
own uses.
Eric,
You can use the xfs_io chattr command to mark known files as
nodefrag. Using the chattr -R option can be used to recurse
directories.
Barry,
That's right but I can't do this on a filesystem that's just been
defragged say a minute ago, and in the mean time 20 new files got added
(I don't know what these files are... ).
The whole filesystem has to be scanned again and here comes the issue:
fsr wants to try and reduce the extents of many files for which it can't
do it thus incurring lots of work and load until it can even reach the
new files do defrag them...
Marc
|