blackshard83 wrote:
Performance is degrading often very fast on cheap 32 GB USB sticks formatted as ext4 devices, but is not degrading on f2fs system over cheap 8 GB sdcards. f2fs systems are also much more stressed than ext4 (at least 700 Megabytes wrote per-day, in small and large blocks and an average of 38 GB read per-day).
Thanks, those are good data points.
blackshard83 wrote:
The only real problem so-far we encountered with f2fs is that if you don't cleanly shutdown your filesystem, it loses most of the recently written data.
Is that regardless of whether you 'sync' beforehand. Or is data safe as long as applications fsync appropriately?
IIRC, the default behaviour of linux is to flush data that has been cached for more than 30 seconds, using too much RAM and block IO if cached data is taking up more than a certain percentage of total RAM. So there shouldn't be too much of a difference in behavior after data is synced.
You shouldn't lose more than 30 seconds worth of changes with either filesystem and very little for applications which handle IO safely (like dpkg tries).
I guess complexity comes in when the controllers on the SD cards themselves lie about what they're doing. What happens when the card claims a write has occurred when it hasn't really. How does wear leveling interact with random power resets. Do you get in states where one physical block is addressed incorrectly? How can a filesystem address issues if the behavior of different SD cards can vary widely and isn't trustworthy? These aren't just rhetorical questions, I'm actually curious, since I haven't seen much information about this, given the proprietary nature of the inner workings of SD cards.
I might have gone off on too much of a tangent there, sorry.