lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 05 Jun 2014 06:47:37 -0700
From:	Eric Dumazet <eric.dumazet@...il.com>
To:	Stephen Hemminger <stephen@...workplumber.org>
Cc:	netdev <netdev@...r.kernel.org>
Subject: [PATCH iproute2] ss: display pacing_rate/max_pacing_rate

From: Eric Dumazet <edumazet@...gle.com>

Since linux-3.15, kernel exports tcpi_pacing_rate and
tcpi_max_pacing_rate in tcp_info

Add TCP pacing_rate information on ss -i output :

lpaa23:~# ./ss -ti dst 10.246.7.151
State      Recv-Q Send-Q   Local Address:Port       Peer Address:Port   
ESTAB      0      325800    10.246.7.151:57614
10.246.7.152:46811   
	 cubic wscale:7,7 rto:201 rtt:0.081/0.006 mss:1448 cwnd:90 ssthresh:63
send 12871.1Mbps pacing_rate 15397.8Mbps unacked:90 retrans:0/305
rcv_space:29200


If SO_MAX_PACING_RATE is set on the socket, we add /max_pacing_rate as
in :

... pacing_rate 1570.5Mbps/2.0Gbps ...

Signed-off-by: Eric Dumazet <edumazet@...gle.com>
---
 misc/ss.c |   10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/misc/ss.c b/misc/ss.c
index 187c852..c847954 100644
--- a/misc/ss.c
+++ b/misc/ss.c
@@ -1583,6 +1583,16 @@ static void tcp_show_info(const struct nlmsghdr *nlh, struct inet_diag_msg *r,
 					 / rtt));
 		}
 
+		if (info->tcpi_pacing_rate &&
+		    info->tcpi_pacing_rate != ~0ULL) {
+			printf(" pacing_rate %sbps",
+				sprint_bw(b1, info->tcpi_pacing_rate * 8.));
+
+			if (info->tcpi_max_pacing_rate &&
+			    info->tcpi_max_pacing_rate != ~0ULL)
+				printf("/%sbps",
+					sprint_bw(b1, info->tcpi_max_pacing_rate * 8.));
+		}
 		if (info->tcpi_unacked)
 			printf(" unacked:%u", info->tcpi_unacked);
 		if (info->tcpi_retrans || info->tcpi_total_retrans)


--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