public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
* [systemtap patch] Experimental systemtap integration of 'blktrace transport'
@ 2006-10-05 23:31 Tom Zanussi
  0 siblings, 0 replies; only message in thread
From: Tom Zanussi @ 2006-10-05 23:31 UTC (permalink / raw)
  To: systemtap; +Cc: linux-btrace

[-- Attachment #1: message body text --]
[-- Type: text/plain, Size: 1651 bytes --]

This is a patch to the 0930 systemtap snapshot that adds the ability
to have systemtap log its data using the 'blktrace transport'.  You'll
need to apply the accompanying kernel and user 'blktrace transport'
patches, then apply this to systemtap.  Once you've done that, you can
run a probe with the -l option:

# stap -l transport1.stp

The output will appear in currprobe.systemtap.X, one for each cpu,
with X replaced by the cpu id.  To get the human-readable merged
version, run stp_parse with 'currprobe' as the arg:

# stp_parse currprobe

Which will display the output to stdout.

To use in 'live mode', where the data is parsed and displayed as it
comes in, you can have stap send the output to stdout using '-o -'
option and pipe that output to stp_parse with the '-i -' option:

# stap -l -o - transport1.stp | stp_parse -i -

You can also have the per-cpu output sent over the network using the
-n option.  First start the stp_server:

# stp_server
server: waiting for connections...

Then start the trace:

# stap -l -n localhost transport1.stp
systemtap: connecting to localhost
systemtap: connected!
Trace: currprobe
  CPU  0:                    0 events,       66 KiB data
  CPU  1:                    0 events,        1 KiB data
  Total:                     0 events (dropped 0),       67 KiB data

When the trace is over, you should have a directory on the server like
this:

# cd 127.0.0.1-2006-10-06-22:41:24
# stp_parse

You can then run stp_parse on that system to display the data.

At the moment, I don't have a setup to test this over a real network
and have only tried localhost, but I wouldn't foresee any problems.

Tom





[-- Attachment #2: systemtap utt patch --]
[-- Type: application/octet-stream, Size: 29978 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2006-10-05 23:31 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-10-05 23:31 [systemtap patch] Experimental systemtap integration of 'blktrace transport' Tom Zanussi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).