File system for compact flash or SD for linux to run off of.

Michael Torrie torriem at
Wed Aug 31 17:06:35 MDT 2011

I'm trying to put together a mini server (almost an embedded system) and
I'm struggling to know what kind of file system to use.  Most of the
boards I'm looking at (must be x86) have either compact flash or SD
slot.  Given that the computer will run like an embedded system and
could be powered off at any time, I'd like to get a file system on it
that won't wear out the CF, and won't get corrupted with power outages.
 For the most part, the server won't do too much disk I/O.  There are no
databases, and logging isn't that important.  So some of the file system
could be read-only.  I need about 1-2 GB (this baby has to run CentOS 5
or 6 and run data acquisition software written in labview) of storage.

I've had experience on sheeva plugs running both JFFS2 and UBIFS with
standard debian installs (standard syslog, etc) and they run great, but
both file systems are designed for MTD devices, but both CF and SD are
block-level devices with internal wear-leveling, so neither file system
is appropriate here.  Besides that fact, I created a virtual 4 GB (about
the size I need) CF disk and used the block2mtd driver to make it be a
MTD device, and though I can format it with ubiformat, I cannot attach
it. It gives me a kernel memory allocation error.  Even 1 GB gives me
this error.  I can get a 512 MB image to work, but that's not enough
space for what I need anyway.  I know I can do a jffs2 emulation on
compact flash, but the mount time for a large volume is horrendous.
Even 512 MB takes a while to mount.

So at the moment I'm considering doing read-only ext4 for most of the
partitions, with a small R/W ext4 partition for variable things. But if
anyone has any better ideas or experience in this area, I welcome



More information about the PLUG mailing list