summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorge Engelbrecht <engeg@google.com>2021-09-16 17:41:01 -0600
committerCommit Bot <commit-bot@chromium.org>2021-09-17 19:33:21 +0000
commit20660716b0273d82ccf456bf990451276472593a (patch)
tree0575da7791378395352dbfaec5d18e291575f1d5
parentff416f58a0bc7ac25871085b0adb0078a684f1c5 (diff)
downloadvboot-stabilize-14235.B.tar.gz
strip_boot_from_image: use sfill instead of fstrimstabilize-14235.B
fstrim relies on the underlying device supporting it and on our instances we're on lvm devices. Since we're fstrim'ing a mounted loopback the ability to call fstrim is inherited by the parent device. Something has changed in the kernel (see bug) that stopped us from making the trim call on the loopback partition. sfill with these options should accomplish the same thing (single write with all zeros) as well as cleaning up inode space. BRANCH=main BUG=b:200038130 TEST=signer full tests with this commit. Signed-off-by: engeg <engeg@google.com> Change-Id: I8c71adfd59c11b5142aa367fb20222fc4b03a2ba Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/vboot_reference/+/3167191 Tested-by: George Engelbrecht <engeg@google.com> Auto-Submit: George Engelbrecht <engeg@google.com> Reviewed-by: Jason Clinton <jclinton@chromium.org> Reviewed-by: Jared Loucks <jaredloucks@google.com> Reviewed-by: Greg Edelston <gredelston@google.com> Commit-Queue: George Engelbrecht <engeg@google.com> Commit-Queue: Greg Edelston <gredelston@google.com>
-rwxr-xr-xscripts/image_signing/strip_boot_from_image.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/image_signing/strip_boot_from_image.sh b/scripts/image_signing/strip_boot_from_image.sh
index 2971b087..0f363902 100755
--- a/scripts/image_signing/strip_boot_from_image.sh
+++ b/scripts/image_signing/strip_boot_from_image.sh
@@ -27,7 +27,7 @@ zero_free_space() {
local rootfs="$1"
info "Zeroing freespace in ${rootfs}"
- sudo fstrim -v "${rootfs}"
+ sudo sfill -llz "${rootfs}"
}