delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2002/04/09/23:59:33

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Date: Tue, 09 Apr 2002 23:59:08 -0400
From: Alan Dobkin <Alan AT ADobkin DOT Net>
To: cygwin AT cygwin DOT com
Subject: Re: ps command - revisited
Message-ID: <3130134465.1018396748@ADobkin-1.US.Nortel.Com>
In-Reply-To: <20020410030805.GC23551@redhat.com>
References: <20020410030805 DOT GC23551 AT redhat DOT com>
MIME-Version: 1.0

--On Tuesday, April 09, 2002 11:08 PM -0400 Christopher Faylor
<cgf AT redhat DOT com> wrote:

> As with so many other things in Cygwin, what you see is what 
> you get from the underlying Windows API that we're using.  If 
> certain processes aren't showing up when we say "give me all 
> of your processes", then they aren't being displayed.

Well, I just did a few tests, and the results may shed some light 
on the problem, which seems to be specific to Cygwin, not the API.  
I ran ps -W on several Windows 2000 systems, including one with a 
clean install of the OS and Cygwin from this week.  In every case, 
the CSRSS.EXE process is excluded when ps is run on the local box, 
either in a bash cmd shell or rxvt.  However, when using SSH, even 
to localhost, the CSRSS.EXE process magically re-appears.  Also, 
using every one of the other ps-type utilities (i.e. TLIST, PULIST, 
PsList, Task Manager, etc.), this process is displayed at all times.

So why would Cygwin be excluding this process on the local machine?  
Whatever the answer is may be the same reason to why the original 
poster's process wasn't being displayed either, and I wonder if 
their process would be displayed if they tried the ps -W via SSH.

> The exception is PID 0.  The zero pid is special to cygwin so it 
> can't be displayed due to a cygwin limitation.

A simple solution to this might be to have ps -W prepend PID 0 to 
its output as a placeholder so the listing is complete.  Similarly, 
the System process should be identified as such instead of unknown.

> The functionality you see now is all that I plan on providing.
> 
> Patches are, as always, gratefully accepted, however.

I don't intend to submit a patch for this either, at least not any 
time soon, but I would be happy to provide information and testing 
for someone else who is willing and able to work on it.

Alan

--
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/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019