Re: Comparing profiles with opreport

Michael Petlan <[email protected]>
Newsgroups gmane.linux.oprofile
Organization Red Hat
Message-ID <1442580467.13087.357.camel@Rudolf-RHEL-7>
Hi Henry,

I can reproduce it using your steps with both RHEL oprofile and the
upstream git head. I think it might be a bug.

OParchive packs all the necessary data into the archive. But it is not
enough unfortunately.

When I do the following:

opreport ls
oparchive -o archive1
opreport ls
oparchive -o archive2
strace -e trace=file -o problem.log opreport --merge=all -a -l --demangle=smart { archive:archive1 } { archive:archive2 }

... I get the correct report, but it stats for the default session dir:

stat("/home/mpetlan2/tmp/tmp/oprofile_data", {st_mode=S_IFDIR|0775, st_size=30, ...}) = 0

When opreport gets it, it's happy and in case the archived absolute
paths include the same session dir's name, everything is OK.


In case I rename the oprofile_data dir after the archives are created,
it does not work, either:

opreport --merge=all -a -l --demangle=smart { archive:archive1 } { archive:archive2 }
(the oprofile_data dir is not found, since it's renamed)

or

opreport --merge=all -a -l --demangle=smart --session-dir=/home/renamed { archive:archive1 } { archive:archive2 }
(the renamed dir exists, but it is not available in the archived tree)


I guess that this issue is also behind your problem. I think that
oprofile needs a fix in order to ignore session dirs when dealing with
archives, since if you compare two archives, you should not need the
session dir. You need the session dir only if you compare an archive
against a current run.

Regards,
Michael


On Wed, 2015-09-16 at 13:45 +0000, Henry May wrote:
> I'm trying to compare profiles taken on two systems (one is RHEL6 and
> the other is RHEL7) using opreport per the instructions at
> http://oprofile.sourceforge.net/doc/opreport.html#opreport-diff
>  
> On the RHEL6 system I did:
> operf
> -d /storage/hjmay/results/TNF/h0424_2015-09-08_J1P4.181.perf.2/operf/ChainSink02.15805/server_20150908174952_prof
> oparchive
> --session-dir=/storage/hjmay/results/TNF/h0424_2015-09-08_J1P4.181.perf.2/operf/ChainSink02.15805/server_20150908174952_prof -o /storage/hjmay/results/TNF/h0424_2015-09-08_J1P4.181.perf.2/operf_arch
>  
> On the RHEL7 system I did:
> operf
> -d /storage/hjmay/results/TNF/h0429_2015-09-08_J1P4.181.perf.2/operf/ChainSink02.5081/server_20150908221930_prof
> oparchive
> --session-dir=/storage/hjmay/results/TNF/h0429_2015-09-08_J1P4.181.perf.2/operf/ChainSink02.5081/server_20150908221930_prof -o /storage/hjmay/results/TNF/h0429_2015-09-08_J1P4.181.perf.2/operf_arch
>  
> All of the files are on a shared file system accessible to both
> systems.
>  
> If I run opreport on a single session's data; e.g.,
> opreport --merge=all -a -l --demangle=smart
> --session-dir=/storage/hjmay/results/TNF/h0429_2015-09-08_J1P4.181.perf.2/operf/ChainSink02.5081/server_20150908221930_prof archive:/storage/hjmay/results/TNF/h0429_2015-09-08_J1P4.181.perf.2/operf_arch
> or
> opreport --merge=all -a -l --demangle=smart
> --session-dir=/storage/hjmay/results/TNF/h0424_2015-09-08_J1P4.181.perf.2/operf/ChainSink02.15805/server_20150908174952_prof archive:/storage/hjmay/results/TNF/h0424_2015-09-08_J1P4.181.perf.2/operf_arch
> I get the profile histogram data as expected.
> But If I try to run a differential report; e.g.,
> opreport --merge=all -a -l --demangle=smart
> { --session-dir=/storage/hjmay/results/TNF/h0424_2015-09-08_J1P4.181.perf.2/operf/ChainSink02.15805/server_20150908174952_prof archive:/storage/hjmay/results/TNF/h0424_2015-09-08_J1P4.181.perf.2/operf_arch } { --session-dir=/storage/hjmay/results/TNF/h0429_2015-09-08_J1P4.181.perf.2/operf/ChainSink02.5081/server_20150908221930_prof archive:/storage/hjmay/results/TNF/h0429_2015-09-08_J1P4.181.perf.2/operf_arch }
> I get
> opreport error: No sample file found: If using opcontrol for
> profiling,
> try running 'opcontrol --dump'; otherwise, specify a session
> containing
> sample files.
> 
> What am I missing?
>  
>  
>  
>  
>   
> 
> Henry May
> IBM InfoSphere Streams Performance
> [email protected]
> 720-342-8873
> Tie: 963-8873
> 
> ------------------------------------------------------------------------------
> Monitor Your Dynamic Infrastructure at Any Scale With Datadog!
> Get real-time metrics from all of your servers, apps and tools
> in one place.
> SourceForge users - Click here to start your Free Trial of Datadog now!
> http://pubads.g.doubleclick.net/gampad/clk?id=241902991&iu=/4140
> _______________________________________________
> 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.