From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1OJtut-0001q1-N2 for mharc-grub-devel@gnu.org; Wed, 02 Jun 2010 15:47:55 -0400 Received: from [140.186.70.92] (port=35194 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OJtI7-00046E-6y for grub-devel@gnu.org; Wed, 02 Jun 2010 15:07:52 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OJtI5-0005X2-H5 for grub-devel@gnu.org; Wed, 02 Jun 2010 15:07:50 -0400 Received: from cobija.connexer.com ([66.93.22.232]:46011) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OJtI5-0005WS-D3 for grub-devel@gnu.org; Wed, 02 Jun 2010 15:07:49 -0400 Received: from rangda.stickybit.se (h-234-204.A189.priv.bahnhof.se [81.170.234.204]) by cobija.connexer.com (Postfix) with ESMTPA id D631C30006 for ; Wed, 2 Jun 2010 15:07:46 -0400 (EDT) Received: by rangda.stickybit.se (Postfix, from userid 1000) id C141410533; Wed, 2 Jun 2010 21:07:44 +0200 (CEST) Date: Wed, 2 Jun 2010 21:07:44 +0200 From: sean finney To: grub-devel@gnu.org Message-ID: <20100602190744.GA4058@rangda.stickybit.se> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="UFHRwCdBEJvubb2X" Content-Disposition: inline User-Agent: Mutt/1.5.20 (2009-06-14) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 1) X-Mailman-Approved-At: Wed, 02 Jun 2010 15:47:53 -0400 Subject: [PATCH] Fix root device detection for lvm2 X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 02 Jun 2010 19:07:52 -0000 --UFHRwCdBEJvubb2X Content-Type: multipart/mixed; boundary="cmJC7u66zC7hs+87" Content-Disposition: inline --cmJC7u66zC7hs+87 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline If you have a single / filesystem on lvm2, the boot process will hang waiting for a root filesystem that never appears. This patch modifies the logic in deciding what the root device actually is, and allows the initramfs to succesfully load the root filesystem. The attached patch has been in use in the debian "grub2" packages for quite a while, so I assume it's safe to use :) --cmJC7u66zC7hs+87 Content-Type: text/x-diff; charset=us-ascii Content-Disposition: attachment; filename="01_uuids_and_lvm_dont_play_along_nicely.diff" Content-Transfer-Encoding: quoted-printable Index: b/util/grub.d/10_linux.in =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D --- a/util/grub.d/10_linux.in +++ b/util/grub.d/10_linux.in @@ -43,7 +43,8 @@ esac =20 if [ "x${GRUB_DEVICE_UUID}" =3D "x" ] || [ "x${GRUB_DISABLE_LINUX_UUID}" = =3D "xtrue" ] \ - || ! test -e "/dev/disk/by-uuid/${GRUB_DEVICE_UUID}" ; then + || ! test -e "/dev/disk/by-uuid/${GRUB_DEVICE_UUID}" \ + || [ "`grub-probe -t abstraction --device ${GRUB_DEVICE} | sed -e 's,.= *\(lvm\).*,\1,'`" =3D "lvm" ] ; then LINUX_ROOT_DEVICE=3D${GRUB_DEVICE} else LINUX_ROOT_DEVICE=3DUUID=3D${GRUB_DEVICE_UUID} --cmJC7u66zC7hs+87-- --UFHRwCdBEJvubb2X Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iD8DBQFMBqwAynjLPm522B0RArQwAJ94hwyUkcRE+INiBwNnP2yNm4vUuQCfaVxr X19oZGBpEvHEJp04tS86fK0= =GMyA -----END PGP SIGNATURE----- --UFHRwCdBEJvubb2X--