To run a system from CDROM w/o using any HD, ramdisk is essential.
A limitation that exists in loading the initial ramdisk is how
much data can be comrpessed into the boot image, which on Intel
PC devices with El Torito is limited to a 2.88 MB floppy image.
To get past this limitation, my first thought is to have the
initial ramdisk bring in a program run as /linuxrc which then
reads a larger image from a file on the CDROM into yet another
ramdisk which will then be remounted as root by the kernel.
An issue I am running into is which ramdisk to use. I cannot
use /dev/ram0 (1,0) because initrd uses that one, and it is
already mounted. Overwriting it would have * consequences.
So I will use a 2nd ramdisk. Now the issue is which one. Should
I use /dev/ram1? Maybe programs on a running system expect to
take the next ramdisk past one that might be used by initrd. Or
should I use /dev/ram15? Similarly, programs might grab ramdisks
from the top down. I'd really prefer to let whoever uses this
make that decision. But the obvious place, where one puts a
root=/dev/ram1 on the kernel argument string won't work because
the hard coded device names in init/main.c don't have any more
ramdisks besides just /dev/ram (I notice a similar limitation in
choice of SCSI CDROM devices).
The only thing I can see is to require users to rebuild the initrd
image that all this starts from and include a special file pointing
specifically to the same device that the kernel will mount (which
would have to know it strictly by major,minor to get to a ramdisk
other than the first one).
Any comments on making it easier for users? I don't want to require
them to recompile everything to change something like which ramdisk.
Is it possible for /linuxrc to unmount / (after 2 ramdisks are open)
and mount / again as the 2nd ramdisk? If that is possible, then I
could copy the initrd to the 2nd ramdisk and rebuild the 1st one to
be what will become the real device to mount root. But alas, the
mapping of /linuxrc for the running process would block unmounting
the / filesystem. OK, maybe switching executeables. But even then
something is mapped from a filesystem mounted over / anyway. How to
have no filesystems mounted and have a process running ... doubtful.
| Phil Howard - KA9WGN | My current websites: linuxhomepage.com, ham.org
| phil (at) ipal.net +----------------------------------------------------