On 5/26/20 3:40 AM, Tuong Lien wrote: > This commit allows printing the statistics of a broadcast-receiver link > using the same tipc command, but with additional 'link' options: > > $ tipc link stat show --help > Usage: tipc link stat show [ link { LINK | SUBSTRING | all } ] > > With: > + 'LINK' : print the stats of the specific link 'LINK'; > + 'SUBSTRING' : print the stats of all the links having the 'SUBSTRING' > in name; > + 'all' : print all the links' stats incl. the broadcast-receiver > ones; > > Also, a link stats can be reset in the usual way by specifying the link > name in command. > > For example: > > $ tipc l st sh l br > Link <broadcast-link> > Window:50 packets > RX packets:0 fragments:0/0 bundles:0/0 > TX packets:5011125 fragments:4968774/149643 bundles:38402/307061 > RX naks:781484 defs:0 dups:0 > TX naks:0 acks:0 retrans:330259 > Congestion link:50657 Send queue max:0 avg:0 > > Link <broadcast-link:1001001> > Window:50 packets > RX packets:95146 fragments:95040/1980 bundles:1/2 > TX packets:0 fragments:0/0 bundles:0/0 > RX naks:380938 defs:83962 dups:403 > TX naks:8362 acks:0 retrans:170662 > Congestion link:0 Send queue max:0 avg:0 > > Link <broadcast-link:1001002> > Window:50 packets > RX packets:0 fragments:0/0 bundles:0/0 > TX packets:0 fragments:0/0 bundles:0/0 > RX naks:400546 defs:0 dups:0 > TX naks:0 acks:0 retrans:159597 > Congestion link:0 Send queue max:0 avg:0 > > $ tipc l st sh l 1001002 > Link <1001003:data0-1001002:data0> > ACTIVE MTU:1500 Priority:10 Tolerance:1500 ms Window:50 packets > RX packets:99546 fragments:0/0 bundles:33/877 > TX packets:629 fragments:0/0 bundles:35/828 > TX profile sample:8 packets average:390 octets > 0-64:75% -256:0% -1024:0% -4096:25% -16384:0% -32768:0% -66000:0% > RX states:488714 probes:7397 naks:0 defs:4 dups:5 > TX states:27734 probes:18016 naks:5 acks:2305 retrans:0 > Congestion link:0 Send queue max:0 avg:0 > > Link <broadcast-link:1001002> > Window:50 packets > RX packets:0 fragments:0/0 bundles:0/0 > TX packets:0 fragments:0/0 bundles:0/0 > RX naks:400546 defs:0 dups:0 > TX naks:0 acks:0 retrans:159597 > Congestion link:0 Send queue max:0 avg:0 > > $ tipc l st re l broadcast-link:1001002 > > $ tipc l st sh l broadcast-link:1001002 > Link <broadcast-link:1001002> > Window:50 packets > RX packets:0 fragments:0/0 bundles:0/0 > TX packets:0 fragments:0/0 bundles:0/0 > RX naks:0 defs:0 dups:0 > TX naks:0 acks:0 retrans:0 > Congestion link:0 Send queue max:0 avg:0 > > Acked-by: Ying Xue <ying....@windriver.com> > Acked-by: Jon Maloy <jma...@redhat.com> > Signed-off-by: Tuong Lien <tuong.t.l...@dektech.com.au> > --- > tipc/link.c | 25 +++++++++++++++++-------- > 1 file changed, 17 insertions(+), 8 deletions(-) >
Applied to iproute2-next. Thanks for the examples in the commit message.