<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugzilla.yoctoproject.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugzilla.yoctoproject.org/"
          
          maintainer="it-coreprojects-helpdesk@linuxfoundation.org"
>

    <bug>
          <bug_id>3242</bug_id>
          
          <creation_ts>2012-10-05 12:21:50 +0000</creation_ts>
          <short_desc>cannot select kernel trace type for a lttng project</short_desc>
          <delta_ts>2019-08-29 15:17:24 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>6</classification_id>
          <classification>Yocto Project Subprojects</classification>
          <product>Eclipse Plugin</product>
          <component>eclipse-plugin</component>
          <version>1.3</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>CLOSED</bug_status>
          <resolution>OBSOLETE</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard>release note, upstream is unpluged lttng legacy support, so please stop using lttng legacy</status_whiteboard>
          <keywords></keywords>
          <priority>Medium</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>1.3</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Alexandru Georgescu">alexandru.c.georgescu</reporter>
          <assigned_to name="Jessica">jessica.zhang</assigned_to>
          <cc>dvhart</cc>
    
    <cc>ioanax.grigoropol</cc>
    
    <cc>tom.zanussi</cc>
    
    <cc>yp.ep.watcher</cc>
    
    <cc>yp.watcher</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>---</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>26281</commentid>
    <comment_count>0</comment_count>
    <who name="Alexandru Georgescu">alexandru.c.georgescu</who>
    <bug_when>2012-10-05 12:21:50 +0000</bug_when>
    <thetext>########################################
STEPS TO REPRODUCE:
 1.Upgrade Eclipse Linux tools lttng to latest version which is under http://download.eclipse.org/technology/linuxtools/update.

2.Install Lttng parser library 2.5 and 2.6 with the URL http://wiki.eclipse.org/Linux_Tools_Project/LTTng.

3. In Eclipse, File-&gt;New Project and create a new Lttng project.

4.Scp the file lttng.c to target machine, then in remote target run: gcc -lust lttng.c, it will generate a binary file named a.out. 
5. Run lttng-ust YoctoProjectTools -&gt; lttng-user space , in the window set the import project to your newly created lttng project, set Application as the absolute patch of a.out on target machine.
6.After lttng-ust is done, you should see an entry created in your ust project&apos;s Traces sub-dir, named  as a long numbers.

7.Right click the entry to change the type to kernel type and select Open


#########################################
EXPECTED RESULTS
7.You may see some tracing date in the lttng-viewer.

#########################################
ACTUAL RESULTS
7. An error appears when selecting kernel trace type:

Type could not be set for one or more traces.




lttng.c file: 


########
#include &lt;ust/marker.h&gt;

int main(int argc, char **argv)
{
  int v=6;
  char *st=&quot;lttng example&quot;;

  trace_mark(main, myevent, &quot;firstarg %d secondarg %s&quot;, v, st);

  trace_mark(main, myotherevent, MARK_NOARGS);

  return 0;

}
########</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>26282</commentid>
    <comment_count>1</comment_count>
    <who name="Alexandru Georgescu">alexandru.c.georgescu</who>
    <bug_when>2012-10-05 12:22:45 +0000</bug_when>
    <thetext>I am using: 

Location: http://autobuilder.yoctoproject.org/pub/nightly/20121003-4
Branch: danny
Tag: 1.3_M5.rc3

Commits:
poky: 86c9aa8081f107420cd3763d0566d779daddc2b1
eclipse-poky: aa38f8b19c921cce2f73647d8aeb7e355c868b56
meta-qt3: c86fb1727ae09526c442ec29fffde3f010aa70eb
meta-intel: 2c1e927fa99abe47865a03cf661d4757ff3147c6</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>26355</commentid>
    <comment_count>2</comment_count>
    <who name="Darren Hart">dvhart</who>
    <bug_when>2012-10-08 18:00:08 +0000</bug_when>
    <thetext>Adding Tom to CC for context.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>26503</commentid>
    <comment_count>3</comment_count>
    <who name="Jessica">jessica.zhang</who>
    <bug_when>2012-10-11 04:04:02 +0000</bug_when>
    <thetext>Alex,

