On Wed Oct 18, 2000 at 08:14:49AM -0800, Richard Jennings wrote:
> Hi
>
> I'm trying to make a boot floppy using busybox and ash. The goal is
> to have a single floppy that will boot up into a shell where I can
> execute a few commands, fdisk, mke2fs, mount, etc... I have all the
> components trimmed down to fit on a single floppy.
Busybox has a little internal shell that can do this. If you just
need a command line just using busybox is enough. If you need Bourne
shell scripting, then ash is the right choice (for now).
> I have a kernel
> with the few modules that I need compiled in. I am using LILO as the
> bootloader. /etc/lilo.conf has the lines :
>
> boot = /dev/fd0
>
> image=/bzImage
> root=/dev/fd0
> append="init=/bin/sh"
>
> The system boots fine but then I'm prompted for a root disk. When I
> hit return the system fails with a kernel panic can't find init. Even
> though I have init compiled into busybox.
>
> I've tried using rdev to set the ramdisk word to 0 and set the root
> device to /dev/fd0. This still does not solve the problem.
>
> I made an initrd with roughly the same results.
I believe the way you are doing things here, you have described a system for
two floppies -- one for your kernel and one for your root fs. But you
are only using 1 floppy...
> Has anyone successfully made a single floppy system like this? If so,
> how? Do you have a floppy image you are willing to share?
I do it all the time, though I find using syslinux much easier for working
with floppy disks. To do this, first (assuming you have mtools installed)
run
mformat A:
the run
syslinux /dev/fd0
Then mount the floppy
mount /dev/fd0 /mnt -t msdos
And copy onto it the file syslinux.cfg with something like:
timeout 30
default linux
prompt 1
label linux
kernel linux
append initrd=initrd.gz initrd_archive=minix boot=/dev/fd0,msdos
Then copy your kernel and initrd onto the floppy
cp /boot/kernel-2.2.17 /mnt/linux
cp ~/initrd.gz /mnt
unmount and you are ready to go,
-Erik
--
Erik B. Andersen email: [EMAIL PROTECTED]
--This message was written using 73% post-consumer electrons--
--
To unsubscribe from this list, send a message to [EMAIL PROTECTED]
with the command "unsubscribe linux-embedded" in the message body.
For more information, see <http://waste.org/mail/linux-embedded>.