Use mv not cp to try to avoid moving disk blocks around for -5 fix

Related: rhbz#735259
handle initramfs on xen better (patch from Marko Ristola)
Resolves: rhbz#728775
This commit is contained in:
Peter Jones 2011-09-14 16:08:42 -04:00
parent eb5089f407
commit 1156d47d8e
2 changed files with 25 additions and 2 deletions

View File

@ -0,0 +1,16 @@
From: Marko Ristola <marko.ristola@kolumbus.fi>
Date: 2011-08-07 07:43:01 EDT
Subject: [PATCH] Xen also uses initramfs not initrd filename
diff --git a/util/grub.d/20_linux_xen.in b/util/grub.d/20_linux_xen.in
--- a/util/grub.d/20_linux_xen.in 2011-05-17 17:10:29 +0000
+++ b/util/grub.d/20_linux_xen.in 2011-09-14 19:02:23 +0000
@@ -154,6 +154,7 @@
for i in "initrd.img-${version}" "initrd-${version}.img" \
"initrd-${version}" "initrd.img-${alt_version}" \
"initrd-${alt_version}.img" "initrd-${alt_version}" \
+ "initramfs-${version}.img" "initramfs-${alt_version}" \
"initramfs-genkernel-${version}" \
"initramfs-genkernel-${alt_version}" ; do
if test -e "${dirname}/${i}" ; then

View File

@ -18,7 +18,7 @@
Name: grub2
Epoch: 1
Version: 1.99
Release: 5%{?dist}
Release: 6%{?dist}
Summary: Bootloader with support for Linux, Multiboot and more
Group: System Environment/Base
@ -32,6 +32,7 @@ Patch0: grub-1.99-handle-fwrite-return.patch
Patch1: grub-1.99-grub_test_assert_printf.patch
Patch2: grub-1.99-just-say-linux.patch
Patch3: grub-1.99-Workaround-for-variable-set-but-not-used-issue.patch
Patch4: grub2-handle-initramfs-on-xen.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@ -229,7 +230,7 @@ fi
%triggerun -- grub2 < 1:1.99-4
# Back up the files before uninstalling old grub2
mkdir -p /boot/grub2.tmp &&
cp -a /boot/grub2/*.mod \
mv -f /boot/grub2/*.mod \
/boot/grub2/*.img \
/boot/grub2/*.lst \
/boot/grub2/device.map \
@ -352,6 +353,12 @@ fi
%endif
%changelog
* Wed Sep 14 2011 Peter Jones <pjones@redhat.com> - 1.99-6
- Use mv not cp to try to avoid moving disk blocks around for -5 fix
Related: rhbz#735259
- handle initramfs on xen better (patch from Marko Ristola)
Resolves: rhbz#728775
* Sat Sep 03 2011 Kalev Lember <kalevlember@gmail.com> - 1.99-5
- Fix upgrades from grub2 < 1.99-4 (#735259)