help needed to boot from compact flash

From: Everett X. Wang (everteq_at_sbcglobal.net)
Date: 01/24/05

  • Next message: Michael Schnell: "Re: Memory mapped hardware registers"
    Date: Mon, 24 Jan 2005 05:32:55 GMT
    
    

    Hi All,

    I have trying to move my linux from harddrive to a compact flash without
    much success for a week. Here is what I am trying to do:

    I already have my own kernel and modules, tested successfully on my computer
    on hard drive. I followed
    the three article series from Bruce Perens here to make busybox and file
    system:

    part 1 for busybox
    http://www.linuxdevices.com/articles/AT6143283999.html

    part 2 for file system,
    http://linuxdevices.com/articles/AT9416075241.html
    I used Ram disk intead of romfs described in book by Karim Yaghmour
    "Building embedded Linux systems"

    The compact flash is connect to an IDE to CF, set to the master of the
    second channel.

    Then I used grub to load my kernel and initrd. by running /sbin/grub
    root (hd2,0)
    setup (hd2,0)

    When it boots, it gives me a grub prompt
    I typed

    kernel /boot/bzImage
    initrd /boot/initrd.bin
    boot

    where the initrd.bin is a compressed Ram disk image from the whole rootfs.

    Then I got this message
    ....
    VFS: Mounted root (ext2 filesystems).
    kmod: failed to exec /sbin/modeprobe -s -k block-major-3 errrno=2
    VFS: Cann't open root device "" or 03:07
    Please append a correct "root=" boot option
    kernel panic: VFS: Unable to mount root fs on 03:07

    I also tried to copy the filesystem directly to the flash and reboot
    it also gives me a grub prompt
    do the same for the kernel and initrd (I used the real initrd.img from
    mkinitrd this time)
    I got this message:
    hda hda1 hda1 hda3 (these are OK because I have three partitions on the
    compact flash)
    hda7 bad access block 3 count 2
    end-request I/O error dev 03:07 (hda) sector 2
    unable to read superblock
    ...
    I never have anything like hda7. It has only 3 partitions.

    Can any one help me here? Do I have to compile all the modules into the
    kernel or keep them as modules as I am doing it now?

    Thanks in advance.

    Everett


  • Next message: Michael Schnell: "Re: Memory mapped hardware registers"

    Relevant Pages

    • help needed to boot from compact flash
      ... I have trying to move my linux from harddrive to a compact flash without ... much success for a week. ... Then I used grub to load my kernel and initrd. ... VFS: Mounted root. ...
      (comp.arch.embedded)
    • Re: help needed to boot from compact flash
      ... Everett X. Wang wrote: ... > I have trying to move my linux from harddrive to a compact flash ... > much success for a week. ... > I already have my own kernel and modules, ...
      (comp.arch.embedded)
    • Re: help needed to boot from compact flash
      ... Everett X. Wang wrote: ... > I have trying to move my linux from harddrive to a compact flash ... > much success for a week. ... > I already have my own kernel and modules, ...
      (comp.os.linux.embedded)
    • Re: Etch on USB-HD wont boot - race condition?
      ... notebook but the kernel cannot find the root filesystem. ... I had an initial problem that I think I got solved: On boot, ... Begin: Mounting root file system... ... SCSI device sda: 78140159 512-byte hdwr sectors ...
      (Debian-User)
    • Re: Flaws in recent Linux kernels
      ... Many distributions include other programs which may be ... suitable for exploiting the kernel vulnerability. ... possible to install third-party SUID root programs which may be used. ... A new revision of the Openwall Linux kernel patch, 2.2.19-ow3, is now ...
      (Bugtraq)