9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: "Bruce Ellis" <brucee@chunder.com>
To: <9fans@cse.psu.edu>
Subject: Re: [9fans] killing rogue processes
Date: Fri, 19 Dec 2003 11:03:11 +1100	[thread overview]
Message-ID: <01a901c3c5c3$864cf1b0$8201a8c0@cc77109e> (raw)
In-Reply-To: <E1AX1TG-000DM0-LU@t40.swtch.com>


----- Original Message -----
From: "Russ Cox" <rsc@swtch.com>
To: <9fans@cse.psu.edu>
Sent: Friday, December 19, 2003 3:57 AM
Subject: Re: [9fans] killing rogue processes


...

> Kill the server it is talking to, which is clearly misbehaving

no, you have to try harder...  sometimes a lot harder.
it is not a problem with misbehaving servers.  it's a flaw
in 9p(2000), or devmnt, take your pick.

when a process exits it closes its fds.
if the close is the final reference to a channel then
the chan is clunked and if the chan is being served
the poor old process sends off a Tclunk and sits
around waiting for the Rclunk.  if the server is also
exiting (which happens when they are in the same
killed pgrp) they might be lucky enough to *not* be
stuck waiting for each other.

a very common scenario is a deadly embrace between
rio upas/fs and exportfs.  it happens all the time to me.
rob's suggestion was to "rattle the cage enough" to get
things to go away.

things were even worse in inferno where fds are never
closed explicitly.  i fixed it in inferno because any
system of any complexity demanded a huge stick to
rattle the cage.

as for "who is using inferno", well i use it for almost
everything - almost all code i've written this year has
been in limbo.  i run emu on plan9 for development,
emu on win2k to give me access to all the devices
that i can't get data sheets for (particularly usb midi
and non-standard usb audio).  of course it also runs
in my phone and router (wrt54g) and on $50 386
machines from china, various arm/xscale boards etc.
my inferno web server (with active scripting) is so
much smaller and faster than apache that it runs
without pain on all of the above platforms.

i've had informal sporadic discussions with VN about
how to share the wealth (the inferno i run is so divergent
from theirs that i wouldn't attempt a merge).  maybe
something will happen - when the weather gets worse.

just my threepence worth.

brucee


      parent reply	other threads:[~2003-12-19  0:03 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-12-18 17:42 mirtchov
2003-12-18 16:57 ` Russ Cox
2003-12-18 18:28   ` andrey mirtchovski
2003-12-18 19:50     ` David Presotto
2003-12-18 20:01       ` mirtchov
2003-12-18 19:13         ` Russ Cox
2003-12-19 14:31           ` mirtchov
2003-12-18 22:31             ` Russ Cox
2003-12-19 17:20               ` ron minnich
2003-12-20  9:01                 ` boyd, rounin
2003-12-19 17:25               ` mirtchov
2003-12-19  6:19         ` boyd, rounin
2003-12-18 20:29           ` mirtchov
2003-12-18 20:41             ` Scott Schwartz
2003-12-18 20:48               ` mirtchov
2003-12-19  3:07             ` David Presotto
2003-12-19  6:45             ` boyd, rounin
2003-12-19  5:57       ` boyd, rounin
2003-12-19  0:03   ` Bruce Ellis [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='01a901c3c5c3$864cf1b0$8201a8c0@cc77109e' \
    --to=brucee@chunder.com \
    --cc=9fans@cse.psu.edu \
    /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;
as well as URLs for NNTP newsgroup(s).