From: Christopher Faylor <cygwin@cygwin.com>
To: cygwin@cygwin.com
Subject: Re: cygwin 1.3.10: kill gives spurious Not owner
Date: Mon, 04 Mar 2002 11:10:00 -0000 [thread overview]
Message-ID: <20020304191012.GE14103@redhat.com> (raw)
In-Reply-To: <002301c1c394$f2c00090$dc37500a@midaskapiti.com>
On Mon, Mar 04, 2002 at 03:54:52PM -0000, Stephen Osborn wrote:
>When using kill I get spurious "Not owner" messages, even though all
>processes (reported by ps) are running as me.
>
>In the mailing list archives the only problems with kill seem to be
>related to killing *other* users' processes. This is not what I am
>doing.
>
>I am running Cygwin on NT. Cygcheck o/p at the bottom.
>
>I have a script (A) which runs another script (B) in a separate
>process. B stores its PID and this is retrieved by the A. B also runs
>another script (C) in a separate process.
>
>Script A tries to remove all of these processes in a housekeeping
>exercise, by using ps, grep and script B's PID.
>
>This successfully kills script B but on script C a "Not owner" error is
>thrown.
>
>This was working as expected (i.e. both B & C were killed) but this
>changed a couple of days ago.
>
>I have modified script A to remove the kill command and after the run
>ps gives
>
> PID PPID PGID WINPID TTY UID STIME COMMAND
> 802 1 802 802 con 1006 14:11:18 /usr/bin/bash
>I 564 1 564 564 con 1006 14:11:40 /usr/bin/bash
> 831 1 1020 1034 con 1006 14:38:57 /usr/bin/sh
> 920 831 1020 920 con 1006 Jan 1 /cygdrive/d/jdk1.3/bin/java
> 682 802 682 571 con 1006 14:44:04 /usr/bin/ps
>
>Issuing kill 920 (=script C) yields
>bash: kill: (920) - Not owner
/cygdrive/d/jdk1.3/bin/java is undoubtedly not a cygwin process so it
doesn't respond to cygwin signals. This is because recent versions of
/bin/sh now use vfork()/exec() to start processes. vfork/exec does
not leave an cygwin stub around to deal with signals for non-cygwin
processes.
The work around is to use bash to start the process.
cgf
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
next prev parent reply other threads:[~2002-03-04 19:10 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2002-03-04 7:51 Stephen Osborn
2002-03-04 11:10 ` Christopher Faylor [this message]
2002-03-07 7:28 ` Stephen Osborn
2002-03-07 8:42 ` Christopher Faylor
2002-03-19 10:00 ` Stephen Osborn
2002-03-19 10:49 ` Christopher Faylor
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=20020304191012.GE14103@redhat.com \
--to=cygwin@cygwin.com \
/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 read-only IMAP folder(s) and NNTP newsgroup(s).