I am trying to install Grub on a Sandisk 16Mb CompactFlash card using an IDE adapter. When I try and boot from the CF Card I get the following error.
Verifying DMI Pool Data........ GRUB Loading stage2Read Error Can anybody help me shed some light on how to resolve the problem? The history of how I set up the card is outlined below. Apologies for the length of the email. I really would be grateful for any help or pointers. Thanks in advance Grant Forrester System: Via ITX ME6000 mainboard OS: Redhat 7.3 Primary Master: Excelstor 20Gb HDD Secondary Master: Sandisk SDCFB-16 + IDE Adpator BIOS ---- Inspection of the BIOS reveals the CF card has been correctly identified as the master device on the seconday ide channel. The properties for the card are given as: size: 16Mb Cylinders: 490 Heads: 2 Sectors: 32 FDISK (v2.11n) ----- On booting the full Redhat installation on my main HDD (/dev/hda) I can inspect and set the partition table on the CF card (/dev/hdc) using fdisk as follows: $ fdisk /dev/hdc Disk /dev/hdc: 2 heads, 32 sectors, 490 cylinders Units = cylinders of 64 * 512 bytes Device Boot Start End Blocks Id System /dev/hdc1 * 1 490 15664 83 Linux MKE2FS (v1.27) ------ The single partition on the CF card (/dev/hdc1) is then formatted as an ext2fs filesystem as follows: $ mke2fs /dev/hdc1 mke2fs 1.27 (8-Mar-2002) Filesystem label= OS type: Linux Block size=1024 (log=0) Fragment size=1024 (log=0) 3920 inodes, 15664 blocks 783 blocks (5.00%) reserved for the super user First data block=1 2 block groups 8192 blocks per group, 8192 fragments per group 1960 inodes per group Superblock backups stored on blocks: 8193 Writing inode tables: done Writing superblocks and filesystem accounting information: done This filesystem will be automatically checked every 28 mounts or 180 days, whichever comes first. Use tune2fs -c or -i to override. The filesystem can then be mounted on /mnt/flash and inspected as follows: $ mount /dev/hdc1 /mnt/flash $ ls /mnt/flash lost+found Copy GRUB and boot files ------------------------ All the files found in my Redhat /boot/grub directory are then copied to the flash folder /grub as follows: $ cp -R /boot/grub /mnt/flash $ ls -l /mnt/flash/grub -rw-r--r-- 1 root root 101 Jan 27 20:49 device.map -rw-r--r-- 1 root root 10880 Jan 27 20:49 e2fs_stage1_5 -rw-r--r-- 1 root root 9808 Jan 27 20:49 fat_stage1_5 -rw-r--r-- 1 root root 8896 Jan 27 20:49 ffs_stage1_5 -rw------- 1 root root 667 Jan 27 20:49 grub.conf -rw-r--r-- 1 root root 11104 Jan 27 20:49 jfs_stage1_5 lrwxrwxrwx 1 root root 11 Jan 27 20:49 menu.lst -> ./grub.conf -rw-r--r-- 1 root root 9280 Jan 27 20:49 minix_stage1_5 -rw-r--r-- 1 root root 12576 Jan 27 20:49 reiserfs_stage1_5 -rw-r--r-- 1 root root 33585 Jan 27 20:49 splash.xpm.gz -rw-r--r-- 1 root root 512 Jan 27 20:49 stage1 -rw-r--r-- 1 root root 131008 Jan 27 20:49 stage2 -rw-r--r-- 1 root root 8544 Jan 27 20:49 vstafs_stage1_5 -rw-r--r-- 1 root root 12744 Jan 27 20:49 xfs_stage1_5 The kernel and initrd images I require are then copied to /mnt/flash. (I have successfully booted from these images using a temporary grub boot option in my existing Redhat install /dev/hda so I know they work). $ ls -l /mnt/flash drwxr-xr-x 2 root root 1024 Jan 27 20:49 grub -rw-r--r-- 1 root root 8388608 Jan 27 20:53 ice3.img drwx------ 2 root root 12288 Jan 27 20:44 lost+found -rw-r--r-- 1 root root 1041347 Jan 27 20:53 vmlinuz-2.4.18-3 Do GRUB magic (0.91) ------------- Start the grub console and wait for the BIOS probing to end. Available devices detected are (hd0) HDD and (hd1) Sandisk CF card. The GRUB session is as follows. grub> geometry (hd1) drive 0x81: C/H/S = 490/2/32, The number of sectors = 31360, /dev/hdc Partition num: 0, Filesystem type is ext2fs, partition type 0x83 grub> root (hd1,0) Filesystem type is ext2fs, partition type 0x83 grub> setup (hd1,0) Checking if "/boot/grub/stage1" exists... no Checking if "/grub/stage1" exists... yes Checking if "/grub/stage2" exists... yes Checking if "/grub/e2fs_stage1_5" exists... yes Running "embed /grub/e2fs_stage1_5 (hd1,0)"... failed (this is not fatal) Running "embed /grub/e2fs_stage1_5 (hd1,0)"... failed (this is not fatal) Running "install /grub/stage1 d (hd1,0) /grub/stage2 p /grub/grub.conf "... succeeded Done. Reboot ------ On reboot I switched the boot order in the BIOS to start with HDD1 (ie the CF card) rather than my disk (HDD0). I get the error 'GRUB Loading stage2Read Error'. I even tried removing my existing HDD and plugging the CF card into the primary IDE channel making it HDD0. Resetting the BIOS to boot from HDD0 results in the same error message. Any help please? _______________________________________________ Bug-grub mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/bug-grub