Re: [uCsimm] Creating Ram FS

From: Greg Ungerer (
Date: Fri Jun 30 2000 - 07:12:59 EDT

SZ wrote:
> Say, how can we config the size and characteristic from the ramfs.img?

>From the uClinux/ColdFire developments page at

(Note that the source references are to the uClinux/ColdFire package,
it should be similar to locations in the uC-src package).

10. Creating new RAM disk images?

You can create your RAM disks, of any size (given RAM limits). Follow
the directions for creating a RAM disk from the
kernel documentation, should be /usr/src/linux/Documentation/ramdisk.txt
on your host Linux system. Once you have a raw
image you need to run a simple compressor over it... Do the following:

    cd user/ramimage
    gcc -O -o holes holes.c
    ./holes ramdisk-image > ../../romfs/etc/ramfs.img

Where ramdisk-image is the image file that you generated above.

I would suggest also doing a tune2fs on the file-system, and setting the
interval-between-checks to 0, so that you don't get
any annoying "should fsck this file-system" messages when it is mounted.

You may also want to think carefully about how many files you think you
may want to create in that file-system. Adjust the
number of inodes accordingly.

There is some samples of size 64k, 128k, 256k, 512k, 1024k and 2048k in
the user/ramimage directory...

Greg Ungerer EMAIL:
Moreton Bay (A Lineo Company) PHONE: +61 7 3279 1822
Unit 12, 97 Jijaws St, FAX: +61 7 3279 1820
Sumner Park, QLD, 4074, Australia WEB:
This message resent by the list server

This archive was generated by hypermail 2b30 : Sun Apr 07 2002 - 00:01:37 EST