Re: [uCsimm] Implementing updateable ramdisk

From: Greg Ungerer (
Date: Wed May 09 2001 - 03:32:46 EDT

Hi Ashwin,

Ashwin wrote:
> I have a problem. Some of my applications need to store some
> intialisation variables in files these variables can be updated i.e any
> changes made to them should be reflected the next time the system boots.
> How do I go about doing it?
> I have thought of a scheme where in I seperate the ramdisk.img from the
> romdisk directory and keep it seperately in flash say after ramdisk as a
> different partition.So when my system boots I expand the ramdisk partiton
> in ram and mount it.Now when I need to update the ramdisk I give a command
> which makes new a ramfs and compress it and write it back to the flash.
> How is the scheme does anybody have a different sugestion?
> The next problem would be knowing where to write the new image and how to
> write it.
> I found a utiltiy in the userland directory named flashwrite there is no
> documentation of the same can I use it for writing purpose?

I wrote a daemon that pretty much does exactly what you describe,
called flatfsd. It is distributed with the uCLinux/ColdFire

It "archives" a small RAM filesystem to a /dev/romX device.
It will also recreate the RAM disk at boot time. Currently
you send it a SIGUSR to tell it to save away the contents of
the RAM disk to FLASH. Others have modified the sash shell
built in "sync" command to do this too.


Greg Ungerer -- Chief Software Wizard EMAIL:
Lineo (Integrated Products Group) PHONE: +61 7 3435 2888
825 Stanley St, FAX: +61 7 3891 3630
Woolloongabba, QLD, 4102, Australia WEB:
This message resent by the list server

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