On Wed, 2021-02-10 at 16:59 -0500, Steven Rostedt wrote: > On Tue, 09 Feb 2021 13:24:23 +0100 > Dario Faggioli <dfaggioli@xxxxxxxx> wrote: > > > > == VM: > > # echo tsc > > > /sys/devices/system/clocksource/clocksource0/current_clocksource > > # echo x86-tsc > /sys/kernel/tracing/trace_clock > > # trace-cmd agent > > > > == Host: > > # echo x86-tsc > /sys/kernel/tracing/trace_clock > > # trace-cmd record -p nop -e sched:* -e kvm:* -e timer:hrtimer* -A > > tumbleweed-jeos:823 -e sched:* -e syscalls:*_clock_nanosleep -e > > timer:hrtimer* sleep 1 > > > > Note you can use -C x86-tsc on the command line which would handle > the > clocks for you. I believe it may update the agent as well, but if > not, you > can add it to the agent as well. Also "-p nop" shouldn't be needed, > as that > would happen automatically if "-p" is left off. > > trace-cmd record -e sched -e kvm -e 'hrtimer*' -C x86-tsc \ > -A tumbleweed-jeos:823 -e sched -e '*_clock_nanosleep' -e > 'hrtimer*' \ > sleep 1 > Right. That's better indeed. > > And I do end up with the two files: trace.dat for the host and > > trace- > > (null).dat (oh, well :-D) for the guest. > > I believe my latest push should fix that ;-) > Yes, 27c464a74f8f54d0 (trace-cmd: Use instance->name for guests and not tracefs instance name) fixes this for me. I was also trying to do some debugging, out of curiosity. And in fact I was not understanding where the name was being copied in the place where tracefs_instance_get_name() looks for it. :-) Thanks! -- Dario Faggioli, Ph.D http://about.me/dario.faggioli Virtualization Software Engineer SUSE Labs, SUSE https://www.suse.com/ ------------------------------------------------------------------- <<This happens because _I_ choose it to happen!>> (Raistlin Majere)
Attachment:
signature.asc
Description: This is a digitally signed message part