blob: 0811d860fe75000de852c569ccaaa3ae1f0aa944 [file] [log] [blame]
Paolo Bonzinifd41b5a2016-05-24 10:41:15 +02001kvm_stat(1)
2===========
3
4NAME
5----
6kvm_stat - Report KVM kernel module event counters
7
8SYNOPSIS
9--------
10[verse]
11'kvm_stat' [OPTION]...
12
13DESCRIPTION
14-----------
15kvm_stat prints counts of KVM kernel module trace events. These events signify
16state transitions such as guest mode entry and exit.
17
18This tool is useful for observing guest behavior from the host perspective.
19Often conclusions about performance or buggy behavior can be drawn from the
20output.
Stefan Raspl1eaa2f92017-03-10 13:40:07 +010021While running in regular mode, use any of the keys listed in section
22'Interactive Commands' below.
23Use batch and logging modes for scripting purposes.
Paolo Bonzinifd41b5a2016-05-24 10:41:15 +020024
25The set of KVM kernel module trace events may be specific to the kernel version
26or architecture. It is best to check the KVM kernel module source code for the
27meaning of events.
28
Stefan Raspl1eaa2f92017-03-10 13:40:07 +010029INTERACTIVE COMMANDS
30--------------------
31[horizontal]
Stefan Raspl5c1954d252017-06-25 21:34:16 +020032*b*:: toggle events by guests (debugfs only, honors filters)
33
Stefan Raspl44430842017-03-10 13:40:14 +010034*c*:: clear filter
35
Stefan Raspl1eaa2f92017-03-10 13:40:07 +010036*f*:: filter by regular expression
37
Stefan Raspl516f1192018-02-22 12:16:27 +010038*g*:: filter by guest name/PID
Stefan Rasplf9ff1082017-03-10 13:40:13 +010039
Stefan Raspl1fdea7b2017-06-07 21:08:38 +020040*h*:: display interactive commands reference
41
Stefan Raspl6667ae82017-06-07 21:08:41 +020042*o*:: toggle sorting order (Total vs CurAvg/s)
43
Stefan Raspl516f1192018-02-22 12:16:27 +010044*p*:: filter by guest name/PID
Stefan Raspl1eaa2f92017-03-10 13:40:07 +010045
46*q*:: quit
47
Stefan Raspl9f114a02017-03-10 13:40:15 +010048*r*:: reset stats
49
Stefan Raspl64eefad2017-06-07 21:08:39 +020050*s*:: set update interval
51
Stefan Raspl1eaa2f92017-03-10 13:40:07 +010052*x*:: toggle reporting of stats for child trace events
Stefan Rasplfff8c9e2017-12-11 12:25:23 +010053 :: *Note*: The stats for the parents summarize the respective child trace
54 events
Stefan Raspl1eaa2f92017-03-10 13:40:07 +010055
56Press any other key to refresh statistics immediately.
57
Paolo Bonzinifd41b5a2016-05-24 10:41:15 +020058OPTIONS
59-------
60-1::
61--once::
62--batch::
63 run in batch mode for one second
64
65-l::
66--log::
67 run in logging mode (like vmstat)
68
69-t::
70--tracepoints::
71 retrieve statistics from tracepoints
72
73-d::
74--debugfs::
75 retrieve statistics from debugfs
76
Stefan Rasplab7ef192017-06-25 21:34:15 +020077-i::
78--debugfs-include-past::
79 include all available data on past events for debugfs
80
Janosch Frankf0cf0402016-05-18 13:26:24 +020081-p<pid>::
82--pid=<pid>::
83 limit statistics to one virtual machine (pid)
84
Stefan Rasplf9ff1082017-03-10 13:40:13 +010085-g<guest>::
86--guest=<guest_name>::
87 limit statistics to one virtual machine (guest name)
88
Paolo Bonzinifd41b5a2016-05-24 10:41:15 +020089-f<fields>::
90--fields=<fields>::
Stefan Rasplf3d11b02017-12-11 12:25:24 +010091 fields to display (regex), "-f help" for a list of available events
Paolo Bonzinifd41b5a2016-05-24 10:41:15 +020092
93-h::
94--help::
95 show help message
96
97SEE ALSO
98--------
99'perf'(1), 'trace-cmd'(1)
100
101AUTHOR
102------
103Stefan Hajnoczi <stefanha@redhat.com>