🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.bugs.4bsd
Article #1381

"netstat -s" switches "size smaller than min" and "size < length"

#1381
From: Guy Harris
Date: Wed, 03 May 1989 20:48
40 lines
2298 bytes
Index: ucb 4.3BSD-tahoe

Description:
	"netstat -s" prints "ipstat.ips_tooshort", which is the count of
	packets dropped because the data in the packet was less than the
	size given in the IP header, with the description "...with size
	smaller than minimum", and prints "ipstat.ips_toosmall", which
	is the count of packets dropped because they were smaller than
	the IP header size, with the description "...with data size <
	data length".  The descriptions are reversed.
Repeat-By:
	Try using "netstat" to figure out why packets are being dropped,
	note that the reason given doesn't make any sense, and then
	verify that it doesn't make any sense by using a Sniffer to peek
	inside the packets.   Or just check out "ucb/netstat/inet.c" and
	"sys/netinet/ip_input.c" ....
Fix:
	Modify "ucb/netstat/inet.c" as follows:

*** inet.c.orig	Wed May  3 13:38:55 1989
--- inet.c	Wed May  3 13:41:43 1989
***************
*** 243,250 ****
  		ipstat.ips_total);
  	printf("\t%u bad header checksum%s\n",
  		ipstat.ips_badsum, plural(ipstat.ips_badsum));
! 	printf("\t%u with size smaller than minimum\n", ipstat.ips_tooshort);
! 	printf("\t%u with data size < data length\n", ipstat.ips_toosmall);
  	printf("\t%u with header length < data size\n", ipstat.ips_badhlen);
  	printf("\t%u with data length < header length\n", ipstat.ips_badlen);
  	printf("\t%u fragment%s received\n",
--- 243,250 ----
  		ipstat.ips_total);
  	printf("\t%u bad header checksum%s\n",
  		ipstat.ips_badsum, plural(ipstat.ips_badsum));
! 	printf("\t%u with size smaller than minimum\n", ipstat.ips_toosmall);
! 	printf("\t%u with data size < data length\n", ipstat.ips_tooshort);
  	printf("\t%u with header length < data size\n", ipstat.ips_badhlen);
  	printf("\t%u with data length < header length\n", ipstat.ips_badlen);
  	printf("\t%u fragment%s received\n",
Technical Details
Message-ID: <1551@auspex.auspex.com>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!cs.utexas.edu!uunet!auspex!guy

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!cs.utexas.edu!uunet!auspex!guy
From: guy@auspex.auspex.com (Guy Harris)
Newsgroups: comp.bugs.4bsd
Subject: "netstat -s" switches "size smaller than min" and "size < length"
Message-ID: <1551@auspex.auspex.com>
Date: 3 May 89 20:48:07 GMT
Reply-To: guy@auspex.auspex.com (Guy Harris)
Organization: Auspex Systems, Santa Clara
Lines: 40