summaryrefslogtreecommitdiffstats
path: root/usr.bin/netstat
Commit message (Collapse)AuthorAgeFilesLines
* remove unneeded include of route.hsam2003-10-031-0/+1
| | | | Supported by: FreeBSD Foundation
* 1. Add support for printing PIM-related statistics withhsu2003-08-075-1/+136
| | | | | | | | | netstat -s -p pim 2. Print information about the bandwidth meters installed in the kernel with netstat -g Submitted by: Pavlin Radoslavov <pavlin@icir.org>
* * Use sysctlbyname(3) to print statistics about the MFC andhsu2003-08-051-6/+24
| | | | | | | | | | | | | | multicast VIF tables. This change is needed for consistency with the rest of the netstat/mroute.c implementation, and because in some cases "netstat -g" may fail to report the multicast forwarding information (e.g., if we run a multicast router on PicoBSD). * Remove "DVMRP" from the head comment of file netstat/mroute.c, because the printed multicast-related statistics are not DVMRP-specific anymore. Submitted by: Pavlin Radoslavov <pavlin@icir.org>
* Revert last delta.ru2003-05-211-10/+3
| | | | | | | | The -l option is deprecated (hence undocumented in usage() and SYNOPSIS), as was threatened in the commitlog accompanying rev. 1.10 of main.c. Approved by: re (blanket)
* Make the mb_alloc low-watermark sysctl-tunable read-only and makebmilekic2003-05-151-0/+4
| | | | | | | | netstat(1) not display it for now because its effects are not yet completely implemented and we're about to cut 5.2-RELEASE. This is temporary. Approved by: re (scottl, rwatson)
* Back out support for RFC3514.mdodd2003-04-021-1/+0
| | | | RFC3514 poses an unacceptale risk to compliant systems.
* Implement support for RFC 3514 (The Security Flag in the IPv4 Header).mdodd2003-04-011-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | (See: ftp://ftp.rfc-editor.org/in-notes/rfc3514.txt) This fulfills the host requirements for userland support by way of the setsockopt() IP_EVIL_INTENT message. There are three sysctl tunables provided to govern system behavior. net.inet.ip.rfc3514: Enables support for rfc3514. As this is an Informational RFC and support is not yet widespread this option is disabled by default. net.inet.ip.hear_no_evil If set the host will discard all received evil packets. net.inet.ip.speak_no_evil If set the host will discard all transmitted evil packets. The IP statistics counter 'ips_evil' (available via 'netstat') provides information on the number of 'evil' packets recieved. For reference, the '-E' option to 'ping' has been provided to demonstrate and test the implementation.
* Document the undcumnt -l option (that's a lowercase `el').keramida2003-03-261-3/+10
| | | | | PR: 48466 Submitted by: Peter Philipp <dot.bomb@freenet.de>
* Kill #ifdef NS and some leftover #ifdef ISO code. Re-pack the nlist[]peter2003-03-056-1397/+34
| | | | array, it isn't likely to find any ARPAnet IMP drivers in FreeBSD.
* o Allow "buckets" in mb_alloc to be differently sized (according tobmilekic2003-02-203-41/+64
| | | | | | | | | | | | | | | | compile-time constants). That is, a "bucket" now is not necessarily a page-worth of mbufs or clusters, but it is MBUF_BUCK_SZ, CLUS_BUCK_SZ worth of mbufs, clusters. o Rename {mbuf,clust}_limit to {mbuf,clust}_hiwm and introduce {mbuf,clust}_lowm, which currently has no effect but will be used to set the low watermarks. o Fix netstat so that it can deal with the differently-sized buckets and teach it about the low watermarks too. o Make sure the per-cpu stats for an absent CPU has mb_active set to 0, explicitly. o Get rid of the allocate refcounts from mbuf map mess. Instead, just malloc() the refcounts in one shot from mbuf_init() o Clean up / update comments in subr_mbuf.c
* - Determine the size of buffers with sizeof() instead of usingrobert2003-02-101-7/+7
| | | | | plain magic numbers - one of them was apparently wrong but unharmful. - Remove empty line.
* o Typo/Grammar fixesmtm2003-01-143-10/+18
| | | | | | | | o Added mini-function to correctly handle singular/plural of words ending in 'ly' Approved by: markm (mentor) Not objected to by: -audit
* Warns cleanups for netstat:dwmalone2002-09-0515-195/+194
| | | | | | | | | | | 1) Include arpa/inet.h for ntohs. 2) Constness fixes. 3) Fix shadowing except for "sin" which shouldn't be in scope. 4) Remove register keyword. 5) Add missing initialsers to user defined structs. 5) Make prototype of netname6 globally visable. 6) Use right macros for printing syncache stats (even though entrie isn't a word).
* Widen struct sockbuf's sb_timeo member to int from short. Withjdp2002-07-247-9/+9
| | | | | | | | | | | | | non-default but reasonable values of hz this member overflowed, breaking NFS over UDP. Also, as long as I'm plowing up struct sockbuf ... Change certain members from u_long/long to u_int/int in order to reduce wasted space on 64-bit machines. This change was requested by Andrew Gallatin. Netstat and systat need to be rebuilt. I am incrementing __FreeBSD_version in case any ports need to change.
* Add the tcps_sndrexmitbad statistic, keep track of late acks that causeddillon2002-07-191-0/+2
| | | | unnecessary retransmissions.
* Fix incorrect cast.kbyanc2002-07-161-1/+1
|
* fixed typo.suz2002-07-031-2/+2
| | | | | obtained from: KAME MFC after: 3 days
* Use calculated column widths for the routing table display when -W iskbyanc2002-06-051-55/+208
| | | | | | | | | supplied rather than arbitrarily larger widths. This (almost) guarantees that no columns will be truncated (routing table additions between the width calculation and display passes may create a row with column widths larger than those calculated). Sponsored by: NTT Multimedia Communications Labs
* Use %lu instead of %ld when printing rt_use (aka rt_rmx.rmx_pksent)silby2002-05-311-1/+1
| | | | | Submitted by: Andre Oppermann <oppermann@pipeline.ch> MFC after: 5 days
* Cast to kill warnings. De-register.markm2002-04-281-3/+3
|
* fix warnings; change variable/argument names that mask global names.markm2002-04-281-4/+4
|
* Remove GCC-specific flags and commented out cruft.markm2002-04-281-3/+0
|
* Some easy const fixes.markm2002-04-281-3/+3
|
* Print IFT_ETHER addresses with ether_ntoa(3) (with leading zeros).ru2002-04-061-13/+6
|
* Style improvements recommended by Bruce as a follow up to somedwmalone2001-12-101-1/+1
| | | | | | | | of the recent WARNS commits. The idea is: 1) FreeBSD id tags should follow vendor tags. 2) Vendor tags should not be compiled (though copyrights probably should). 3) There should be no blank line between including cdefs and __FBSDIF.
* - Make ip_rtaddr() global, and use it to look up the correct sourceru2001-11-301-0/+5
| | | | | | | | | address in icmp_reflect(). - Two new "struct icmpstat" members: icps_badaddr and icps_noroute. PR: kern/31575 Obtained from: BSD/OS MFC after: 1 week
* Add syncache statistics to netstat.jlemon2001-11-221-0/+16
|
* Fix typo.murray2001-10-231-1/+1
| | | | | PR: docs/31388 Submitted by: Yoshihiko Sarumaru <mistral@imasy.or.jp>
* Print statistics for AF_IPX.mdodd2001-10-191-0/+2
| | | | Note that the IPX code doesn't update these correctly yet, but should.
* Fixed bugs from revision 1.27. Specifically:ru2001-10-111-9/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Restore the ability to look up network names in the networks(5) database by passing getnetbyaddr(3) shifted network numbers, but without duplicating the old bug that was fixed in 1.27 (we now only shift netnums with standard netmasks). For example: Before: $ netstat -r [...] 127.0.1/24 localhost UGSc 0 0 lo0 127.0.2/24 localhost UGSc 0 0 lo0 After: $ netstat -r [...] subnet1/24 localhost UGSc 0 0 lo0 subnet2/24 localhost UGSc 0 0 lo0 - Only try to lookup with the forged netmask if the mask was not explicitly specified, like it was before 1.27. For example: Before: $ netstat -r net-44.ampr.org/25 localhost UGSc 0 0 lo0 net-44.ampr.org/25 localhost UGSc 0 0 lo0 After: 44.108.2/25 localhost UGSc 0 0 lo0 44.108.2.128/25 localhost UGSc 0 0 lo0 - Make sure to null-terminate the resulting string. MFC after: 1 week
* The previous change also disaligned lines with AF_IPX and AF_NSru2001-10-091-10/+10
| | | | | addresses. Unshrink "Network" width to the previous value, and make sure everything is aligned again.
* Minor output formatting for 'netstat -i':mdodd2001-10-091-7/+7
| | | | | - Right align Mtu - Print AF_INET family with correct field width.
* Re-enable mbtypes statistics in the mbuf allocator. I disabled thesebmilekic2001-09-301-45/+31
| | | | | | | | | | | | | | | | | when I changed the allocator bits. This implements per-CPU mbtypes stats by keeping net number of decrements/increments of a given mbtype per-CPU and then summing all of the per-CPU mbtypes to produce the total net number of allocated mbufs of the given mbtype. Counters are carefully balanced to avoid/prevent underflows/overflows. mbtypes stats are re-enabled with the idea that we may occasionally (although very rarely) observe slight inconsistencies in the stat reporting. Most of the time, we should be fine, though. Also make appropriate modifications to netstat(1) and systat(1) to do the necessary reporting. Submitted by: Jiangyi Liu <jyliu@163.net>
* Implement the ``-f address_family'' filter for -i.ru2001-09-113-3/+14
| | | | Prodded by: Igor Podlesny <poige@morning.ru>
* Update usage() to match reality.ru2001-09-111-5/+12
|
* Yay!ru2001-09-071-236/+262
| | | | Make this manpage readable and match the reality.
* If -s -s is specified, don't show zero multicast routing statistics.ru2001-09-072-66/+48
|
* Deprecate the -l option in favour of more natural -W.ru2001-09-075-15/+11
| | | | | | | | The compatibility glue is still provided. (This change is not yet reflected in the manpage, nor in usage(). This will be fixed at a later time today, with the general manpage cleanup commit.)
* Don't print stray socket addresses (-A) with the listen queue display (-L).ru2001-09-071-23/+20
| | | | Also, print socket's protocol with the -L.
* SECURITY: Drop `setgid kmem' bit as early as possible.ru2001-08-311-0/+1
|
* -a is not an options (sic).dd2001-08-281-1/+1
|
* Mention what an asterisk means in the -i display.dd2001-08-281-0/+4
| | | | | PR: 30069 Submitted by: andrew@ugh.net.au
* Don't misuse the return from snprintf.brian2001-08-201-5/+7
| | | | MFC after: 2 weeks
* Removed duplicate VCS ID tags, as per style(9).ru2001-08-131-1/+0
|
* Add a "X KBytes of wired memory reserved" metric that representsbmilekic2001-07-311-11/+14
| | | | | | | | | approximately the amount of memory allocated from the mbuf maps and sitting in the mbuf allocator's cache containers, and display in parantheses the percentage of said memory that is actually in use at the given time `netstat -m' is executed. Suggested by: mjacob
* - Do not handle the per-CPU containers in mbuf code as though the cpuidsbmilekic2001-07-261-11/+7
| | | | | | | | | | | | | | | | | were indices in a dense array. The cpuids are a sparse set and treat them as such, setting up containers only for CPUs activated during mb_init(). - Fix netstat(1) and systat(1) to treat the per-CPU stats area as a sparse map, in accordance with the above. This allows us to properly boot with certain CPUs disactivated. However, if we later decide to re-activate said CPUs, we will barf until we decide to implement CPU spinon/spinoff callback hooks to allow for said CPUs' per-CPU containers to get configured on their activation. Reported by: mjacob Partially (sys/ diffs) Submitted by: mjacob
* Use sysctl to export multicast routing statsfenner2001-07-251-5/+13
|
* Remove whitespace at EOL.dd2001-07-151-13/+13
|
* mdoc(7) police: sort SEE ALSO xrefs (sort -b -f +2 -3 +1 -2).ru2001-07-061-1/+1
|
* Make `rttrash' variable (#routes not in table but not freed) visibleru2001-06-293-5/+17
| | | | through ``netstat -rs''.
OpenPOWER on IntegriCloud