|
From: Nix <ni...@es...> - 2006-01-25 16:32:38
|
On Wed, 25 Jan 2006, Miklos Szeredi stipulated: > One of the more interesting observations about FUSE is that it lacks > support for interrupting operations. > > Not the abort style 'kill -9' interrupt that already works, but a > graceful interrupt which notifies the filesystem about the need to > cancel the operation. > > How do people feel about this? Are there situations where this would > be useful? I'm trying to work out how it could be responded to by the filesystem. Even a filesystem using a multithreaded main loop would need to have the interrupted thread check some sort of interruption flag periodically, which would be really annoying --- and since the interrupted thread is likely to itself be blocked in the kernel at the time of the interruption, it's even harder to make it work usefully. One that didn't have a multithreaded main loop wouldn't even be able to receive the notification until the blocked operation had completed, unless you sent it a signal or something, and even if you do that, what can the userspace filesystem do about it? It's probably *still* blocked or sleeping in the kernel... > One problem related to this is that some applications assume that > filesystem operations are uninterruptible, which is generally true for > disk filesystems, but not necessarily for network filesystems. Certainly that's a theoretical problem, but in practice if applications can't cope with an interruption error then they probably can't cope with any other read()/write() errors either, including bad blocks, closes of their fd by children, or disk full errors :/ I've been running NFS in interruptible mode across the board for years and nothing's ever gone wrong. (Of course, interruption might annoy, say, a database that's trying to maintain consistency in some file, and the file vanishes --- but a DB has to be able to cope with that sort of thing anyway, or it can't cope with power failures.) -- `Everyone has skeletons in the closet. The US has the skeletons driving living folks into the closet.' --- Rebecca Ore |