summaryrefslogtreecommitdiffstats
path: root/usr.bin/netstat
Commit message (Collapse)AuthorAgeFilesLines
* Don't shadow globals.yar2006-11-273-7/+7
| | | | | Found by: WARNS=6 MFC after: 3 days
* We should return the name in cp, not printf it.yar2006-11-271-1/+3
| | | | | Found by: WARNS=6 MFC after: 3 days
* Don't always print a space character in show_stat(), since a spacebde2006-11-081-12/+23
| | | | | shouldn't be printed after the last column. This restores the formatting to 79 columns.
* Nits.bms2006-09-292-2/+2
| | | | Submitted by: ru
* Push removal of mrouted down to the rest of the tree.bms2006-09-292-2/+2
|
* Markup fixes.ru2006-09-291-6/+7
|
* Export tcps_rcvmemdrop available in 'struct tcpstat' with netstat(1).wkoszek2006-09-201-0/+1
| | | | | Requested by: Tomasz Pilat <tomasz.pilat (at) axelspringer.pl> Approved by: andre
* - Achieve WARNS=3 by using sparse initializers or avoiding initializers at all.yar2006-07-286-49/+52
| | | | | | | | - Fix a nlist initialization: it should be terminated by a NULL entry. - Constify. - Catch an unused parameter. Tested on: i386 amd64 ia64
* Achieve WARNS=2 by using uintmax_t to pass around 64-bit quantities,yar2006-07-2818-307/+321
| | | | | | | including to printf(). Using uintmax_t is also robust to further extensions in both the C language and the bitwidth of kernel counters. Tested on: i386 amd64 ia64
* Both fields of struct timeval are of a non-basic type,yar2006-07-281-6/+10
| | | | so we should cast them to a type printf() knows about.
* Avoid useless work: Do not build inet6.c if INET6 support is off.yar2006-07-281-1/+3
| | | | | This also avoids pretending that netstat includes inet6.c in the output from ident(1).
* Not having ipv6 in your kernel is not an error and should not be reported.julian2006-07-141-1/+4
| | | | MFC after: 1 week
* Since kernel & userland use different timebase and netstat is reading kerneloleg2006-07-061-3/+13
| | | | | | memory directly, we should do timebase conversion for route lifetime. Approved by: glebius (mentor)
* Reimplementation of world/kernel build options. For details, see:ru2006-03-171-2/+4
| | | | | | | | http://lists.freebsd.org/pipermail/freebsd-current/2006-March/061725.html The src.conf(5) manpage is to follow in a few days. Brought to you by: imp, jhb, kris, phk, ru (all bugs are mine)
* Improved description for packet zone statistics.andre2006-02-181-1/+1
| | | | | Sponsored by: TCP/IP Optimization Fundraise 2005 MFC after: 3 days
* Print statistics on mbuf+clusters in packet zone.andre2006-02-181-0/+4
| | | | | Sponsored by: TCP/IP Optimization Fundraise 2005 MFC after: 3 days
* Print statistics on jumbo mbuf clusters.andre2006-02-181-2/+72
| | | | | Sponsored by: TCP/IP Optimization Fundraise 2005 MFC after: 3 days
* Sort sfbuf allocation counters with other sfbuf information.rwatson2006-02-111-13/+9
| | | | MFC after: 3 days
* Un-#if 0 the printing of allocation failure counts for mbufs, clusters,rwatson2006-02-111-2/+0
| | | | | | and packets in netstat -m. MFC after: 3 days
* Add support for printing IPSEC protocol stats if the kernel was compiledkbyanc2005-12-285-97/+489
| | | | | | | | | | | | | with FAST_IPSEC rather than the KAME IPSEC stack. Note that the output of "netstat -s -p ipsec" differs depending on which stack is compiled into the kernel since they each keep different stats. This delta also adds the "esp", "ah", and "ipcomp" protocol stats, which are also available when the kernel is compiled with the FAST_IPSEC stack (e.g. "netstat -s -p esp"). Submitted by: Matt Titus <titus at nttmcl dot com> MFC after: 3 days
* Provide some basic documentation explaining what the bpf(4) flags arecsjp2005-12-181-0/+24
| | | | | supposed to mean. Also, add an external references for bpf now that we reference flags from that man page.
* Remove two lines of debugging output that accidentally snuck into therwatson2005-11-281-2/+0
| | | | commit to fix up kvm support for netstat -m.
* -mdoc sweep.ru2005-11-181-2/+3
|
* Modify netstat -mb to use libmemstat when accessing a core dump or liverwatson2005-11-133-178/+54
| | | | | | | | | | | | | | | | kernel memory and not using sysctl. Previously, libmemstat was used only for the live kernel via sysctl paths. This results in netstat output becoming both more consistent between core dumps and the live kernel, and also more information in the core dump case than previously (i.e., mbuf cache information). Statistics relating to sfbufs still rely on a kvm descriptor as they are not currently exposed via libmemstat. netstat -m operating on a core is still unable to print certain sfbuf stats available on the live kernel. MFC after: 1 week
* Align output.ru2005-11-091-2/+2
|
* Fix obvious copy'n'paste-O in rev.1.36 While here nit style.mlaier2005-10-221-3/+3
| | | | | | PR: bin/87783 Submitted by: Mats Palmgren MFC after: 1 week
* Remove bridge(4) from the tree. if_bridge(4) is a full functionalmlaier2005-09-274-51/+2
| | | | | | | | replacement and has additional features which make it superior. Discussed on: -arch Reviewed by: thompsa X-MFC-after: never (RELENG_6 as transition period)
* - Print space character in show_stat(). Remove a lot of priuntf(" ").glebius2005-09-271-37/+29
| | | | | - Utilize show_stat() in sidewaysintpr() loop. This makes periodic statistics to honor -h flag.
* Use is '-' to imply that the flag is not set, rather than '.'.csjp2005-09-151-1/+1
|
* Print a warning if we fail to retrieve the process name for any reason.csjp2005-09-131-1/+3
|
* If there are'nt any bpf descriptors to process than dont bother attempting tocsjp2005-09-131-0/+2
| | | | | | retrieve statistic information for them. Pointed out by: Pawel Worach < pawel.worach at gmail.com >
* Free the bpf descriptor array after we are done with it. This probably isntcsjp2005-09-071-0/+1
| | | | | that critical as the program exits after this point anyway, but this may not always be the case.
* Update usage to reflect the new option.csjp2005-09-071-1/+2
| | | | Pointed out by: ru
* Merge bpfstat's functionality into the netstat(1) utility. This addscsjp2005-09-075-3/+144
| | | | | | | | | | | | | | | | | | | | | | | | | | | a -B option which causes bpf peers to be printed. This option can be used in conjunction with -I if information about specific interfaces is desired. This is similar to what NetBSD added to their version of netstat. $ netstat -B Pid Netif Flags Recv Drop Match Sblen Hblen Command 1137 lo0 p--s-- 0 0 0 0 0 tcpdump 205 sis0 -ifs-l 37331 0 1 0 0 dhclient $ $ netstat -I lo0 -B Pid Netif Flags Recv Drop Match Sblen Hblen Command 1174 lo0 p--s-- 0 0 0 0 0 tcpdump $ -Add bpf.c which stores all the code for retrieving and parsing bpf related statistics. -Modify main.c to add support for the -B option and hook it into the program logic. -Add bpf.c to the build. -Document this new functionality in the man page and bump the revision date. -Add prototype for bpf_stats function.
* List -W as one of the meaningful options to the -i (interfaces)yar2005-08-241-1/+1
| | | | | | display of netstat(1). MFC after: 3 days
* Bail if interface is misspelled instead of falling out into theru2005-08-201-0/+2
| | | | | "all interfaces" mode. (Only works with -w, but still better than nothing.)
* Add a new switch -h for interface stats mode, which prints all interfaceglebius2005-08-184-10/+29
| | | | | | | statistics in human readable form. In collaboration with: vsevolod Reviewed by: cperciva
* Don't include -lipx twice.phk2005-08-051-2/+2
|
* Make IPX support depend on NO_IPXphk2005-08-052-2/+16
|
* Since libmemstat(3) now supports its own error management mechanism,rwatson2005-07-241-1/+2
| | | | | | | use that instead of trying to use errno, in order to produce a sensible error message. MFC after: 1 day
* Modify "netstat -mb" to use libmemstat(3) when acting on a live system,rwatson2005-07-182-36/+197
| | | | | | | | | | | | | | | | | | | | | | | | with a number of positive benefits: - Start using UMA(9) statistics for mbufs and clusters, which avoids using the mbuf allocator statistics which suffer from races under load on SMP. This should eliminate "negative" mbuf counts in netstat -mb. - We are now able to track cached (free) mbufs and clusters and count it towards memory allocated by the network stack. - We are now also able to track memory allocated to mbuf tags since libmemstat(3) can also query malloc(9). We don't print this except as part of the total (for now - #if 0). - We are now able to track mbuf/cluster/packet allocation failures, although they are not currently printed (#if 0). - Don't print out sfbuf statistics when running on a kernel core, as currently that code is able only to query sysctl for statistics. MFC after: 1 week
* Print newly exported pfsync statistics with netstat(8).mlaier2005-07-143-1/+52
| | | | | Requested by: glebius MFC after: 1 week
* NI_WITHSCOPEID cleanup. Neither RFC 2553 nor RFC 3493 definesume2005-05-131-2/+2
| | | | | NI_WITHSCOPEID, and our getaddrinfo(3) does nothing special for it, now.
* Silence a warning on systems without carp(4).ru2005-04-121-1/+2
|
* Add limits on the number of elements in the sack scoreboard bothps2005-03-091-0/+1
| | | | | | | | per-connection and globally. This eliminates potential DoS attacks where SACK scoreboard elements tie up too much memory. Submitted by: Raja Mukerji (raja at moselle dot com). Reviewed by: Mohan Srinivasan (mohans at yahoo-inc dot com).
* Add CARP (Common Address Redundancy Protocol), which allows multipleglebius2005-02-223-0/+50
| | | | | | | | | | | | | hosts to share an IP address, providing high availability and load balancing. Original work on CARP done by Michael Shalayeff, with many additions by Marco Pfatschbacher and Ryan McBride. FreeBSD port done solely by Max Laier. Patch by: mlaier Obtained from: OpenBSD (mickey, mcbride)
* According to style.Makefile(5):delphij2005-01-231-2/+4
| | | | | | WARNS?= should appear before CFLAGS Reviewed by: ru
* Make sure that we don't define INET6 when NO_INET6 is defined.delphij2005-01-221-0/+2
| | | | | | | | Without this change, when running netstat with a kernel without INET6 built in, you will get a complain at the end of "netstat -s" output. X-MFC: NO_INET6 was called "NOINET6" on RELENG_5
* evise use of queue(9) macros for netipx when used from userspace:rwatson2005-01-021-11/+5
| | | | LIST_FOREACH() is difficult to use correctly, so don't try to.
* Apply a simplifying patch submitted by rik to the IPX support inrwatson2004-12-311-34/+14
| | | | | | | | | | | netstat(1): - Make previously unnecessarily global variables local. - Use LIST_FOREACH() in preference to manual iteration. - Restore a sanity check through slightly incestuous use of queue macro knowledge. Submitted by: rik
OpenPOWER on IntegriCloud