Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

After experiencing some crash related file system outages (requiring manual fsck and repair, we are looking for the optimum file system and fs config for an embedded linux with HDD or SDD mass storage.

A good candidate so far is using ext3fs with "journal_data" mount option to minimize the risk on inconsistent data and meta data after a crash.

I would be happy to hear about other/better options any experiences.

NB "crash" here refers mostly to unexpected shutdown due to power loss. The ext4fs does not seem to handle this very gracefully.

share|improve this question

migrated from stackoverflow.com Dec 22 '09 at 15:38

This question came from our site for professional and enthusiast programmers.

    
SDD = ??? Solid state disk? –  Josh Kelley Dec 22 '09 at 15:43
add comment

2 Answers

One way to make embedded filesystems reliable is to make the entire filesystem read-only. If you really need to write things you can use tmpfs and lose them at reboot, or have a separate filesystem for that data that isn't necessary for successful boot (i.e. boot scripts fsck or rebuild that fs if it's damaged.)

share|improve this answer
add comment

The Embedded Linux Wiki has a File Systems section with a lot of useful info. However, it focuses more on the low-hardware-specs / very-specialized-purpose end of embedded; if you're dealing with hard drives and ext3, you may be closer to a traditional PC environment.

Making your root filesystem read-only, as in Eric Seppanen's answer, is an excellent suggestion.

For solid state drives and flash drives, journaling may not be a good idea; the drives' faster seek times mean that the performance gain of journaling is less noticeable, and journaling means extra writes which means less disk lifespan. See this Slashdot question and especially these comments for discussion.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.