newbie needs help puting linux on compactflash

Do you have a question? Post it now! No Registration Necessary

Translate This Thread From English to

Threaded View
Hi All,

I am trying to put Linux 2.4.24 to compact flash. I checked a few sites on
the web and still have difficult booting from 256M of Sandisk compact flash
on an IDE controller.

Here is my setup:

host: P4 with Redhat 9 installed. All kernel development software is
installed. I was trying to use an USB from SanDisk to write file to the
256Mb flash.

target: P3 900Mhz from TME-Inc. with compactflash socket (type II) on
primary IDE slave, 512MB SDRAM, USBs, ethernet, dual channel IDE, integrated
video. etc.

I was trying to follow this page but failed:
http://www.flutterby.com/wiki/CompactFlash%20Linux%20Install%20for%20Embedded%20Applications

and this one too:
http://www.linuxjournal.com/article.php?sid45%51

when I try to install lilo.

Is that simple and straightway to put linux on the bootable flash so my
PC104 p3 can boot?

Thanks.

Everett



Re: newbie needs help puting linux on compactflash

Quoted text here. Click to load it

*How* did it fail?

Quoted text here. Click to load it

It is...*if* you get it right.  There are several ways to get
it wrong though, especially if the target system boots off of
a different device number than the build system.  (See the
"bios" setting of LILO for that.)

--kyler

Re: newbie needs help puting linux on compactflash
Hi,

It failed at lilo:

I can mount the compactflash. It showes up as a SCSI:
mount -t ext2 /dev/sdb1 /mnt/cf

I can make directory under cf, copy files to it.

But when I do this, it failed

/sbin/lilo -v 3 -r /mnt/cf -C etc/lilo.conf

lilo report that it can't find /dev/sdb

Originally, I thought that the lilo.conf has a problem. But it failed even
for this
/sbin/lilo -v 3 -r /mnt/cf, which uses default lilo in /etc
with the same message.
A friend ask me to try "chroot" to /mnt/cf. It also failed, even though I
mount the flash and
can create directory and files in /mnt/cf.

Any idea about this?

Everett


Quoted text here. Click to load it



Re: newbie needs help puting linux on compactflash
On Tue, 17 Feb 2004 00:10:51 GMT, "Everett X. Wang"
I did it this way:
Hope this helps:

Creating my filesystem as NFS. Mount my compact flash in /mnt and copy
the NFS contents into /mnt. After that "chroot" to /mnt.  Then I have a
/boot and /etc directory with lilo.conf in /etc. Because I am using
devfs I have to mount /dev again and not to forget /proc. Then "lilo -v"
does the right thing. No trouble. My lilo.conf looks like this:
(My compact flash is connectetd like an IDE device)

boot=/dev/ide/host0/bus0/target0/lun0/disc
lba32
menu-title="Bootmenue CAR-PC"
prompt
timeout20%
vga78%5

image=/boot/linux
        label=hd_linux
        root=/dev/ide/host0/bus0/target0/lun0/part1
        append="hdb=none ide1=noprobe ...."

image=/boot/nfs_linux
        label=nfs_linux
        append="root=/dev/nfs ....."

JB
--
Juergen Beisert        email: jbeisert _AT_ eurodsn _DOT_ de
EuroDesign embedded technologies GmbH  http://www.eurodsn.de

Re: newbie needs help puting linux on compactflash
snipped-for-privacy@netscape.net (Juergen Beisert) writes:

Quoted text here. Click to load it

Don't forget simple things like installing an MBR and setting the
boot partition boot flag.

--kyler

Re: newbie needs help puting linux on compactflash
Thanks for you information. I am trying to follow exmaples here. But I don't
know how to creat NFS file system. Can you showed me how to do that?

I have a redhat 9 installed on my desktop computer and I know how to compile
a kernel for the embedded PC. I also have a USB flash reader connected to
the desktop PC which linux supports it. The embedded PC is a PC104 P3 with
an IDE flash connector.

Thanks a lot.

Everett

Quoted text here. Click to load it



Re: newbie needs help puting linux on compactflash
Quoted text here. Click to load it

That requires a NFS server on the network.  It you don't have one, it would
be easier to dump an raw CF boot image directly.

Quoted text here. Click to load it

Can you connect the flash drive to you desktop PC?
If so, just rawwrite a bootable image to the flash drive.  

Quoted text here. Click to load it

Site Timeline