On Fri, 2007-06-22 at 05:41 -0500, Dallas Clement wrote: > Can anyone tell me how to determine which device Linux booted from. I > am using GRUB to boot Linux. My menu.lst config is this: > > title GNU/Linux, kernel 2.6.21.1 > root (hd0,0) > kernel /boot/kernels/bzImage > > Once booted from Linux, I would like to be able to tell which Linux > device, i.e. /dev/hdx or /dev/sdx corresponds to hd0. > > Is there a way to determine this? > > Thanks!
For the benefit of anyone who cares, I found the answer to my problem. It has been solved by some engineers over at Dell. They created a project called Enhanced Disk Drive services a.k.a EDD, which has been incorporated into the 2.6 Linux kernel as the CONFIG_EDD option. It worked marvelously for me. You have to load the edd.ko module for it to work. It will then collect the BIOS drive info into the /sys/firmware/edd folder. The info concerning the boot device is found in the int13_dev80 folder. You can simply compare the cylinders with the output of "fdisk -l" to determine the Linux partition name of your boot device. Regards, Dallas _______________________________________________ Bug-grub mailing list Bug-grub@gnu.org http://lists.gnu.org/mailman/listinfo/bug-grub