man ps
says (emphasis mine):comm COMMAND command name (only the executable name).
Modifications to the command name will not be
shown. A process marked is partly
dead, waiting to be fully destroyed by its
parent. The output in this column may contain
spaces. (alias ucmd, ucomm). See also the args
format keyword, the -f option, and the c option.
When specified last, this column will extend to
the edge of the display. If ps can not determine
display width, as when output is redirected
(piped) into a file or another command, the
output width is undefined (it may be 80,
unlimited, determined by the TERM variable, and
so on). The COLUMNS environment variable or
--cols option may be used to exactly determine
the width in this case. The w or -w option may
be also be used to adjust width.
Indeed, setting the
COLUMNS
variable manually helps:watch "ps aux | grep 'ps aux'"
COLUMNS=2000 watch "ps aux | grep 'ps aux'"
Comments
Post a Comment
https://gengwg.blogspot.com/