Bug 64862 - RHEL 2.1/IPF/QU3: -c option to netstat(1) repeatedly prints headings (not I/F stats)
Summary: RHEL 2.1/IPF/QU3: -c option to netstat(1) repeatedly prints headings (not I/F...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 2.1
Classification: Red Hat
Component: net-tools
Version: 2.1
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Phil Knirsch
QA Contact: Aaron Brown
URL:
Whiteboard:
: 110590 (view as bug list)
Depends On:
Blocks: 73750 107565
TreeView+ depends on / blocked
 
Reported: 2002-05-13 18:00 UTC by Glen A. Foster
Modified: 2015-03-05 01:10 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2003-12-19 14:46:14 UTC


Attachments (Terms of Use)
patch that fixes this bug (4.63 KB, patch)
2002-08-21 20:30 UTC, Scott Edlund
no flags Details | Diff


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2003:164 normal SHIPPED_LIVE Updated net-tools package fixes netstat -c output 2003-12-19 05:00:00 UTC

Description Glen A. Foster 2002-05-13 18:00:09 UTC
Description of Problem: Per the netstat(1) man-page: 

   -c, --continuous       This  will cause netstat to print the selected
information every second continuously.  But when "netstat -ic" is run, only the
heading is printed every time, even when there is network activity on the
interface(s).

Version-Release number of selected component (if applicable):
# rpm -qf $(which netstat)
net-tools-1.60-3

How Reproducible: 100%

Actual Results:
# netstat -i
Kernel Interface table
Iface   MTU Met   RX-OK RX-ERR RX-DRP RX-OVR   TX-OK TX-ERR TX-DRP TX-OVR Flg
eth0   1500   029960939      0      0    948 5972829      0      0      0 BRU
lo    16436   0  124720      0      0      0  124720      0      0      0 LRU
# netstat -ic
Kernel Interface table
Iface   MTU Met   RX-OK RX-ERR RX-DRP RX-OVR   TX-OK TX-ERR TX-DRP TX-OVR Flg
eth0   1500   029961009      0      0    948 5973075      0      0      0 BRU
lo    16436   0  124720      0      0      0  124720      0      0      0 LRU
Iface   MTU Met   RX-OK RX-ERR RX-DRP RX-OVR   TX-OK TX-ERR TX-DRP TX-OVR Flg
Iface   MTU Met   RX-OK RX-ERR RX-DRP RX-OVR   TX-OK TX-ERR TX-DRP TX-OVR Flg
Iface   MTU Met   RX-OK RX-ERR RX-DRP RX-OVR   TX-OK TX-ERR TX-DRP TX-OVR Flg
Iface   MTU Met   RX-OK RX-ERR RX-DRP RX-OVR   TX-OK TX-ERR TX-DRP TX-OVR Flg
Iface   MTU Met   RX-OK RX-ERR RX-DRP RX-OVR   TX-OK TX-ERR TX-DRP TX-OVR Flg



Expected Results: With or without the header, I would expect to see interface
statistics.  This is very reproducible; you can start up a ping to localhost and
a ping to exercise eth0, and all that ever prints is the header -- no interface
statistics.


Additional Information:

Comment 1 Scott Edlund 2002-08-21 20:30:45 UTC
Created attachment 72072 [details]
patch that fixes this bug

Comment 2 Phil Knirsch 2002-10-04 08:36:16 UTC
*** Bug 73750 has been marked as a duplicate of this bug. ***

Comment 3 Glen A. Foster 2003-01-24 22:17:52 UTC
This defect still exists in Phoebe (version 2) public beta.

Comment 4 Nishanth Thomas 2003-02-07 17:08:05 UTC
*** Bug 83728 has been marked as a duplicate of this bug. ***

Comment 5 Phil Knirsch 2003-02-11 14:15:28 UTC
Fixed in latest net-tools version. Now every 8 outputs the header is printed
again and a delay option has been added, too.

Read ya, Phil 

Comment 6 Glen A. Foster 2003-03-31 22:26:39 UTC
Can we get an errata update posted on the RHN server for IA64 as well?

Comment 8 Phil Knirsch 2003-04-22 12:58:00 UTC
OK, package updated and built and opened a RHEL AS 2.1 errata for it.

Please make sure it gets added to the AS2.1 QU3 update.

Read ya, Phil

Comment 9 Larry Troan 2003-05-13 14:49:54 UTC
ISSUE TRACKER 21400 opened as sev 2

Comment 10 Glen A. Foster 2003-07-14 16:52:19 UTC
Fix verified in an early cut of an ia64-based distribution.  This defect is also
in AS2.1 QU2 errata for IA64 -- really hoping it gets fixed for QU3 (per Phil).

Comment 11 Larry Troan 2003-08-08 22:56:02 UTC
Phil requests this be fixed in QU3 errata. Blocking BUG...

Comment 12 Larry Troan 2003-08-08 22:56:55 UTC
Errata, not Taroon. Sorry. 

Comment 13 Scott Edlund 2003-08-12 16:25:24 UTC
Phils patch seems broken on machines with interface aliases:

Here is output from RH9 machine.

Iface     MTU Met   RX-OK RX-ERR RX-DRP RX-OVR   TX-OK TX-ERR TX-DRP TX-OVR Flg
eth0       1500   051723645      0      0      064367877      0      0      0 BMRU
eth0:1     1500   0 9292193      0      0    142 8149663      0      0      0 BMRU
eth1       1500   0 9292193      0      0    142 8149663      0      0      0 BMRU
lo        16436   0   34498      0      0      0   34498      0      0      0 LRU
eth0       1500   051723645      0      0      064367877      0      0      0 BMRU
eth0:1     1500   0 9292194      0      0    142 8149663      0      0      0 BMRU
eth1       1500   0 9292194      0      0    142 8149663      0      0      0 BMRU
lo        16436   0   34498      0      0      0   34498      0      0      0 LRU
eth0       1500   051723668      0      0      064367889      0      0      0 BMRU
eth0:1     1500   0 9292194      0      0    142 8149663      0      0      0 BMRU
eth1       1500   0 9292194      0      0    142 8149663      0      0      0 BMRU
lo        16436   0   34498      0      0      0   34498      0      0      0 LRU
eth0       1500   051723668      0      0      064367889      0      0      0 BMRU
eth0:1     1500   0 9292222      0      0    142 8149694      0      0      0 BMRU
eth1       1500   0 9292222      0      0    142 8149694      0      0      0 BMRU

Notice data from eth0:1 and eth1 as being the same.  This is incorrect.  Also,
it should print the header every x times, print the totals for each interface
then print the deltas of each other ( ala solaris, hpux, aix ) like in the patch
that I provided.


Comment 14 Ulf Zimmermann 2003-08-20 19:18:51 UTC
In addition to the above mentioned issue, "netstat -c -i eth0" or 
even "netstat -i eth0" isn't working either, it prints out all interfaces:

dbprod-01 ulf /home/ulf > netstat -c -i eth0
Kernel Interface table
Iface   MTU Met   RX-OK RX-ERR RX-DRP RX-OVR   TX-OK TX-ERR TX-DRP TX-OVR Flg
eth0   1500   014891764      0      0      0 9722602      0      0      0 BMRU
eth1   1500   036690252      0      0      044376013      0      0      0 BMRU
lo    16436   0 2373810      0      0      0 2373810      0      0      0 LRU
Iface   MTU Met   RX-OK RX-ERR RX-DRP RX-OVR   TX-OK TX-ERR TX-DRP TX-OVR Flg
Iface   MTU Met   RX-OK RX-ERR RX-DRP RX-OVR   TX-OK TX-ERR TX-DRP TX-OVR Flg

dbprod-01 ulf /home/ulf > netstat -c --interfaces eth0
Kernel Interface table
Iface   MTU Met   RX-OK RX-ERR RX-DRP RX-OVR   TX-OK TX-ERR TX-DRP TX-OVR Flg
eth0   1500   014892105      0      0      0 9722900      0      0      0 BMRU
eth1   1500   036691214      0      0      044376848      0      0      0 BMRU
lo    16436   0 2373902      0      0      0 2373902      0      0      0 LRU
Iface   MTU Met   RX-OK RX-ERR RX-DRP RX-OVR   TX-OK TX-ERR TX-DRP TX-OVR Flg
Iface   MTU Met   RX-OK RX-ERR RX-DRP RX-OVR   TX-OK TX-ERR TX-DRP TX-OVR Flg
Iface   MTU Met   RX-OK RX-ERR RX-DRP RX-OVR   TX-OK TX-ERR TX-DRP TX-OVR Flg


Comment 16 Larry Troan 2003-10-16 22:13:19 UTC
WAS MUSTFIX for Update3, but HP-IPF reduced to SHOULDFIX. Changing blocker to
correct bug.

Comment 18 Phil Knirsch 2003-11-26 10:01:36 UTC
The -i option hasn't been working for a long time and was also wrongly
documented in the manpages.

I've been working on a fix for that but unfortunately that won't make
it in U3.

I've already scheduled another net-tools update for U4 which will then
include a fix for the interface alias problem as well as for the -i
option.

Thanks,

Read ya, Phil

Comment 19 Phil Knirsch 2003-12-03 10:53:53 UTC
*** Bug 110590 has been marked as a duplicate of this bug. ***

Comment 22 John Flanagan 2003-12-19 14:46:14 UTC
An errata has been issued which should help the problem described in this bug report. 
This report is therefore being closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files, please follow the link below. You may reopen 
this bug report if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2003-164.html



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