Barriers still not passing on simple dm devices...
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 9 lines · Eric Sandeen
I've noticed that on 2.6.29-rcX, with Andi's patch (
ab4c1424882be9cd70b89abf2b484add355712fa, dm: support barriers on simple devices) barriers are still getting rejected on these simple devices.So what's the right way around this? What should dm (or md for that matter) advertise on their queues about ordered-ness? Should there be some sort of "
QUEUE_ORDERED_PASSTHROUGH" or something to say "this level doesn't care, ask the next level" or somesuch? Or should it inherit the flag from the next level down? Ideas?
IMO each block device SHOULD provide barriers - either native or emulated, and each meta device MUST provide emulated barriers if it provides dynamic device binding and barriers.
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 2 lines · Mikulas Patocka
./drivers/block/loop.c:
doesn't reject barriers, it's ok because it doesn't reorder requests
But it relies on other devices to not reorder.
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 16 lines · Chris Mason
Quoted 6 lines · Mikulas Patocka
Quoted 5 lines
The error handling is complex, no doubt
about that. But the trial barrier test is pretty trivial and even could be easily abstracted out. If a later barrier write fails, then that's really no different than if a normal write fails. Error handling is not easy in that case.Quoted 7 lines
I had a discussion with Andi about it some times ago. The conclusion was that all the current filesystems handle barriers failing in the middle of the operation without functionality loss, but it makes barriers useless for any performance-sensitive tasks (commits that wouldn't block concurrent activity). Non-blocking commits could only be implemented if barriers don't fail.
Quoted 2 lines
If a barrier fails at runtime, the filesystems do fall back to not doing barriers without real problems.
That's because there are no real problems in not honoring barriers - unless your system crashes.
Quoted 2 lines
But, that's because they don't actually
rely on the barriers to decide if an async commit is a good idea.
As long as they cannot rely on barriers - how should they?
[...]
Quoted 2 lines
In general, async commits happen with threads and they aren't related to barriers.
If my filesystem said "First update b, then let a point to b", where the H is the thread?
Quoted 1 line
Barriers don't really give us error handling,
Each request should give you error handling, but you are right: The whole queue after the barrier must be aborted, too. (Or better: The part depending on the barrier.)
Quoted 3 lines
and they are at
the very end of a long chain of technical problems around commits that don't block concurrent activity.
You lost me here, but I guess the end will be a major rewrite.