All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jan Harkes <jaharkes@cs.cmu.edu>
To: Sujal Shah <sujal@sujal.net>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: FS Development (or interrupting ls)
Date: Fri, 3 Aug 2001 10:31:41 -0400	[thread overview]
Message-ID: <20010803103141.A25450@cs.cmu.edu> (raw)
In-Reply-To: <3B69EF9C.74DF18D6@sujal.net>
In-Reply-To: <3B69EF9C.74DF18D6@sujal.net>

On Thu, Aug 02, 2001 at 08:26:04PM -0400, Sujal Shah wrote:
> 
> I'm working on a userspace filesystem daemon which replaces Venus (from
> CODA) or podfuk (UserVFS) using the CODA driver.  I'm still early in my
> development process, but I've run into one frustrating problem.  While
> testing my code, I have started causing ls to hang. 
> 
> It keeps the directory open, which means I can't do things like, oh,
> unmount the filesystem. :-)  Anyone have any suggestions on recovering
> gracefully when this happens short of rebooting (which is what I do
> now)?  Basically, 'ls' hangs, and can't be killed (even kill -9) and
> 'lsof' lists the directory as open (which is furthered confirmed by
> umount complaining about the filesystem being busy).

Kill the userspace daemon, when the /dev/cfs0 device is closed all
pending upcalls are aborted and further accesses to /coda will return
EIO or something.

You still won't be able to unmount until all processes that have a
reference to a file in /coda, typically caused by their 'cwd', i.e.
use cd to move shell's out of the /coda tree and kill off any
applications that were started from a shell that was at the time in
/coda.

It is unusual that you are unable to kill ls, all upcalls to the
userspace process should be interruptable (except for close). There
might be something wrong in the way you created your directory container
files and the kernel gets stuck in readdir, but strace or enabling
verbose debugging from the kernel module should help you narrow it down.
(echo 1 > /proc/sys/coda/printentry ; echo 4095 > /proc/sys/coda/debug)

Jan


      parent reply	other threads:[~2001-08-03 14:32 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <3B69EF9C.74DF18D6@sujal.net>
2001-08-03 10:18 ` FS Development (or interrupting ls) Amit S. Kale
2001-08-03 10:38   ` [patch] (was " Tigran Aivazian
2001-08-03 14:43   ` Daniel Phillips
2001-08-03 15:13     ` Sujal Shah
2001-08-03 16:14     ` Tigran Aivazian
2001-08-03 14:31 ` Jan Harkes [this message]

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=20010803103141.A25450@cs.cmu.edu \
    --to=jaharkes@cs.cmu.edu \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sujal@sujal.net \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.