3 ms·
Well, actually I would love to disable disk caching on my embedded Linux systems because it's a really common use case that they lose power and I would like to
by jschwartzi 8y ago
Well, actually I would love to disable disk caching on my embedded Linux systems because it's a really common use case that they lose power and I would like to not have a bunch of data in memory when that happens. Right now I have to call sync before I do anything with the power or when I come back up everything I just "copied" is gone.
- helianer 8y agoYou would still want to leave on read caching. You can still turn off write caching on your disks with hdparm.
- fulafel 8y agoYou can use O_SYNC. This will make the wear on your flash bigger so use with caution on cheapo flash, like SD cards.
- mlaretallack 8y agoWas about to say this. The disk cache does get in the way when you want to have realtime response on embedded system. The swapd just seems to cause issues.