← Back to team overview

touch-packages team mailing list archive

[Bug 1348775] Re: Supporting -D from e2fsck in e4defrag

 

Unfortunately, what you are requesting isn't possible.   E4defrag works
in an online mode -- that it is, it works while the file system is
mounted.

E2fsck -D works off-line; the file system must be unmounted to optimize
the directory.  So it simply wouldn't be possible to move the
functionality from e2fsck to e4defrag without adding a huge amount of
kernel support.  And in practice, honestly, it's rarely needed.

If you know no one is using a dirctory, you can mostly get the behaviour
you want by doing this:

mkdir foo.new ; mv foo.new/* foo ; rmdir foo ; mv foo.new foo

Of course, if something is trying to access the directory foo while you
are doing this, it will fail, which is why this isn't something that I
would put into e4defrag.  Also, it's pretty simple for anyone to do from
the command line.


** Changed in: e2fsprogs (Ubuntu)
       Status: New => Invalid

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to e2fsprogs in Ubuntu.
https://bugs.launchpad.net/bugs/1348775

Title:
  Supporting -D from e2fsck in e4defrag

Status in “e2fsprogs” package in Ubuntu:
  Invalid

Bug description:
  I'm using Ubuntu 14.10 dev with e2fsprogs 1.42.10-1.1ubuntu1 and
  e2fsck provides the option -D to optimize directories but in my
  opinion this is an option that would be more suitable in e4defrag
  (except that e2fsck also supports ext2 and ext3). Maybe e4defrag can
  support this option too if this action can be performed on a
  read/write mounted device which would have the advantage that no read-
  only remounting and a filesystem check is needed for the optimizing
  process.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/e2fsprogs/+bug/1348775/+subscriptions


References