Is this the legacy lttng?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>26510</commentid>
    <comment_count>4</comment_count>
    <who name="Alexandru Georgescu">alexandru.c.georgescu</who>
    <bug_when>2012-10-11 09:29:40 +0000</bug_when>
    <thetext>(In reply to comment #3)
&gt; Alex,
&gt; 
&gt; Is this the legacy lttng?

Hi Jessica,
I am using the legacy lttng.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>26542</commentid>
    <comment_count>5</comment_count>
    <who name="Jessica">jessica.zhang</who>
    <bug_when>2012-10-12 03:19:14 +0000</bug_when>
    <thetext>we&apos;ll remove lttng legacy support in 1.3 point release</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>26565</commentid>
    <comment_count>6</comment_count>
    <who name="Tom Zanussi">tom.zanussi</who>
    <bug_when>2012-10-13 17:48:49 +0000</bug_when>
    <thetext>The links above in STEPS TO REPRODUCE steps 1 and 2 don&apos;t work, and I wasn&apos;t able to locate any current documentation that tells how to set up ADT for 1.3, so haven&apos;t been able to get the basic setup working in order to try reproducing upgrading and installing the components mentioned.

The comments suggest that the user has a choice between using legacy lttng and lttng 2.0.  lttng 2.0 was currently not operational (either was legacy lttng because it&apos;s not supported in the yocto kernels, but that won&apos;t change), but I just submitted a couple patches that fix that:

http://lists.linuxtogo.org/pipermail/openembedded-core/2012-October/030957.html
https://lists.yoctoproject.org/pipermail/poky/2012-October/008477.html

With lttng 2.0 apparently fixed, can the above steps be used to test lttng 2.0 instead of legacy lttng for this bug?  If so, please provide the correct links and updated instructions to try reproducing.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>26613</commentid>
    <comment_count>7</comment_count>
    <who name="Tom Zanussi">tom.zanussi</who>
    <bug_when>2012-10-15 17:08:46 +0000</bug_when>
    <thetext>Apparently, eclipse in the Juno release already has an LTTNG plugin installed that will read and display lttng 2.0 traces.

With the lttng-2.0 fixes mentioned in the previous comment, I was able to capture an lttng 2.0 trace and view the trace files in the eclipse &apos;LTTng kernel perspective&apos;.

This was the eclipse tarball that I used:

eclipse-cpp-juno-SR1-linux-gtk-x86_64.tar.gz

I wasn&apos;t able to connect to the target machine remotely to do this, though, I had to bring the trace files over manually - trying to connect to the remote target I got an &apos;RSE&apos; error:

&apos;Connect	(RSE SubSystem Operation:)&apos; has encountered a problem.

Failed to connect sshd on &quot;192.168.7.2:22&quot;
Failed to connect sshd on &quot;192.168.7.2:22&quot;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>26614</commentid>
    <comment_count>8</comment_count>
    <who name="Jessica">jessica.zhang</who>
    <bug_when>2012-10-15 19:45:38 +0000</bug_when>
    <thetext>Tom, 

The RSE connection issue is caused by RSE can&apos;t handle proxy settings very well, so can you go to Windows-&gt;Preferences-&gt;General-&gt;Network Connection, then under Active Provider: select &quot;Direct&quot; instead of &quot;Manual&quot; or &quot;Native&quot;.


Also, for lttng2.0 we changed the tools to import the remote trace to local tracing project since upstream already have the built in viewer created.

Thanks,
Jessica</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>26615</commentid>
    <comment_count>9</comment_count>
    <who name="Tom Zanussi">tom.zanussi</who>
    <bug_when>2012-10-15 20:15:02 +0000</bug_when>
    <thetext>(In reply to comment #8)
&gt; Tom, 
&gt; 
&gt; The RSE connection issue is caused by RSE can&apos;t handle proxy settings very
&gt; well, so can you go to Windows-&gt;Preferences-&gt;General-&gt;Network Connection,
&gt; then under Active Provider: select &quot;Direct&quot; instead of &quot;Manual&quot; or &quot;Native&quot;.
&gt; 

That seemed to work, thanks, or at least it now connects and lists available events, will have to play around to see if it actually works.

&gt; 
&gt; Also, for lttng2.0 we changed the tools to import the remote trace to local
&gt; tracing project since upstream already have the built in viewer created.
&gt; 

So the LTTng kernel plugin that comes with Juno allows you to list events and initiate tracing over the network, and the tool changes you made allow you to import the trace to the local machine in order to view the trace?

Not sure about the status of this bug then - none of this will work unless the 2 patches I posted to oe-core/poky are pulled in, as I understand it...

But even then, is it working as intended?

I have no context and although it seems to minimally work using Juno out of the box and just pointed at a Yocto target, I can&apos;t test using the official ADT tools since I can&apos;t find the appropriate docs.


&gt; Thanks,
&gt; Jessica</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>26618</commentid>
    <comment_count>10</comment_count>
    <who name="Jessica">jessica.zhang</who>
    <bug_when>2012-10-15 20:55:15 +0000</bug_when>
    <thetext>OK, I&apos;m marking this bug as resolved and obsolte since

1: the context is more toward the legacy lttng-ust support which is obsolete and at that time when importing tracing data (even for ust), there&apos;s no other type associate it them so we just use kernel type, even though it&apos;s not right, but at least allow us to view the tracing data in the trace viewer.  Long story shot, that is no longer support with the un-plug of legacy lttng-ust support from upstream.

2. Seems we&apos;re piggyback this bug for the new lttng2.0 support, so what I&apos;m proposing us to do is:
a. I&apos;ll update ADT manual for the correct 2.0 usage model which is more for importing remote tracing data to an local lttng project, kernel or user space.  For 2.0 since upstream has done a full clean up, now for user space tracing data, the type will be distinguished as &quot;generic CTF trace&quot; or &quot;kernel&quot; trace depends on the tracing data.  I&apos;ve just verified that as far as user space trace, mapping them to &quot;generic CTF trace&quot; works fine.

2. Tom please make sure that our images after your patch can correctly generate both kernel and user space lttng tracing data.  The user space tracing data that I&apos;ve genereated is using the lttng 2.0 hello demo program sample and generate on my local host and copied over to remote target.  Then I verified my eclipse plug-in works.  So, yes, we&apos;ve never fully tested lttng2.0 support in any of our images.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>26642</commentid>
    <comment_count>11</comment_count>
    <who name="Alexandru Georgescu">alexandru.c.georgescu</who>
    <bug_when>2012-10-16 14:40:16 +0000</bug_when>
    <thetext>verified as per Jessica&apos;s last comment.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>84826</commentid>
    <comment_count>12</comment_count>
    <who name="Armin Kuster">akuster</who>
    <bug_when>2019-08-29 15:17:24 +0000</bug_when>
    <thetext>closing</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>