在虚拟机中运行的Linux上的oprofile
我正在使用VirtualBox运行Linux Ubuntu 10.4 VM。我正在尝试使用oprofile来配置虚拟机中的某些应用程序。我已经安装了oprofile 0.9.6,但我无法让它工作。当我尝试启动时,我收到以下错误:
opcontrol --start
/usr/local/bin/opcontrol: line 323: /usr/local/bin/ophelp: cannot execute binary file
/usr/local/bin/opcontrol: line 1483: /usr/local/bin/oprofiled: cannot execute binary file
Couldn't start oprofiled.
Check the log file "/var/lib/oprofile/samples/oprofiled.log" and kernel syslog
因为我不确定VirtualBox是否可以提供对性能计数器的访问(我在这里有疑问,所以如果你有任何指针它会很棒)我将oprofile默认为定时器中断,如下所示:
opcontrol --deinit
/usr/local/bin/opcontrol: line 323: /usr/local/bin/ophelp: cannot execute binary file
Unloading oprofile module
root@dev-ubuntu-10:/usr/local/bin# /sbin/modprobe oprofile timer=1
root@dev-ubuntu-10:/usr/local/bin# opcontrol --init
但仍然没有工作,我得到同样的错误。甚至可以在VM中运行oprofile吗?
谢谢
没有找到相关结果
已邀请:
5 个回复
好按紊叉
缉康怪
通常意味着您尝试在32位内核上执行
二进制文件。
和
打印什么?
嗓瑰
绊伦欧
然后尝试使用它工作正常您可能想要打开VMWARE中的虚拟CPU计数器并禁用Linux中的nmi_watchdog寄存器,因为它们可能被其他分析器使用。
仿普
架构性能监控功能(0xa / edx): 固定计数器的数量= 0x0(0) 固定计数器的位宽= 0x0(0) 似乎只有Vmware和KVM可以模拟PMU单元,而不是VBOX