From 17169e26fc8bf2281028627893dd9aede5bb9e67 Mon Sep 17 00:00:00 2001 From: Pavel Cahyna Date: Thu, 28 Jul 2022 20:54:21 +0200 Subject: [PATCH] Apply upstream PR 2808 Exclude dev/watchdog* from recovery system Resolves: rhbz2111049 --- rear-bz2111049.patch | 37 +++++++++++++++++++++++++++++++++++++ rear.spec | 1 + 2 files changed, 38 insertions(+) create mode 100644 rear-bz2111049.patch diff --git a/rear-bz2111049.patch b/rear-bz2111049.patch new file mode 100644 index 0000000..d7e19bc --- /dev/null +++ b/rear-bz2111049.patch @@ -0,0 +1,37 @@ +commit 1447530f502305ed08149d9b2a56a51fb91af875 +Author: Johannes Meixner +Date: Wed May 25 13:51:14 2022 +0200 + + Merge pull request #2808 from rear/jsmeix-exclude-watchdog + + Exclude dev/watchdog* from the ReaR recovery system: + In default.conf add dev/watchdog* to COPY_AS_IS_EXCLUDE + because watchdog functionality is not wanted in the recovery system + because we do not want any automated reboot functionality + while disaster recovery happens via "rear recover", + see https://github.com/rear/rear/pull/2808 + Furthermore having a copy of dev/watchdog* + during "rear mkrescue" in ReaR's build area + may even trigger a system crash that is caused by a + buggy TrendMicro ds_am module touching dev/watchdog + in ReaR's build area (/var/tmp/rear.XXX/rootfs), + see https://github.com/rear/rear/issues/2798 + +diff --git a/usr/share/rear/conf/default.conf b/usr/share/rear/conf/default.conf +index 881a0af0..cb14da8b 100644 +--- a/usr/share/rear/conf/default.conf ++++ b/usr/share/rear/conf/default.conf +@@ -1414,7 +1414,12 @@ COPY_AS_IS=( $SHARE_DIR $VAR_DIR ) + # We let them being recreated by device mapper in the recovery system during the recovery process. + # Copying them into the recovery system would let "rear recover" avoid the migration process. + # See https://github.com/rear/rear/pull/1393 for details. +-COPY_AS_IS_EXCLUDE=( $VAR_DIR/output/\* dev/.udev dev/shm dev/shm/\* dev/oracleasm dev/mapper ) ++# /dev/watchdog /dev/watchdog\* functionality is not wanted in the ReaR rescue/recovery system ++# because we do not want any automated reboot while disaster recovery happens via "rear recover". ++# Furthermore having dev/watchdog* during "rear mkrescue" may even trigger a system "crash" that is ++# caused by TrendMicro ds_am module touching dev/watchdog in ReaR's build area (/var/tmp/rear.XXX/rootfs). ++# See https://github.com/rear/rear/issues/2798 ++COPY_AS_IS_EXCLUDE=( $VAR_DIR/output/\* dev/.udev dev/shm dev/shm/\* dev/oracleasm dev/mapper dev/watchdog\* ) + # Array of user names that are trusted owners of files where RequiredSharedObjects calls ldd (cf. COPY_AS_IS) + # and where a ldd test is run inside the recovery system that tests all binaries for 'not found' libraries. + # The default is 'root' plus those standard system users that have a 'bin' or 'sbin' or 'root' home directory diff --git a/rear.spec b/rear.spec index cafc2ed..ae23bb5 100644 --- a/rear.spec +++ b/rear.spec @@ -30,6 +30,7 @@ Patch39: rear-pr2675.patch Patch40: rear-bz2048454.patch Patch41: rear-bz2035939.patch Patch42: rear-bz2083272.patch +Patch43: rear-bz2111049.patch # rear contains only bash scripts plus documentation so that on first glance it could be "BuildArch: noarch" # but actually it is not "noarch" because it only works on those architectures that are explicitly supported.