How reliable is jffs2 really (denx cvs devel kernel)?

Wolfgang Denk wd at denx.de
Wed Jul 20 18:37:32 EST 2005


In message <200507200830.27141.david.jander at protonic.nl> you wrote:
> 
> I already thought it might be a good idea to subscribe to that list.
> Any hint about how I can figure out exactly which version of MTD code I have?

I already answered this in my previous message: it's a snapshot  from
MTD CVS of March 13, 2005, backported to the 2.4 kernel.

In general, you can find this type of information when  checking  the
CVS  history.  That's  why  we  run a CVS server and not only provide
tarballs.

> The version of linuxppc_2_4_devel I have is about 2 months old, do I have to 
> expect important changes concerning MTD since then?

More changes have been made since, of course, but I'm  not  aware  of
anything that might be relevant to your problem.

> need to log data into flash. Right now I use an oversized jffs2 partition, 
> log via syslogd and logrotate on size. I am getting the impression that this 

This is about the worst case use for JFFS2 - always  appending  small
chunks (sinlge lines of text) to an ever growing file is exactly what
the filesystem was NOT designed for.

> is not workable for mission critical things. At least not with the kernel and 
> MTD code I have. Others must have the same problem, so here's my question: 
> Which way to do such a thing? Write my own filesystem?

No. Don't reinvent the wheel. Use a buffer are with  unlimited  write
cycles  (like  SRAM  or FRAM), or even a reserved area of your system
RAM, and use pramfs on it. If  you're  using  U-Boot,  you  can  even
arrange that such a file system survives warm boots. Then establish a
policy  for writing the data from this buffer area to flash (probably
still using JFFS2) at a much lower rate. Avoid append  mode.  Try  to
write files in a single operation. etc.

Best regards,

Wolfgang Denk

-- 
Software Engineering:  Embedded and Realtime Systems,  Embedded Linux
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
"Summit meetings tend to be like panda matings. The expectations  are
always high, and the results usually disappointing."   - Robert Orben



More information about the Linuxppc-embedded mailing list