Bug 54195 - ps shouldn't truncate lines when outputing to a pipe
ps shouldn't truncate lines when outputing to a pipe
Status: CLOSED NOTABUG
Product: Red Hat Linux
Classification: Retired
Component: procps (Show other bugs)
7.1
i386 Linux
medium Severity medium
: ---
: ---
Assigned To: Daniel Walsh
Aaron Brown
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2001-10-01 10:15 EDT by Need Real Name
Modified: 2007-04-18 12:37 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2004-03-29 07:45:22 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Need Real Name 2001-10-01 10:15:28 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.4+) Gecko/20010921

Description of problem:
Piping ps to less or to an output file results in lines greater then 80
chars being truncated, even when running in a window with greater then 80
lines of width.

Version-Release number of selected component (if applicable):


How reproducible:
Always

Steps to Reproduce:
1.Start a maximized gnome-terminal
2.run ps e  ps outputs chars to the edge of the screen
3.run ps e > ps.out output truncated at 80 chars
	

Actual Results:  ps output is truncated

Expected Results:  ps should output it's full, untruncated, line of
information.

Additional info:
Comment 1 Alexander Larsson 2002-06-20 09:46:20 EDT
This is a "historical" issue. Use the -w or w argument to make ps not cut the
output.
Comment 2 Need Real Name 2002-06-20 09:58:38 EDT
It still doesn't seem like it does the "right" thing. When you have a terminal of 80 chars
it should truncate to 80 chars. When you pipe the output somewhere it should give the
full lines.
Comment 3 Need Real Name 2002-06-20 10:09:50 EDT
I guess the real point here is it's very strange to have an xterm with 130 columns when
you do ps aux it fills the 130 columns but when you do ps aux | less it truncates to
80 columns.
Comment 4 Alexander Larsson 2002-06-20 10:25:38 EDT
Not truncating when the output is a pipe sounds reasonable. 
Reopening.
Comment 5 Daniel Walsh 2004-03-26 06:41:48 EST
Is this fixed in procps-3.1.15?
Comment 6 Daniel Walsh 2004-03-29 07:45:22 EST
Comments from upstream maintainer:

Current behavior differs. There is no correct behavior
though; the old behavior was quite reasonable. Failing
to truncate lines makes "ps auxe | less" look ugly.
Either way, this is a losing situation. Perhaps "ps"
should link against curses so that TERM may be used.

So not a bug.

Note You need to log in before you can comment on or make changes to this bug.