Skip to Content.
Sympa Menu

baslinux - Re: [BL] Loop BL3 uses a RAMDISK ?

baslinux AT lists.ibiblio.org

Subject: Baslinux mailing list

List archive

Chronological Thread  
  • From: sindi keesan <keesan AT sdf.lonestar.org>
  • To: baslinux AT lists.ibiblio.org
  • Subject: Re: [BL] Loop BL3 uses a RAMDISK ?
  • Date: Tue, 11 Jan 2005 22:49:35 +0000 (UTC)

On Wed, 12 Jan 2005 3aoo-cvfd AT dea.spamcon.org wrote:

sindi keesan wrote:

Yes, the loop version of BL3 has a small ramdisk
(to anchor the loop file). IIRC it is less than 100kb.

My partner wants to know more about this ramdisk.

In order to use a loop file as the root filesystem,
you must first mount the partition where the loop
file resides. fs.img (the BL3 loop file) resides
in the baslin directory on a DOS partition. So
you need to mount the DOS partition and then mount
/baslin/fs.img. This is done by a tiny filesystem
running in a ramdisk.

Have a look at boot.bat
--------------------------------------------------
loadlin zimage root=/dev/loop0 initrd=initfs.gz rw
--------------------------------------------------
It tells the kernel to unzip initfs.gz to a ramdisk

Where does it say to use a ramdisk? In bl2 root=/dev/ram0
The ramdisk is mounted on /initrd ?

and run it. initfs is a small filesystem (containing
a shell and a few necessary utilities/devices). It
automatically runs a script to mount the loop file
at /dev/loop0. The kernel then uses it as the root
filesystem (root=/dev/loop0).

/initrd/linuxrc = 16K bin =609 bytes

Once the kernel is running on /dev/loop, the shell/
devices/utilities in initfs are redundant. However,
it is not possible to un-mount the ramdisk. The
ramdisk still contains the mountpoint for the DOS
partition. You can't kill the ramdisk without killing
access to fs.img

Would it save a tiny bit of memory to delete linuxrc and everything esle besides /DOS from ramdisk? I think you said linux could use memory from empty parts of a ramdisk.


can he look at it?

Yes, the ramdisk is still mounted (at /initrd). You
will find the executables in /initrd/bin and the devices
in /initrd/dev. The script for mounting /dev/loop is
/initrd/linuxrc.

Cheers,
Steven

____________________________
http://www.basiclinux.com.ru
_______________________________________________
BasLinux mailing list
BasLinux AT lists.ibiblio.org
http://lists.ibiblio.org/mailman/listinfo/baslinux


keesan AT sdf.lonestar.org
SDF Public Access UNIX System - http://sdf.lonestar.org




Archive powered by MHonArc 2.6.24.

Top of Page