From 347c1e3296f347dd859e8fb9f178677e0b1dd523 Mon Sep 17 00:00:00 2001 From: CentOS Sources Date: Fri, 26 Aug 2022 16:15:33 +0000 Subject: [PATCH] import rear-2.6-7.el8 --- SOURCES/rear-bz2119501.patch | 39 ++++++++++++++++++++++++++++++++++++ SOURCES/rear-bz2120736.patch | 18 +++++++++++++++++ SPECS/rear.spec | 10 ++++++++- 3 files changed, 66 insertions(+), 1 deletion(-) create mode 100644 SOURCES/rear-bz2119501.patch create mode 100644 SOURCES/rear-bz2120736.patch diff --git a/SOURCES/rear-bz2119501.patch b/SOURCES/rear-bz2119501.patch new file mode 100644 index 0000000..71b4d47 --- /dev/null +++ b/SOURCES/rear-bz2119501.patch @@ -0,0 +1,39 @@ +diff --git a/usr/share/rear/build/default/490_fix_broken_links.sh b/usr/share/rear/build/default/490_fix_broken_links.sh +index 5bace664..cf960be8 100644 +--- a/usr/share/rear/build/default/490_fix_broken_links.sh ++++ b/usr/share/rear/build/default/490_fix_broken_links.sh +@@ -7,6 +7,23 @@ + # see https://github.com/rear/rear/issues/1638 + # and https://github.com/rear/rear/pull/1734 + ++# Some broken symlinks are expected. The 'build' and 'source' symlinks in kernel modules point to kernel sources ++# and are broken untol one installs the kernel-debug-devel or kernel-devel packages (on Fedora) and even then ++# the targets are jot included in the rescue system by default. ++# Do not warn about those, it is just noise. ++local irrelevant_symlinks=( '*/lib/modules/*/build' '*/lib/modules/*/source' ) ++function symlink_is_irrelevant () { ++ for i in "${irrelevant_symlinks[@]}"; do ++ # do not quote $i, it is a glob pattern, matching will be performed by [[ ... == ... ]] ++ # quoting inside [[ ]] prevents pattern matching ++ if [[ "$1" == $i ]]; then ++ return 0 ++ fi ++ done ++ return 1 ++} ++ ++ + # FIXME: The following code fails if symlinks or their targets contain characters from IFS (e.g. blanks), + # cf. the same kind of comments in build/default/990_verify_rootfs.sh + # and layout/prepare/GNU/Linux/130_include_mount_subvolumes_code.sh +@@ -38,6 +55,10 @@ pushd $ROOTFS_DIR + local broken_symlink='' + local link_target='' + for broken_symlink in $broken_symlinks ; do ++ if symlink_is_irrelevant "$broken_symlink" ; then ++ DebugPrint "Ignoring irrelevant broken symlink $broken_symlink" ++ continue ++ fi + # For each broken symlink absolute path inside ROOTFS_DIR + # we call "readlink -e" in the original system to get its link target there. + # If in the original system there was a chain of symbolic links like diff --git a/SOURCES/rear-bz2120736.patch b/SOURCES/rear-bz2120736.patch new file mode 100644 index 0000000..8bcce79 --- /dev/null +++ b/SOURCES/rear-bz2120736.patch @@ -0,0 +1,18 @@ +diff --git a/usr/share/rear/conf/default.conf b/usr/share/rear/conf/default.conf +index b14525da..23a83b71 100644 +--- a/usr/share/rear/conf/default.conf ++++ b/usr/share/rear/conf/default.conf +@@ -1841,10 +1841,10 @@ OBDR_BLOCKSIZE=2048 + # BACKUP=NBU stuff (Symantec/Veritas NetBackup) + ## + # +-COPY_AS_IS_NBU=( /usr/openv/bin/vnetd /usr/openv/bin/vopied /usr/openv/lib /usr/openv/netbackup /usr/openv/var/auth/[mn]*.txt /opt/VRTSpbx /etc/vx/VxICS /etc/vx/vrtslog.conf ) +-COPY_AS_IS_EXCLUDE_NBU=( /usr/openv/netbackup/logs "/usr/openv/netbackup/bin/bpjava*" /usr/openv/netbackup/bin/xbp /usr/openv/netbackup/bin/private /usr/openv/lib/java /usr/openv/lib/shared/vddk /usr/openv/netbackup/baremetal ) ++COPY_AS_IS_NBU=( /usr/openv/bin/vnetd /usr/openv/bin/vopied /usr/openv/lib /usr/openv/netbackup /usr/openv/var/auth/[mn]*.txt /usr/openv/var/vxss /usr/openv/var/webtruststore /usr/openv/resources/nbpxyhelper /opt/VRTSpbx /etc/vx/VxICS /etc/vx/vrtslog.conf /var/log/VRTSpbx ) ++COPY_AS_IS_EXCLUDE_NBU=( "/usr/openv/netbackup/logs/*" "/usr/openv/netbackup/bin/bpjava*" /usr/openv/netbackup/bin/xbp /usr/openv/netbackup/bin/private /usr/openv/lib/java "/usr/openv/lib/*-plugins" /usr/openv/lib/shared/vddk /usr/openv/netbackup/baremetal "/var/log/VRTSpbx/*" ) + # See https://github.com/rear/rear/issues/2105 why /usr/openv/netbackup/sec/at/lib/ is needed: +-NBU_LD_LIBRARY_PATH="/usr/openv/lib:/usr/openv/netbackup/sec/at/lib/" ++NBU_LD_LIBRARY_PATH="/usr/openv/lib:/usr/openv/netbackup/sec/at/lib/:/usr/openv/lib/boost" + PROGS_NBU=( ) + + ## diff --git a/SPECS/rear.spec b/SPECS/rear.spec index 82ed2cb..a0b586c 100644 --- a/SPECS/rear.spec +++ b/SPECS/rear.spec @@ -3,7 +3,7 @@ Summary: Relax-and-Recover is a Linux disaster recovery and system migration tool Name: rear Version: 2.6 -Release: 6%{?dist} +Release: 7%{?dist} License: GPLv3 Group: Applications/File URL: http://relax-and-recover.org/ @@ -28,6 +28,8 @@ Patch43: rear-bz2111049.patch Patch44: rear-bz2104005.patch Patch48: rear-bz2111059.patch Patch49: pxe-rsync-output.patch +Patch50: rear-bz2119501.patch +Patch51: rear-bz2120736.patch ### Dependencies on all distributions BuildRequires: asciidoc @@ -144,6 +146,8 @@ fi %patch44 -p1 %patch48 -p1 %patch49 -p1 +%patch50 -p1 +%patch51 -p1 echo "30 1 * * * root test -f /var/lib/rear/layout/disklayout.conf && /usr/sbin/rear checklayout || /usr/sbin/rear mkrescue" >rear.cron @@ -177,6 +181,10 @@ TZ=UTC %{__make} -C doc %{_sbindir}/rear %changelog +* Wed Aug 24 2022 Pavel Cahyna - 2.6-7 +- Avoid stderr message about irrelevant broken links +- Changes for NetBackup (NBU) 9.x support + * Tue Aug 9 2022 Pavel Cahyna - 2.6-6 - Restore usr/share/rear/output/PXE/default/820_copy_to_net.sh removed in 2.4-19 with rsync refactor.