PLEASE HELP regarding System Tap
Masami Hiramatsu
mhiramat@redhat.com
Mon Jul 7 20:59:00 GMT 2008
Hi,
Khushboo Goel wrote:
>>> I am using System Tap for probing kernel function so that I can know
>>> more about packet that are send over network. For this I need to
>>> open a File so that I can save all raw data. I want to save this
>>> data when I probing in the function, continuously.
>> We don't have a C stdio-like facility in systemtap yet. You can make
>> your systemtap probe handler just printf(...), which will come out at
>> the stap(run) command's stdout. You can redirect that as you like
>> (perhaps using the "-o" option). Is that sufficient?
>> ------
>
> When i use -o option, it gives me buffer overflow error, i am
> anyhow not printing anything on screen, i am using an aggregate
> variable to store all information, but i have huge data around 50K
> packets in one run ,which gives me overflow buffer , i also increased
> the stack size but if i increase the number of packets i send over the
> network, it gives me same error.
Could you try to expand your buffer and use bulk transfer mode?
you can specify buffer size for each cpu in MB by -s option(sysemtap
uses only 256KB single buffer without -s option, it's too small
for you), and use bulk transfer mode by -b option.
When you uses bulk mode, you can see raw output data in
stpd_cpu* files. these data are output per cpu, so I think
it's good for your situation.
Thank you,
--
Masami Hiramatsu
Software Engineer
Hitachi Computer Products (America) Inc.
Software Solutions Division
e-mail: mhiramat@redhat.com
More information about the Systemtap
mailing list