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: Sat, 23 Oct 2021 12:24:40 +0200 From: Laurent GUERBY <laurent@...rby.net> To: linux-ext4@...r.kernel.org Subject: How to force EXT4_MB_GRP_CLEAR_TRIMMED on a live ext4? Hi, When using fstrim on an ext4 filesystem trim are not issued for EXT4_MB_GRP_WAS_TRIMMED space which is a useful optimization. Is there a way to force a complete trim on a mounted ext4 filesystem? My (limited) understanding of the code is that EXT4_MB_GRP_CLEAR_TRIMMED should be called to do so. My use case is having live migrated a virtual machine root disk from one storage to another, the target supporting trim, but since fstrim in the VM post migration does mostly nothing (assumes most space was trimmed) I cannot release space to the new storage. I tried mount -o remount but without effect. e2fsprogs don't seem to have an option/tool to do this either. I've seen suggestion that rebooting will do the job but the whole point of live migration is to avoid reboot :). I did end up creating dummy files to fill the filesystem and then removing them, but this is far less efficient than what a filesystem tool could do. Thanks in advance for your help, Sincerely, Laurent
Powered by blists - more mailing lists