mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jamie Lokier <jamie@shareable.org>
To: Miklos Szeredi <miklos@szeredi.hu>
Cc: akpm@osdl.org, linux-kernel@vger.kernel.org,
	linux-fsdevel@vger.kernel.org
Subject: Re: [PATCH] FUSE: don't allow restarting of system calls
Date: Sat, 21 May 2005 00:13:12 +0100	[thread overview]
Message-ID: <20050520231312.GD29155@mail.shareable.org> (raw)
In-Reply-To: <E1DZ3Mx-0003ST-00@dorka.pomaz.szeredi.hu>

Miklos Szeredi wrote:
> This patch removes ability to interrupt and restart operations while
> there hasn't been any side-effect.
> 
> The reason: applications.  There are some apps it seems that generate
> signals at a fast rate.  This means, that if the operation cannot make
> enough progress between two signals, it will be restarted for ever.
> This bug actually manifested itself with 'krusader' trying to open a
> file for writing under sshfs.  Thanks to Eduard Czimbalmos for the
> report.

Caching and prefetching would solve that probem much more usefully.

Does sshfs not cache or prefetch any of the data?

IMHO, caching and prefetching makes a lot of sense for this situation
- in fact, it does for any kind of filesystem operation during a
sequence of file operations where a program does not use locks (flock
etc.), fsyncs, or open/close.

Surely caching and prefetching should be a generic feature of FUSE for
all its filesystems unless disabled.  Is there a reason why this is
not done, or is it just not implemented?

> The problem can be solved just by making open() uninterruptible,
> because in this case it was the truncate operation that slowed down
> the progress.  But it's better to solve this by simply not allowing
> interrupts at all (except SIGKILL), because applications don't expect
> file operations to be interruptible anyway.  As an added bonus the
> code is simplified somewhat.

NFS makes file operations interruptible when they're mounted with
"intr".

It's a life-saver, when the server or network gets wedged, to be able
to Control-C a program instead of it being stuck in D-state and
requiring a reboot.

Having a program be stuck in read/write ignoring signals, so that
Control-C, Control-Z and kill don't work on it, while it's waiting for
some network operation, is a horrible thing.

-- Jamie

  reply	other threads:[~2005-05-20 23:13 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-05-20  9:00 Miklos Szeredi
2005-05-20 23:13 ` Jamie Lokier [this message]
2005-05-21  0:41   ` Bryan Henderson
2005-05-21  6:18     ` Miklos Szeredi
2005-05-21  6:12   ` Miklos Szeredi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20050520231312.GD29155@mail.shareable.org \
    --to=jamie@shareable.org \
    --cc=akpm@osdl.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=miklos@szeredi.hu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®