All of lore.kernel.org
 help / color / mirror / Atom feed
* RE: Compiling xenoprof
@ 2006-04-05 15:54 Santos, Jose Renato G
  2006-04-05 16:19 ` David Carr
  2006-04-05 16:54 ` Chris Wright
  0 siblings, 2 replies; 8+ messages in thread
From: Santos, Jose Renato G @ 2006-04-05 15:54 UTC (permalink / raw)
  To: David Carr, xen-devel

 
David,

You are right. This is not very clean.
Yes, you need to do a "make" to create the xen0 and xenU trees
before applying the patch in step c).
If you configure the kernel with oprofile support (CONFIG_OPROFILE)
before step c) you will probably get a compilation error when 
you run make since the patch was not applied yet. You could either delay
setting (CONFIG_OPROFILE) for after you apply patch "c" or you
can apply the patch after you get the compilation error, and then
run make again.

It would be better if there was a "make" option to create the
xen0/xenU trees without compiling them. Does anybody know if 
there is such an option? I remember looking for it in the Makefile
and not finding it, but this was a while ago.

We are now working on getting the xenoprof code included in
xen-unstable.
This should make life much easier for those wanting to use oprofile.

Renato   

>> -----Original Message-----
>> From: xen-devel-bounces@lists.xensource.com 
>> [mailto:xen-devel-bounces@lists.xensource.com] On Behalf Of 
>> David Carr
>> Sent: Tuesday, April 04, 2006 7:31 PM
>> To: xen-devel@lists.xensource.com
>> Subject: [Xen-devel] Compiling xenoprof
>> 
>> I'm having some trouble compiling Xen 3.0.0 with the 
>> xenoprof patches.
>> 
>> The xenoprof instructions say:
>> 
>>   In order to run OProfile in Xen environments four patches 
>> are needed:
>>   a) xenoprof-2.0-xen-3.0.0.patch
>>      Patch for Xen hypervisor.
>>   b) xenoprof-2.0-linux-2.6-sparse.patch
>>      Patch for Xenolinux. Contains oprofile architecture 
>> specific driver 
>>      for xen (Apply to linux-sparse tree in Xen source tree)
>>   c) xenoprof-2.0-linux-2.6.12.patch
>>      Patch for oprofile kernel module in linux 2.6.12. 
>> Contain modifications
>>      to generic oprofile driver code to support xen. (Apply 
>> twice, once to 
>>      dom0 and once to domU trees)
>>  
>> 
>> Every thing goes fine until part c.  The linux-2.6.12-xen0 
>> and linux-2.6.12-xenU directories are empty until you build 
>> xen (and therefore can't be patched yet.)  Doing a make 
>> world will populate these trees but also compiles everything.
>> 
>> What is the proper sequence of patching and make commands to 
>> build a xenoprof tree?
>> 
>> Thanks,
>> David Carr
>> 
>> 
>> 
>> _______________________________________________
>> Xen-devel mailing list
>> Xen-devel@lists.xensource.com
>> http://lists.xensource.com/xen-devel
>> 

^ permalink raw reply	[flat|nested] 8+ messages in thread
* RE: Compiling xenoprof
@ 2006-04-05 17:18 Santos, Jose Renato G
  0 siblings, 0 replies; 8+ messages in thread
From: Santos, Jose Renato G @ 2006-04-05 17:18 UTC (permalink / raw)
  To: David Carr; +Cc: xen-devel

 

>> -----Original Message-----
>> From: David Carr [mailto:dc@dcarr.org] 
>> Sent: Wednesday, April 05, 2006 10:10 AM
>> To: Santos, Jose Renato G; xen-devel@lists.xensource.com
>> Subject: Re: [Xen-devel] Compiling xenoprof
>> 
>> Renato,
>> 
>> I should have been more specific.  The sequence of commands 
>> from the guide that I use is below:
>> 
>> On dom0:
>> [start guests]
>> opcontrol --reset
>> 
>> opcontrol --no-vmlinux
>> 
>> xm list
>> Name                              ID Mem(MiB) VCPUs State  Time(s)
>> Domain-0                           0      256     1 r-----   242.4
>> guest_0                           11      128     1 -b----    11.7
>> guest_1                           12      128     1 -b----    11.8
>> 
>> sudo opcontrol --start-daemon --active-domains=guest_0,guest_1
>> 

You should use domain ids and not domain names, i.e
--active-domains=11,12
I think it would be nice to have support for using domain names, but
It is not supported yet

Renato

^ permalink raw reply	[flat|nested] 8+ messages in thread
* RE: Compiling xenoprof
@ 2006-04-05 17:06 Santos, Jose Renato G
  0 siblings, 0 replies; 8+ messages in thread
From: Santos, Jose Renato G @ 2006-04-05 17:06 UTC (permalink / raw)
  To: Chris Wright; +Cc: David Carr, xen-devel

 

>> -----Original Message-----
>> From: Chris Wright [mailto:chrisw@sous-sol.org] 
>> Sent: Wednesday, April 05, 2006 9:55 AM
>> To: Santos, Jose Renato G
>> Cc: David Carr; xen-devel@lists.xensource.com
>> Subject: Re: [Xen-devel] Compiling xenoprof
>> 
>> * Santos, Jose Renato G (joserenato.santos@hp.com) wrote:
>> > It would be better if there was a "make" option to create the 
>> > xen0/xenU trees without compiling them. Does anybody know 
>> if there is 
>> > such an option?
>> 
>> make prep-kernels
>> 

  Great. This will  be very usefull. Thanks

>> > We are now working on getting the xenoprof code included in 
>> > xen-unstable.
>> > This should make life much easier for those wanting to use 
>> oprofile.
>> 
>> Great, thanks.  Does the patch to oprofile itself have a 
>> chance to get upstream as well?
>>

   Yes that is the plan. The feedback I received is that 
   oprofile patches to support Xen are unlikely to be 
   accepted until Xen makes upstream. The plan then is to wait
   for that.

   Renato

>> thanks,
>> -chris
>> 

^ permalink raw reply	[flat|nested] 8+ messages in thread
* RE: Compiling xenoprof
@ 2006-04-05 16:30 Santos, Jose Renato G
  2006-04-05 17:09 ` David Carr
  0 siblings, 1 reply; 8+ messages in thread
From: Santos, Jose Renato G @ 2006-04-05 16:30 UTC (permalink / raw)
  To: David Carr; +Cc: xen-devel


David,

You are not able to run oprofile on domU only.
The current model supported for XenOProfile is system-wide
profiling, i.e. profiling multiple domains, using the same
hardware counters. In this model
Dom0 has to be the coordinator of a profiling session.
You have to first start oprofile daemon in dom0 indicating which
domains are participating in the profiling session. Then you
need to run "opcontrol --start" in each domU, and finally
start profiling from dom0 (opcontrol --start).
Look at the user guide in http://xenoprof.sourceforge.net
for more details

Renato 

>> -----Original Message-----
>> From: David Carr [mailto:dc@dcarr.org] 
>> Sent: Wednesday, April 05, 2006 9:20 AM
>> To: Santos, Jose Renato G
>> Cc: xen-devel@lists.xensource.com
>> Subject: Re: [Xen-devel] Compiling xenoprof
>> 
>> Renato,
>> 
>> Thanks for your reply.  The steps below got the kernels to 
>> build.  I'm not sure that everything is quite right yet 
>> though.  I can profile on domain 0 and also run opcontrol 
>> --reset on the guests.  However running "opcontrol --start" 
>> on the guests results in:
>> 
>> Using default event: GLOBAL_POWER_EVENTS:100000:1:1:1 Failed 
>> to open profile device: Operation not permitted Using 2.6+ 
>> OProfile kernel interface.
>> 
>> Couldn't start oprofiled.
>> Check the log file "/var/lib/oprofile/oprofiled.log" and 
>> kernel syslog
>> 
>> It appears that this error is coming daemon/liblegacy/init.c 
>> or daemon/init.c This error only occurs on the guests (which 
>> are using the dom0 kernel). 
>> opcontrol --start suceeds on dom0.
>> 
>> Any ideas?
>> 
>> Thanks again,
>> David Carr
>> 
>> Install steps:
>> 
>> In Xen 3.0.0 source directory:
>> 
>> patch -p1 < xenoprof-2.0-xen-3.0.0.patch patch -p1 < 
>> xenoprof-2.0-linux-2.6-sparse.patch
>> make kernels
>> 
>> This will ultimately fail. Then do:
>> 
>> In linux-2.6.12-xen0 directory:
>> 
>> patch -p2 < xenoprof-2.0-linux-2.6.12.patch make kernels
>> 
>> This will ultimately fail. Then do:
>> 
>> In linux-2.6.12-xenU directory:
>> 
>> patch -p2 < xenoprof-2.0-linux-2.6.12.patch make kernels
>> 
>> This will succeed. Then do:
>> 
>> make dist
>> sudo make install
>> 
>> 
>> In oprofile source directory:
>> 
>> patch -p1 < oprofile-0.9.1-xen.patch
>> 
>> 
>> Install oprofile normally
>> 
>> 
>> Santos, Jose Renato G wrote:
>> 
>> > 
>> >David,
>> >
>> >You are right. This is not very clean.
>> >Yes, you need to do a "make" to create the xen0 and xenU 
>> trees before 
>> >applying the patch in step c).
>> >If you configure the kernel with oprofile support (CONFIG_OPROFILE) 
>> >before step c) you will probably get a compilation error 
>> when you run 
>> >make since the patch was not applied yet. You could either delay 
>> >setting (CONFIG_OPROFILE) for after you apply patch "c" or you can 
>> >apply the patch after you get the compilation error, and 
>> then run make 
>> >again.
>> >
>> >It would be better if there was a "make" option to create 
>> the xen0/xenU 
>> >trees without compiling them. Does anybody know if there is such an 
>> >option? I remember looking for it in the Makefile and not 
>> finding it, 
>> >but this was a while ago.
>> >
>> >We are now working on getting the xenoprof code included in 
>> >xen-unstable.
>> >This should make life much easier for those wanting to use oprofile.
>> >
>> >Renato   
>> >
>> >  
>> >
>> >>>-----Original Message-----
>> >>>From: xen-devel-bounces@lists.xensource.com
>> >>>[mailto:xen-devel-bounces@lists.xensource.com] On Behalf Of David 
>> >>>Carr
>> >>>Sent: Tuesday, April 04, 2006 7:31 PM
>> >>>To: xen-devel@lists.xensource.com
>> >>>Subject: [Xen-devel] Compiling xenoprof
>> >>>
>> >>>I'm having some trouble compiling Xen 3.0.0 with the xenoprof 
>> >>>patches.
>> >>>
>> >>>The xenoprof instructions say:
>> >>>
>> >>>  In order to run OProfile in Xen environments four patches are 
>> >>>needed:
>> >>>  a) xenoprof-2.0-xen-3.0.0.patch
>> >>>     Patch for Xen hypervisor.
>> >>>  b) xenoprof-2.0-linux-2.6-sparse.patch
>> >>>     Patch for Xenolinux. Contains oprofile architecture specific 
>> >>>driver
>> >>>     for xen (Apply to linux-sparse tree in Xen source tree)
>> >>>  c) xenoprof-2.0-linux-2.6.12.patch
>> >>>     Patch for oprofile kernel module in linux 2.6.12. 
>> >>>Contain modifications
>> >>>     to generic oprofile driver code to support xen. 
>> (Apply twice, 
>> >>>once to
>> >>>     dom0 and once to domU trees)
>> >>> 
>> >>>
>> >>>Every thing goes fine until part c.  The linux-2.6.12-xen0 and 
>> >>>linux-2.6.12-xenU directories are empty until you build xen (and 
>> >>>therefore can't be patched yet.)  Doing a make world will 
>> populate 
>> >>>these trees but also compiles everything.
>> >>>
>> >>>What is the proper sequence of patching and make commands 
>> to build a 
>> >>>xenoprof tree?
>> >>>
>> >>>Thanks,
>> >>>David Carr
>> >>>
>> >>>
>> >>>
>> >>>_______________________________________________
>> >>>Xen-devel mailing list
>> >>>Xen-devel@lists.xensource.com
>> >>>http://lists.xensource.com/xen-devel
>> >>>
>> >>>      
>> >>>
>> 
>> 

^ permalink raw reply	[flat|nested] 8+ messages in thread
* Compiling xenoprof
@ 2006-04-05  2:31 David Carr
  0 siblings, 0 replies; 8+ messages in thread
From: David Carr @ 2006-04-05  2:31 UTC (permalink / raw)
  To: xen-devel

I'm having some trouble compiling Xen 3.0.0 with the xenoprof patches.

The xenoprof instructions say:

  In order to run OProfile in Xen environments four patches are needed:
  a) xenoprof-2.0-xen-3.0.0.patch
     Patch for Xen hypervisor.
  b) xenoprof-2.0-linux-2.6-sparse.patch
     Patch for Xenolinux. Contains oprofile architecture specific driver 
     for xen (Apply to linux-sparse tree in Xen source tree)
  c) xenoprof-2.0-linux-2.6.12.patch
     Patch for oprofile kernel module in linux 2.6.12. Contain modifications
     to generic oprofile driver code to support xen. (Apply twice, once to 
     dom0 and once to domU trees)
 

Every thing goes fine until part c.  The linux-2.6.12-xen0 and
linux-2.6.12-xenU directories are empty until you build xen (and
therefore can't be patched yet.)  Doing a make world will populate these
trees but also compiles everything.

What is the proper sequence of patching and make commands to build a
xenoprof tree?

Thanks,
David Carr

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2006-04-05 17:18 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-04-05 15:54 Compiling xenoprof Santos, Jose Renato G
2006-04-05 16:19 ` David Carr
2006-04-05 16:54 ` Chris Wright
  -- strict thread matches above, loose matches on Subject: below --
2006-04-05 17:18 Santos, Jose Renato G
2006-04-05 17:06 Santos, Jose Renato G
2006-04-05 16:30 Santos, Jose Renato G
2006-04-05 17:09 ` David Carr
2006-04-05  2:31 David Carr

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.