Comment 33 for bug 321528

Revision history for this message
Rocko (rockorequin) wrote : Re: Include ext4 defrag / defragment tool

Cool, the e4defrag built with those patches seems to work fine. The check function (-c) on my root partition reported a fragmentation score of zero (I guess it must be an average) but did find a number of fragmented files, eg

<Fragmented files> now/best size/ext
1. /var/log/pm-powersave.log 8/1 4 KB
Total/best extents 8/1
 Average size per extent 4 KB
 Fragmentation score 98
 [0-30 no problem: 31-55 a little bit fragmented: 56- needs defrag]

Running e4defrag on this file resulted in:

<File> now/best size/ext
/var/log/pm-powersave.log 1/1 32 KB
 Total/best extents 1/1
 Average size per extent 32 KB
 Fragmentation score 0
 [0-30 no problem: 31-55 a little bit fragmented: 56- needs defrag]

If I run it on a directory, it reports a number of 'successes' and 'failures'. I suspect the failures are for files that are locked (wpa_supplicant was one such file), ie not all files can be defragged online.

The "relevant files defrag" always reports a 100% failure rate for some reason.