All of lore.kernel.org
 help / color / mirror / Atom feed
* qemu/ftrace question
@ 2017-06-20 16:42 Prasun Ratn
  2017-06-21 11:19 ` Stefan Hajnoczi
  0 siblings, 1 reply; 5+ messages in thread
From: Prasun Ratn @ 2017-06-20 16:42 UTC (permalink / raw)
  To: kvm

Hi

I am trying to get qemu events using ftrace but not seeing any events in the
ftrace logs. I see kvm logs like the following but no qemu events such as virtio
blk events. I'm using a locally compiled qemu version with ftrace
backend enabled.

[001] d...  9290.926939: kvm_exit: reason HLT rip 0xffffffff81058e95 info 0 0

This is how I am enabling ftrace logs:

    echo 1 >/sys/kernel/debug/tracing/events/kvm/enable
    echo 1 > /sys/kernel/debug/tracing/tracing_on

    # run cmd
    $CMD

    # disable trace
    echo 0 >/sys/kernel/debug/tracing/events/kvm/enable
    echo 0 > /sys/kernel/debug/tracing/tracing_on

    # copy trace
    echo Copying trace to $outfile
    cp /sys/kernel/debug/tracing/trace $outfile

To debug, I build qemu with the 'log' backend, and I am able to see the
appropriate events in /var/log/libvirt log files.

However if I rebuild qemu with ftrace backend, I don't see any events. Do I need
to enable any other tracing events in /sys/kernel/debug/tracing? Do I need to
run any qemu monitor cmds?

Any thing obvious I may be missing? Any debug steps recommended?

I also tried using the simpletrace backend, but I am not sure where the trace
files are created. I am using libvirt and /proc for the qemu process shows the
cwd as '/' - I'm not sure what's supposed to happen here. Is it possible to
collect simpletrace traces using libvirt?

Thanks
Prasun

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2017-06-23 12:49 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-06-20 16:42 qemu/ftrace question Prasun Ratn
2017-06-21 11:19 ` Stefan Hajnoczi
2017-06-21 15:07   ` Prasun Ratn
2017-06-22  0:28     ` Prasun Ratn
2017-06-23 12:48       ` Stefan Hajnoczi

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.