tags:

views:

1685

answers:

4

When we enter:

ps -f

... the CMD column text doesn't show the full command. Any way to prevent this truncating?

Seems like it's showing the first 80 characters. We are running a fairly log command that has lots of command line switches.


Thanks for the responses.. doesn't seem like any of these do the trick though..

+2  A: 

Pipe the result into cat .. that'll ignore your terminal settings.

ps -f | cat
eduffy
+1  A: 

ps detects the size of your terminal window and clips to that.

Solution: don't output directly to the terminal!

ps -f | less
rix0rrr
A: 

G'day,

Don't forget that -eaf works with normal ps only and not luddite ucb ps.

Ucb ps uses multiple -w options to give you the complete command line.

HTH

cheers,

Rob Wells
+1  A: 

man ps:

-w Use 132 columns to display information, instead of the default which is your window size. If the -w option is specified more than once, ps will use as many columns as necessary without regard for your window size. When output is not to a terminal, an unlimited number of columns are always used.

Hence

ps -f | cat

works

Hardy