ps problem
gam
gam at amdahl.UUCP
Sat Feb 2 16:09:24 AEST 1985
> Ah, finally one I know.
> nohup-ing ps losses the user information and therefore doesn't
> print processes for you. If you try nohup ps -u[your login], it will work!
It probably will, but not because of lost user information. It is
because ps(1) looks at stderr to figure out what the "controlling
terminal" is; nohup redirects stderr to nohup.out, thus there is
no "controlling terminal." It also does not handle this case
correctly, as it blithely assumes stderr is ALWAYS a terminal.
Your example gives different selection criteria (user id) and thus
works; the default is to select all processes associated with the
current terminal.
(this was a fun problem!).
--
Gordon A. Moffett ...!{ihnp4,hplabs,sun}!amdahl!gam
More information about the Comp.unix.wizards
mailing list