lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Fri, 18 Dec 2020 19:40:09 +0100 From: Matteo Croce <mcroce@...ux.microsoft.com> To: linux-ext4@...r.kernel.org Subject: discard and data=writeback Hi, I noticed a big slowdown on file removal, so I tried to remove the discard option, and it helped a lot. Obviously discarding blocks will have an overhead, but the strange thing is that it only does when using data=writeback: Ordered: $ dmesg |grep EXT4 [ 0.243372] EXT4-fs (vda1): mounted filesystem with ordered data mode. Opts: (null) $ grep -w / /proc/mounts /dev/root / ext4 rw,noatime 0 0 $ time rm -rf linux-5.10 real 0m0.454s user 0m0.029s sys 0m0.409s $ grep -w / /proc/mounts /dev/root / ext4 rw,noatime,discard 0 0 $ time rm -rf linux-5.10 real 0m0.554s user 0m0.051s sys 0m0.403s Writeback: $ dmesg |grep EXT4 [ 0.243909] EXT4-fs (vda1): mounted filesystem with writeback data mode. Opts: (null) $ grep -w / /proc/mounts /dev/root / ext4 rw,noatime 0 0 $ time rm -rf linux-5.10 real 0m0.440s user 0m0.030s sys 0m0.407s $ grep -w / /proc/mounts /dev/root / ext4 rw,noatime,discard 0 0 $ time rm -rf linux-5.10 real 0m3.763s user 0m0.030s sys 0m0.876s It seems that ext4_issue_discard() is called ~300 times with data=ordered and ~50k times with data=writeback. I'm using vanilla 5.10.1 kernel. Any thoughts? Regards, -- per aspera ad upstream
Powered by blists - more mailing lists