[debian-edu-commits] debian-edu/ 02/02: Tell grub in our pre-pkgsel script to use the disk device used by /boot, to work around bug #712907.
Petter Reinholdtsen
pere at moszumanska.debian.org
Fri Oct 24 10:00:07 UTC 2014
This is an automated email from the git hooks/post-receive script.
pere pushed a commit to branch master
in repository debian-edu-config.
commit d5dd119827c56ab59f9c37643a61ae938319cec5
Author: Petter Reinholdtsen <pere at hungry.com>
Date: Fri Oct 24 12:00:03 2014 +0200
Tell grub in our pre-pkgsel script to use the disk device used by /boot, to work around bug #712907.
---
debian/changelog | 2 ++
share/debian-edu-config/d-i/pre-pkgsel | 15 +++++++++++++++
2 files changed, 17 insertions(+)
diff --git a/debian/changelog b/debian/changelog
index 54b31f4..2629aa0 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -18,6 +18,8 @@ debian-edu-config (1.813) UNRELEASED; urgency=low
around bug #765577. This avoid complete network failure on
machines affected by this bug.
* Remove unused variable RUNXSERVER from the pre-pkgsel script.
+ * Tell grub in our pre-pkgsel script to use the disk device used by
+ /boot, to work around bug #712907.
-- Petter Reinholdtsen <pere at debian.org> Thu, 23 Oct 2014 10:35:10 +0200
diff --git a/share/debian-edu-config/d-i/pre-pkgsel b/share/debian-edu-config/d-i/pre-pkgsel
index 839ef22..d1d9255 100644
--- a/share/debian-edu-config/d-i/pre-pkgsel
+++ b/share/debian-edu-config/d-i/pre-pkgsel
@@ -304,6 +304,21 @@ create_initial_localadmin_user() {
fi
}
+# Work around grub bug 712907 (see also bug #763580) by preseeding
+# grub-installer/choose_device to the disk used by /target/boot
+# This fix it for the most common case.
+workaround_grub_issue() {
+ bootdev=$(grep /target/boot /proc/mounts | cut -d" " -f1)
+ case "$bootdev" in
+ /dev/sd*)
+ grubdev=$(echo bootdev | sed -rn 's/(\/sd.).*$/\1/p')
+ db_set grub-installer/choose_bootdev "$grubdev" || true
+ ;;
+ esac
+}
+
+workaround_grub_issue
+
db_get debian-edu-install/profile
PROFILE="$RET"
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-edu/debian-edu-config.git
More information about the debian-edu-commits
mailing list