Make use of the stats(3) framework in the TCP stack.
This makes it possible to retrieve per-connection statistical
per-connection statistical information such as the receive window size, RTT, or goodput,
using a newly added TCP_STATS getsockopt(3) option, and extract it usingthem
using the stats_voistat_fetch(3) API.
See the net/tcprtt port for an example consumer of this API.
Compared to the existing TCP_INFO system, the main differences are that
of this APIthis mechanism is easy to extend without breaking ABI, and provides
statistical information instead of raw "snapshots" of values at a given
point in time. stats(3) is more generic and can be used in both
userland and the kernel.
Compared to the existing TCP_INFO, This work depends on:
the main differences are that thisstats(3) framework:
mechanism is easy to extend without breaking ABI, and it provides statisticalhttps://reviews.freebsd.org/D20477
The qmath(3) macros:
information instead of raw "snapshots" of values at a given point of time.https://reviews.freebsd.org/D20116
This depends on https://reviews.freebsd.org/D20477, and the Array-base Red Black Tree implementation:
https://reviews.freebsd.org/D20116, and https://reviews.freebsd.org/D20324. Example tool using it is here: https://reviews.freebsd.org/D20656.324
An example consumer tool for using these TCP stats is here:
Sponsored By: Klara Inc, Netflix
Obtained from: Netflix