NetBSD Problem Report #8943
Received: (qmail 14716 invoked from network); 3 Dec 1999 17:46:02 -0000
Message-Id: <199912031745.LAA28644@torpor.spc.uchicago.edu>
Date: Fri, 3 Dec 1999 11:45:54 -0600 (CST)
From: WL <wliao@ccp.uchicago.edu>
Reply-To: wliao@ccp.uchicago.edu
To: gnats-bugs@gnats.netbsd.org
Subject: undocumented option in /bin/ps
X-Send-Pr-Version: 3.95
>Number: 8943
>Category: bin
>Synopsis: -U _name_ shows process of _name_; not mentioned in man page
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: bin-bug-people
>State: closed
>Class: doc-bug
>Submitter-Id: net
>Arrival-Date: Fri Dec 03 09:48:00 +0000 1999
>Closed-Date: Sat Dec 04 01:24:05 +0000 1999
>Last-Modified: Sat Dec 04 01:25:02 +0000 1999
>Originator: WL
>Release: 1.4.1
>Organization:
>Environment:
System: NetBSD torpor 1.4.1 NetBSD 1.4.1 (TORPORa) #0: Mon Nov 8 11:17:30 PST 1999 wliao@ssdlbc-pc24:/usr/src/sys/arch/i386/compile/TORPORa i386
>Description:
ps -U _name_ gives information about the specified user. This
really nice and handy switch isn't documented in the man
page, nor the ps error message.
>How-To-Repeat:
$ man ps | grep '\-U'
$ ps -help
ps: option requires an argument -- p
usage: ps [-aChjKlmrSTuvwx] [-O|o fmt] [-p pid] [-t tty]
[-M core] [-N system] [-W swap]
ps [-L]
>Fix:
Just some simple changes to /usr/src/bin/ps so the messages
show up.
$ nroff -man ps.1 | grep '\-U'
[-t tty] [-W swap] [-U username]
-U Display information associated with the specified user.
$ ./ps -help
ps: option requires an argument -- p
usage: ps [-aChjKlmrSTuvwx] [-O|o fmt] [-p pid] [-t tty]
[-M core] [-N system] [-W swap] [-U username]
ps [-L]
A "diff -u" for ps.c and ps.1 is pasted below.
--- ps.c.orig Fri Dec 3 11:14:21 1999
+++ ps.c Fri Dec 3 11:15:04 1999
@@ -532,7 +532,7 @@
(void)fprintf(stderr,
"usage:\t%s\n\t %s\n\t%s\n",
"ps [-aChjKlmrSTuvwx] [-O|o fmt] [-p pid] [-t tty]",
- "[-M core] [-N system] [-W swap]",
+ "[-M core] [-N system] [-W swap] [-U username]",
"ps [-L]");
exit(1);
/* NOTREACHED */
--- ps.1.orig Fri Dec 3 11:16:34 1999
+++ ps.1 Fri Dec 3 11:20:59 1999
@@ -63,6 +63,9 @@
.Bk -words
.Op Fl W Ar swap
.Ek
+.Bk -words
+.Op Fl U Ar username
+.Ek
.Nm ""
.Op Fl L
.Sh DESCRIPTION
@@ -165,6 +168,8 @@
option implies the
.Fl r
option.
+.It Fl U
+Display information associated with the specified user.
.It Fl v
Display information associated with the following keywords:
pid, state, time, sl, re, pagein, vsz, rss, lim, tsiz,
>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed
State-Changed-By: hubertf
State-Changed-When: Fri Dec 3 17:24:05 PST 1999
State-Changed-Why:
patch applied, thanks!
(not only to ps.c but also to ps.1!)
- Hubert
>Unformatted:
(Contact us)
$NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.