perf stat to collect the performance statistics of KVM process
Dear all,
I am running perf stat to collect the performance statistics of the already running KVM guest VM process. And I have a shell script to execute the perf stat as a daemon process. But when I use the 'kill' command to stop the perf stat, there is no output redirected to a file. What I would like to do is that to collect performance counters of the guest VM process for a certain period and redirect the output to a log file, but without user interaction (such as using CTRL + C to stop the perf stat)
[root@dell06 ~]# (perf stat -p 7473 -x ,) 2> perftest &
[1] 15086
[root@dell06 ~]# kill 15086
[root@dell06 ~]#
[1]+ Terminated ( perf stat -p 7473 -x , ) 2> perftest
[root@dell06 ~]# cat perftest
[root@dell06 ~]#
Any clue?
Best Regards
Hailong
Quoted 18 lines · Hailong Yang
Dear all,
I am running perf stat to collect the performance statistics of the already running KVM guest VM process. And I have a shell script to execute the perf stat as a daemon process. But when I use the 'kill' command to stop the perf stat, there is no output redirected to a file. What I would like to do is that to collect performance counters of the guest VM process for a certain period and redirect the output to a log file, but without user interaction (such as using CTRL + C to stop the perf stat)
[root@dell06 ~]# (perf stat -p 7473 -x ,) 2> perftest&
[1] 15086
[root@dell06 ~]# kill 15086
[root@dell06 ~]#
[1]+ Terminated ( perf stat -p 7473 -x , ) 2> perftest
[root@dell06 ~]# cat perftest
[root@dell06 ~]#
Quoted 1 line
Any clue?
Can you please try "kill -s INT <pid>"
Quoted 5 lines
Best Regards
Hailong
-Andrew Theurer