Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 30 Apr 2015 13:58:48 +0100
From:      "George Neville-Neil" <gnn@neville-neil.com>
To:        net@freebsd.org
Subject:   SIFTR and DTrace
Message-ID:  <CD29C19D-6076-4363-862A-7BA83E7C9B90@neville-neil.com>

next in thread | raw e-mail | index | archive | help
Howdy,

I have added support for a DTrace SDT to the SIFTR module in HEAD.  What 
this means is that you can
now get SIFTR data filtered out of the kernel directly.  I also added a 
simple script (share/dtrace/siftr) to
show how this works.  The test script is very wordy and only an example 
of how to use this.
In order to use SIFTR with DTrace either load the modules, dtraceall and 
siftr, or compile them
into the kernel.  Here is some example output:

sudo ./siftr
direction in state state-established local 22 remote 55907
snd_cwnd 22978 snd_wnd 131008 rcv_wnd 66608 snd_bwnd 0 snd_ssthresh 
1073725440
	max_seg_size 1448 smoothed_rtt 11 sack_enabled 1
	snd_scale 5 rcv_scale 6 flags 0x3e4 rxt_length 230
	snd_buf_hiwater 33304 snd_buf_cc 0 rcv_buf_hiwater 66608
	rcv_buf_cc 0 sent_inflight_bytes 0 t_segqlen 0
	flowid 0 flowtype 0

Using a DTrace predicate you can select a particular flow based on, for 
instance, the local and
remote ports.  I have not put in the IP address reporting as yet nor 
have I added the ability
to pull out the timeval recorded by SIFTR.  Since the trace point is in 
the code where the
trace is taken it is possible to use DTrace timestamps natively.

Best,
George



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CD29C19D-6076-4363-862A-7BA83E7C9B90>