History log of /freebsd/usr.bin/netstat/route.c (Results 226 – 250 of 310)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: release/6.3.0_cvs, release/6.3.0
# a3ab9923 10-Jan-2008 Andrew Thompson <thompsa@FreeBSD.org>

Add IFT_BRIDGE to the Ethernet section so l2 addresses are formatted correctly.

PR: bin/119542
Submitted by: Niki Denev


# 7627e004 10-Jan-2008 Sam Leffler <sam@FreeBSD.org>

quiet compiler complaint about unused parameters


# 65475bc8 03-Jan-2008 David E. O'Brien <obrien@FreeBSD.org>

style(9)
+ kread is not a boolean, so check it as such
+ fix $FreeBSD$ Ids
+ denote copyrights with /*-
+ misc whitespace changes.


# feda1a43 16-Jul-2007 John Baldwin <jhb@FreeBSD.org>

Restore netstat -M functionality for most statistics on core dumps. In
general, when support was added to netstat for fetching data using sysctl,
no provision was left for fetching equivalent data f

Restore netstat -M functionality for most statistics on core dumps. In
general, when support was added to netstat for fetching data using sysctl,
no provision was left for fetching equivalent data from a core dump, and
in fact, netstat would _always_ fetch data from the live kernel using
sysctl even when -M was specified resulting in the user believing they
were getting data from coredumps when they actually weren't. Some specific
changes:
- Add a global 'live' variable that is true if netstat is running against
the live kernel and false if -M has been specified.
- Stop abusing the sysctl flag in the protocol tables to hold the protocol
number. Instead, the protocol is now its own field in the tables, and
it is passed as a separate parameter to the PCB and stat routines rather
than overloading the KVM offset parameter.
- Don't run PCB or stats functions who don't have a namelist offset if we
are being run against a crash dump (!live).
- For the inet and unix PCB routines, we generate the same buffer from KVM
that the sysctl usually generates complete with the header and trailer.
- Don't run bpf stats for !live (before it would just silently always run
live).
- kread() no longer trashes memory when opening the buffer if there is an
error on open and the passed in buffer is smaller than _POSIX2_LINE_MAX.
- The multicast routing code doesn't fallback to kvm on live kernels if
the sysctl fails. Keeping this made the code rather hairy, and netstat
is already tied to the kernel ABI anyway (even when using sysctl's since
things like xinpcb contain an inpcb) so any kernels this is run against
that have the multicast routing stuff should have the sysctls.
- Don't try to dig around in the kernel linker in the netgraph PCB routine
for core dumps.

Other notes:
- sctp's PCB routine only works on live kernels, it looked rather
complicated to generate all the same stuff via KVM. Someone can always
add it later if desired though.
- Fix the ipsec removal bug where N_xxx for IPSEC stats weren't renumbered.
- Use sysctlbyname() everywhere rather than hardcoded mib values.

MFC after: 1 week
Approved by: re (rwatson)

show more ...


# d092c06c 14-Feb-2007 Bruce M Simpson <bms@FreeBSD.org>

Retire most of the classful network behaviour of netstat -r output, for IPv4.

Without -n, we now only print a "network name" without the prefix length
under the following conditions:
1) the netw

Retire most of the classful network behaviour of netstat -r output, for IPv4.

Without -n, we now only print a "network name" without the prefix length
under the following conditions:
1) the network address and mask matches a classful network prefix;
2) getnetbyaddr(3) returns a network name for this network address.

With -n, we unconditionally print the full unabbreviated CIDR network
prefix in the form "a.b.c.d/p". 0.0.0.0/0 is still printed as "default".

This change is in preparation for changes such as equal-cost multipath, and
to more generally assist operational deployment of FreeBSD as a modern IPv4
router. There are currently no plans to backport this change.

Discussed on: freebsd-net

show more ...


Revision tags: release/6.2.0_cvs, release/6.2.0
# da67074e 27-Nov-2006 Yaroslav Tykhiy <ytykhiy@gmail.com>

We should return the name in cp, not printf it.

Found by: WARNS=6
MFC after: 3 days


# 096146f8 28-Jul-2006 Yaroslav Tykhiy <ytykhiy@gmail.com>

- Achieve WARNS=3 by using sparse initializers or avoiding initializers at all.
- Fix a nlist initialization: it should be terminated by a NULL entry.
- Constify.
- Catch an unused parameter.

Tested

- Achieve WARNS=3 by using sparse initializers or avoiding initializers at all.
- Fix a nlist initialization: it should be terminated by a NULL entry.
- Constify.
- Catch an unused parameter.

Tested on: i386 amd64 ia64

show more ...


# 7b95a1eb 28-Jul-2006 Yaroslav Tykhiy <ytykhiy@gmail.com>

Achieve WARNS=2 by using uintmax_t to pass around 64-bit quantities,
including to printf(). Using uintmax_t is also robust to further
extensions in both the C language and the bitwidth of kernel cou

Achieve WARNS=2 by using uintmax_t to pass around 64-bit quantities,
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

show more ...


# 7c7f48f1 06-Jul-2006 Oleg Bulyzhin <oleg@FreeBSD.org>

Since kernel & userland use different timebase and netstat is reading kernel
memory directly, we should do timebase conversion for route lifetime.

Approved by: glebius (mentor)


Revision tags: release/5.5.0_cvs, release/5.5.0, release/6.1.0_cvs, release/6.1.0, release/6.0.0_cvs, release/6.0.0
# 4f101318 13-May-2005 Hajimu UMEMOTO <ume@FreeBSD.org>

NI_WITHSCOPEID cleanup. Neither RFC 2553 nor RFC 3493 defines
NI_WITHSCOPEID, and our getaddrinfo(3) does nothing special
for it, now.


Revision tags: release/5.4.0_cvs, release/5.4.0, release/4.11.0_cvs, release/4.11.0, release/5.3.0_cvs, release/5.3.0
# 77ef8a97 28-Jul-2004 Gleb Smirnoff <glebius@FreeBSD.org>

Print link level address on vlan interfaces using ether_ntoa(), to make
output on bare ethernet and vlan interfaces the same.

PR: bin/69674
Submitted by: Pawel Malachowski <pawmal-posting@freebsd.l

Print link level address on vlan interfaces using ether_ntoa(), to make
output on bare ethernet and vlan interfaces the same.

PR: bin/69674
Submitted by: Pawel Malachowski <pawmal-posting@freebsd.lublin.pl>
Reviewed by: ru
Approved by: julian (mentor)
MFC after: 1 week

show more ...


# 6cc6f122 26-Jul-2004 Philippe Charnier <charnier@FreeBSD.org>

Add __FBSDID. Replace local variable sin by sockin to not conflict with sin(3).
Use warnx() instead of warn() when error message is not of any interest. Add
prototypes.


Revision tags: release/4.10.0_cvs, release/4.10.0
# 0b46c085 13-Apr-2004 Luigi Rizzo <luigi@FreeBSD.org>

Replace ROUNDUP/ADVANCE with SA_SIZE


Revision tags: release/5.2.1_cvs, release/5.2.1, release/5.2.0_cvs, release/5.2.0
# 25d295e1 28-Nov-2003 Bruce M Simpson <bms@FreeBSD.org>

Fix some minor nits in netstat whereby large interface names would be
truncated. In environments where many tunnel or vlan interfaces are created,
interface names have high numbers which overflow the

Fix some minor nits in netstat whereby large interface names would be
truncated. In environments where many tunnel or vlan interfaces are created,
interface names have high numbers which overflow the field width.

PRs: bin/52349, bin/35838
Submitted by: Mike Tancsa, Scot W. Hetzel
Approved by: re (rwatson)

show more ...


# 9bf40ede 31-Oct-2003 Brooks Davis <brooks@FreeBSD.org>

Replace the if_name and if_unit members of struct ifnet with new members
if_xname, if_dname, and if_dunit. if_xname is the name of the interface
and if_dname/unit are the driver name and instance.

T

Replace the if_name and if_unit members of struct ifnet with new members
if_xname, if_dname, and if_dunit. if_xname is the name of the interface
and if_dname/unit are the driver name and instance.

This change paves the way for interface renaming and enhanced pseudo
device creation and configuration symantics.

Approved By: re (in principle)
Reviewed By: njl, imp
Tested On: i386, amd64, sparc64
Obtained From: NetBSD (if_xname)

show more ...


Revision tags: release/4.9.0_cvs, release/4.9.0
# 8145952f 03-Oct-2003 Sam Leffler <sam@FreeBSD.org>

remove unneeded include of route.h

Supported by: FreeBSD Foundation


Revision tags: release/5.1.0_cvs, release/5.1.0, release/4.8.0_cvs, release/4.8.0
# ab54ea99 05-Mar-2003 Peter Wemm <peter@FreeBSD.org>

Kill #ifdef NS and some leftover #ifdef ISO code. Re-pack the nlist[]
array, it isn't likely to find any ARPAnet IMP drivers in FreeBSD.


Revision tags: release/5.0.0_cvs, release/5.0.0, release/4.7.0_cvs
# a01e3379 05-Sep-2002 David Malone <dwmalone@FreeBSD.org>

Warns cleanups for netstat:
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

Warns cleanups for netstat:
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).

show more ...


Revision tags: release/4.6.2_cvs, release/4.6.2, release/4.6.1
# 9f8df4b4 16-Jul-2002 Kelly Yancey <kbyanc@FreeBSD.org>

Fix incorrect cast.


Revision tags: release/4.6.0_cvs
# ab675913 05-Jun-2002 Kelly Yancey <kbyanc@FreeBSD.org>

Use calculated column widths for the routing table display when -W is
supplied rather than arbitrarily larger widths. This (almost) guarantees
that no columns will be truncated (routing table additi

Use calculated column widths for the routing table display when -W is
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

show more ...


# acc52a9a 31-May-2002 Mike Silbersack <silby@FreeBSD.org>

Use %lu instead of %ld when printing rt_use (aka rt_rmx.rmx_pksent)

Submitted by: Andre Oppermann <oppermann@pipeline.ch>
MFC after: 5 days


# ad3253f2 06-Apr-2002 Ruslan Ermilov <ru@FreeBSD.org>

Print IFT_ETHER addresses with ether_ntoa(3) (with leading zeros).


Revision tags: release/4.5.0_cvs, release/4.4.0_cvs
# 146db49f 11-Oct-2001 Ruslan Ermilov <ru@FreeBSD.org>

Fixed bugs from revision 1.27. Specifically:

- Restore the ability to look up network names in the networks(5)
database by passing getnetbyaddr(3) shifted network numbers,
but without duplicati

Fixed bugs from revision 1.27. Specifically:

- 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

show more ...


# 70057abf 07-Sep-2001 Ruslan Ermilov <ru@FreeBSD.org>

Deprecate the -l option in favour of more natural -W.
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

Deprecate the -l option in favour of more natural -W.
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.)

show more ...


# 1093cc31 29-Jun-2001 Ruslan Ermilov <ru@FreeBSD.org>

Make `rttrash' variable (#routes not in table but not freed) visible
through ``netstat -rs''.


12345678910>>...13