Accepting request 658953 from home:jdelvare:branches:Base:System

dracut-installkernel: Stop keeping old kernel files as .old (boo#1112327)

OBS-URL: https://build.opensuse.org/request/show/658953
OBS-URL: https://build.opensuse.org/package/show/Base:System/dracut?expand=0&rev=359
This commit is contained in:
Marcus Meissner 2019-01-14 09:53:59 +00:00 committed by Git OBS Bridge
parent 7cd6b4c8bb
commit ee3452de15
2 changed files with 18 additions and 43 deletions

View File

@ -4,11 +4,8 @@
#
# May 21, 2003 - agruen@suse.de
# * Adapted for SuSE and cleaned up.
#
# This file is kept in the following CVS repository:
#
# $Source: /suse/yast2/cvsroot/mkinitrd/installkernel,v $
# $Revision: 1.8 $
# November 21, 2018 - jdelvare@suse.de
# * Stop creating .old files.
#
: ${INSTALL_PATH:=/boot}
@ -35,40 +32,6 @@ case "$(uname -m)" in
;;
esac
#
# Move away files from versions up to SuSE Linux 8.2
#
if [ -f $INSTALL_PATH/$BOOTFILE -a ! -L $INSTALL_PATH/$BOOTFILE ]; then
mv $INSTALL_PATH/$BOOTFILE $INSTALL_PATH/$BOOTFILE.old
fi
if [ -L $INSTALL_PATH/System.map ]; then
rm -f $INSTALL_PATH/System.map
elif [ -f $INSTALLPATH/System.map ]; then
mv $INSTALL_PATH/System.map $INSTALL_PATH/System.map.old
fi
#
# Move away files from after SuSE Linux 8.2
#
if [ -f $INSTALL_PATH/$BOOTFILE-$KERNEL_VERSION ]; then
mv $INSTALL_PATH/$BOOTFILE-$KERNEL_VERSION \
$INSTALL_PATH/$BOOTFILE-$KERNEL_VERSION.old;
fi
if [ -f $INSTALL_PATH/System.map-$KERNEL_VERSION ]; then
mv $INSTALL_PATH/System.map-$KERNEL_VERSION \
$INSTALL_PATH/System.map-$KERNEL_VERSION.old;
fi
if [ -f .config ] && [ -f $INSTALL_PATH/$CONFIGFILE ]; then
mv -v $INSTALL_PATH/$CONFIGFILE \
$INSTALL_PATH/$CONFIGFILE.old;
fi
#
# Install new files
#
@ -121,10 +84,6 @@ case "$(uname -m)" in
i?86 | x86_64)
KERNBIN=$(dirname $MAPFILE)/vmlinux
if [ -e $KERNBIN ]; then
if [ -f $INSTALL_PATH/vmlinux-$KERNEL_VERSION.gz ]; then
mv $INSTALL_PATH/vmlinux-$KERNEL_VERSION.gz \
$INSTALL_PATH/vmlinux-$KERNEL_VERSION.gz.old;
fi
gzip -c $KERNBIN > $INSTALL_PATH/vmlinux-$KERNEL_VERSION.gz
fi
;;

View File

@ -4,6 +4,22 @@ Fri Dec 21 11:02:32 UTC 2018 - Michal Suchanek <msuchanek@suse.com>
- 95zfcp_rules/parse-zfcp.sh: remove rule existence check (bsc#1008352).
* adds 0585-95zfcp_rules-parse-zfcp.sh-remove-rule-existence-check.patch
-------------------------------------------------------------------
Mon Dec 17 15:27:15 UTC 2018 - jdelvare@suse.com
- dracut-installkernel: Stop keeping old kernel files as .old
(boo#1112327)
The .old kernel files are confusing grub2 which can't find a
matching directory under /lib/modules. Furthermore, there is no
guarantee that the new modules are fully compatible with the old
kernel.
If anything goes wrong with a new self-compiled kernel, the user
can always boot back to the distribution kernel, so the .old
backup files are not needed in the first place. Get rid of them
to simplify and speed up the whole process.
-------------------------------------------------------------------
Wed Oct 31 09:57:55 UTC 2018 - Daniel Molkentin <daniel.molkentin@suse.com>