From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1HzCFL-0004QU-6z for mharc-grub-devel@gnu.org; Fri, 15 Jun 2007 09:53:51 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1HzCFG-0004OM-VO for grub-devel@gnu.org; Fri, 15 Jun 2007 09:53:47 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1HzCFF-0004NC-5Q for grub-devel@gnu.org; Fri, 15 Jun 2007 09:53:45 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HzCFF-0004N7-2h for grub-devel@gnu.org; Fri, 15 Jun 2007 09:53:45 -0400 Received: from relay.udl.es ([193.144.10.29] helo=relay3.udl.es) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1HzCFE-0001PK-6L for grub-devel@gnu.org; Fri, 15 Jun 2007 09:53:44 -0400 Received: from jupiter.udl.net (jupiter.udl.net [172.16.2.2]) by relay3.udl.es (8.13.7/8.13.7) with ESMTP id l5FDrI2l031340 for ; Fri, 15 Jun 2007 15:53:29 +0200 Received: from [172.16.51.43] (PL-CAP043.udl.net [172.16.51.43]) by jupiter.udl.net (8.11.7p1+Sun/8.11.6) with ESMTP id l5FDlnq17381 for ; Fri, 15 Jun 2007 15:47:49 +0200 (MET DST) Message-ID: <46728A2B.1080103@raulete.net> Date: Fri, 15 Jun 2007 14:46:35 +0200 From: adrian15 User-Agent: Thunderbird 1.5.0.8 (X11/20061107) MIME-Version: 1.0 To: The development of GRUB 2 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-3.0 (relay3.udl.es [10.69.4.19]); Fri, 15 Jun 2007 15:53:29 +0200 (CEST) X-Virus-Scanned: ClamAV 0.88.7/3426/Fri Jun 15 14:02:54 2007 on relay3.udl.es X-Virus-Status: Clean X-detected-kernel: Linux 2.6 (newer, 2) Subject: Detection of boot devices by a linux kernel X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GRUB 2 List-Id: The development of GRUB 2 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 15 Jun 2007 13:53:47 -0000 First question: ================= Once a Kernel has booted can request the bios the different boot devices and try to open them with a bios-disk driver or whatever the name is? Current problems: ==================== I do not know what's the live cd / non-live cd installer algorithm for detecting which grub device corresponds to which linux device. There's a man in hardwareguys.com which gets some strange results. He installing Linux in his 4th drive and as long as it is detected as /dev/sdg then the linux assign it: hd6 . :) http://forums.hardwareguys.com/ikonboard.cgi?act=ST;f=21;t=5731;&#top Probable solution: ===================== If the answer for the first question is that NO here there is my solution to problem. We should make a command that iterates all the hard disks boot devices and looks for the uuid from the hard disks. Once it has done so it saves the result into a variable. Then we can boot a kernel and pass this variable as a parametrer. Example: ========== grub> set prefix=(cd)/boot/grub/ root=(cd) grub> detectboot -s biosdevices grub> set root=(cd) biosdevices=hd0|ffkei|hd1|ereok|hd2|er455 grub> linux /boot/knoppix-6.0-kernel root=/dev/ram grubdevices=$biosdevices grub> initrd /boot/knoppix-6.0-initrd grub> boot Then thanks to the "grubdevices=hd0|ffkei|hd1|ereok|hd2|er455" string found in /proc/cmdline the knoppix boot scripts can check the uuid for each detected hard disk and generate a valid devices.map file. Any comments on this? adrian15