Re: Issue with oprofile and Virtual Machines?

Michael Petlan <[email protected]>
Newsgroups gmane.linux.oprofile
Message-ID <[email protected]>
Hi Brad and William,

> I built oprofile 1.1.0 from source on Ubuntu 12.04 (32-bit), but I’m getting
> the unsupported processor error:
> 
> 
> 
> Here are some details:
> 
> $ uname -a
> 
> Linux Ub32 3.5.0-36-generic #57~precise1-Ubuntu SMP Thu Jun 20 15:22:35 UTC
> 2013 i686 i686 i386 GNU/Linux
> 
> 
> 
> $ operf
> 
> Your kernel's Performance Events Subsystem does not support your processor
> type.
> 
> 
> 
> My underlying hardware is an Intel i7, therefore I’m suspicious that the
> problem is running Ubuntu inside a virtual machine – in this case Parallels
> on OSX.
> 
> 
> 
> Is there any guidance or documentation on how to run operf under VMs?
> 

It is always tricky. As William said, the guest needs to access the MSRs and
identify the CPU. In KVM it is possible to set up the host to share PMU with
the guest. In Parallels it should be possible as well, but I have no experience
with that...

This link shows it should be possible...
http://download.parallels.com/desktop/v9/ga/docs/en_US/Parallels%20Desktop%20User%27s%20Guide/33236.htm

But here is a question without answers, who knows...
https://forum.parallels.com/threads/anybody-uses-pmu-virtualization-on-a-linux-guest.328958/


> 
> 
> I read one suggestion to switch back to 0.9.9, but I have a couple of
> questions.
> 
> 

That is probably because you may use opcontrol with TIMER mode as a fallback
if the hardware counters fail. The legacy opcontrol mode was dropped in 1.0
and so the TIMER interrupt mode.

opcontrol --deinit
/sbin/modprobe oprofile timer=1
opcontrol --reset
opcontrol --init
opcontrol --setup --no-vmlinux ## or use vmlinux...

opcontrol --start

## run something

opcontrol --dump
opcontrol --stop

opreport

> 
> 1. Will I need to rebuild my kernel to include a kernel driver for the older
> format?

Probably no.

> 
> 2. How do I uninstall the existing 1.1.0 build that is now in my /usr folder?

Go to the oprofile dir and run `make uninstall`.

> 
> 3. Am I likely to have issues with 0.9.9 on a VM?

You should not be likely to have any other issues you don't have with 1.1.

> 
> 
> 
> 
> 
> Thanks,
> 
> Brad
> 

Michael


> 
> 
> ------------------------------------------------------------------------------
> 
> _______________________________________________
> oprofile-list mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/oprofile-list
> 

------------------------------------------------------------------------------
_______________________________________________
oprofile-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/oprofile-list
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.