tag 929186 +pending
thanks

On Sun, May 19, 2019 at 09:29:26AM +1200, jfp wrote:
> Package: e2fsprogs
> Version: 1.45.1-1
> Severity: important
> Tags: upstream
> 
> The latest update on multiple machines produces this error on all non-LVM disk
> (I have NO LVM disks in those workstations)

Oops, thanks for the bug report!  The following patch will be in the
the next release.  You can either apply this patch to
/sbin/e2scrub_all, or just disable the e2scrub_all timer unit.

                                        - Ted

>From fbb9bfa4a5925f8049ef51d8f59eb94920781ec8 Mon Sep 17 00:00:00 2001
From: Theodore Ts'o <[email protected]>
Date: Sat, 18 May 2019 23:04:49 -0400
Subject: [PATCH] e2scrub_all: avoid scrubbing all devices when there is
 nothing to scrub

Running lsblk when there are no valid block devicse results in
generating all block devices as the list of devices to scrub; this
results in a lot of e2scrub_all failures.

Addresses-Debian-Bug: #929186

Signed-off-by: Theodore Ts'o <[email protected]>
---
 scrub/e2scrub_all.in | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/scrub/e2scrub_all.in b/scrub/e2scrub_all.in
index 7ee653158..abc237e42 100644
--- a/scrub/e2scrub_all.in
+++ b/scrub/e2scrub_all.in
@@ -103,8 +103,12 @@ fi
 
 # Find scrub targets, make sure we only do this once.
 ls_scan_targets() {
-       lsblk -o NAME,MOUNTPOINT,FSTYPE -P -n -p \
-             $(lvs -o lv_path --noheadings -S 
"lv_active=active,lv_role=public,lv_role!=snapshot,vg_free>${snap_size_mb}") | \
+    local devices=$(lvs -o lv_path --noheadings -S 
"lv_active=active,lv_role=public,lv_role!=snapshot,vg_free>${snap_size_mb}")
+
+    if [ -z "$devices" ]; then
+       return 0;
+    fi
+    lsblk -o NAME,MOUNTPOINT,FSTYPE -P -n -p $devices | \
            grep FSTYPE=\"ext\[234\]\" | while read vars ; do
                eval "${vars}"
 
-- 
2.19.1

Reply via email to