you could try
pargs <PID>
this gives you a list of all arguments
or else use an other ps. If run as root (or any user with enough privileges for that matter)
/usr/ucb/ps auxww
will give you all arguments. Its part of SUNWscpu, "Source Compatibility, (Usr)"
ps
is a very system dependant command. So the answer will depend on the variant of Unix you're using.
With the ps
from procps-ng version 3.3.3 on Linux:
ps -Ao "$(ps L|cut -d' ' -f1 | grep -vx thcount)" | less -S
(for some reason thcount
appears in the list of known fields but is not accepted as argument to -o
. nlwp
is OK though).
You'll get a lot of duplication since many of those fields are aliases for the same thing (or different ways to express it. For instance, you don't really need start
once you've got lstart
).
For the column headers to display the field selector instead of the normal heading (to help you refine which column you do want):
ps -Ao "$(ps L|sed -n '/thcount/!s/\([^ ]*\).*/\1=\1/p')" | less -S
The fields specified by POSIX are args, comm, etime, group, nice, pcpu, pgid, pid, ppid, rgroup, ruser, time, tty, user and vsz. So you can use
ps -Ao args,comm,etime,group,nice,pcpu,pgid,pid,ppid,rgroup,ruser,time,tty,user,vsz
For a command that should works across all compliant systems.
Best Answer
The screen height doesn’t limit the total output, it determines how often the header is repeated (if requested):
will repeat the header every twenty lines (so you’ll get a header, nineteen lines of output, a header, etc.).