Email or username:

Password:

Forgot your password?
10 comments
Hector Martin

@gudenau They cheat at the OS layer, we cheat at the driver layer because it'd be stupid not to. Our default flush interval is faster than macOS though, so your data is strictly safer on Linux (you can lose up to 30 seconds of work on macOS or so, only 1 second on Linux with default settings).

None of this matters on laptops because you are guaranteed a flush when the battery is about to die or when you hold down the power button. This only matters for desktops, when you yank power.

gudenau

@marcan Or there is a power outage or whatever, at least they are both journal filesystems I suppose so it shouldn't matter too much...

Hector Martin

@gudenau Yeah, I haven't done any explicit stress tests yet but I've hard-rebooted (including the NVMe controller) these things hundreds of times and never noticed any unexpected corruption (just the usual things with NULL trailing blocks in files, which is normal for ext4 defaults) so I'm pretty confident if there is some problem lurking it's *really* hard to hit.

Nicolás Alvarez

@gudenau @marcan IIRC you mentioned Mac mini lasting surprisingly long (1 whole second) when unplugged? Wish there was a way to detect that early enough to trigger a flush 😅

Hector Martin

@nicolas17 @gudenau Yeah, I looked for that... unfortunately, couldn't find any :(

Stephen Bannasch (316 ppm)

@nicolas17 @gudenau @marcan I wrote a kiosk application in Electron that ran on a windows 11 system. The network would go down on a power outage about 200ms before the power that ran the system failed. That was enough time to stop writing data.

gudenau

@stepheneb @nicolas17 @marcan That's pretty wild, but it's also very situation dependent.

Stephen Bannasch (316 ppm)

@gudenau @nicolas17 @marcan I was getting random corruption because my app updated persistent state when the network changed state. These were kiosks with large touchscreens in science museums. Took a while to debug this remotely because the network changing state occurred much more often than the power being randomly cut.

Stephen Bannasch (316 ppm)

@gudenau @nicolas17 @marcan there was an deterministic ordering for which systems shut down first and lucky for my needs the network shut down first.

Go Up