From 5b4ad40febbe22513057a4788a1695c6bc2446c9 Mon Sep 17 00:00:00 2001 From: Ruediger Meier Date: Wed, 9 Mar 2016 12:01:54 +0100 Subject: [PATCH] tests: ignore swapon warnings swapon/mkswap warns if system sets different permissions for loop devices. I saw this on Debian 7 (wheezy)/linux-3.2: mkswap: /dev/loop0: insecure permissions 1660, 0660 suggested. swapon: /dev/loop0: insecure permissions 1660, 0660 suggested. Signed-off-by: Ruediger Meier --- tests/ts/swapon/devname | 3 +++ tests/ts/swapon/fixsig | 3 +++ tests/ts/swapon/label | 3 +++ tests/ts/swapon/uuid | 3 +++ 4 files changed, 12 insertions(+) diff --git a/tests/ts/swapon/devname b/tests/ts/swapon/devname index 978b875a05..de9a5f20c6 100755 --- a/tests/ts/swapon/devname +++ b/tests/ts/swapon/devname @@ -42,6 +42,9 @@ grep -q $DEVICE /proc/swaps || ts_die "Cannot find $DEVICE in /proc/swaps" $TS_CMD_SWAPOFF $DEVICE +# swapon/mkswap warns if system sets different permissions for loop devices +sed --in-place '/insecure permissions .*, 0660 suggested/d' $TS_OUTPUT + ts_log "Success" ts_finalize diff --git a/tests/ts/swapon/fixsig b/tests/ts/swapon/fixsig index 6fceb79f80..36c7d9f763 100755 --- a/tests/ts/swapon/fixsig +++ b/tests/ts/swapon/fixsig @@ -44,6 +44,9 @@ grep -q $DEVICE /proc/swaps || ts_die "Cannot find $DEVICE in /proc/swaps" $TS_CMD_SWAPOFF $DEVICE +# swapon/mkswap warns if system sets different permissions for loop devices +sed --in-place '/insecure permissions .*, 0660 suggested/d' $TS_OUTPUT + ts_log "Success" ts_finalize diff --git a/tests/ts/swapon/label b/tests/ts/swapon/label index af7da4f290..bbcd771bed 100755 --- a/tests/ts/swapon/label +++ b/tests/ts/swapon/label @@ -44,6 +44,9 @@ grep -q $DEVICE /proc/swaps || ts_die "Cannot find $DEVICE in /proc/swaps" $TS_CMD_SWAPOFF $DEVICE +# swapon/mkswap warns if system sets different permissions for loop devices +sed --in-place '/insecure permissions .*, 0660 suggested/d' $TS_OUTPUT + ts_log "Success" ts_finalize diff --git a/tests/ts/swapon/uuid b/tests/ts/swapon/uuid index 954e8cdf43..9f244f39a4 100755 --- a/tests/ts/swapon/uuid +++ b/tests/ts/swapon/uuid @@ -44,6 +44,9 @@ grep -q $DEVICE /proc/swaps || ts_die "Cannot find $DEVICE in /proc/swaps" $TS_CMD_SWAPOFF $DEVICE +# swapon/mkswap warns if system sets different permissions for loop devices +sed --in-place '/insecure permissions .*, 0660 suggested/d' $TS_OUTPUT + ts_log "Success" ts_finalize -- 2.47.2