<html><head></head><body><div style="font-family:courier new, courier, monaco, monospace, sans-serif;font-size:13px;"><div></div>
            <div>Dear Philippe,</div><div><br></div><div>I tried with all options, while my trace result was empty yet and the error message was shown again. Indeed, LTTng did not create a folder for saving trace result. </div><div><br></div><div>Thanks a lot for your guidance in advance.</div><div><br></div><div>Mehdi.</div><div><br></div>
            
            <div id="yahoo_quoted_7882357566" class="yahoo_quoted">
                <div style="font-family:'Helvetica Neue', Helvetica, Arial, sans-serif;font-size:13px;color:#26282a;">
                    
                    <div>
                        On Wednesday, October 11, 2017, 12:28:59 AM GMT+3:30, Philippe Proulx <eeppeliteloop@gmail.com> wrote:
                    </div>
                    <div><br></div>
                    <div><br></div>
                    <div><div dir='ltr'><html><body>On Tue, Oct 10, 2017 at 4:12 PM, MMM <<a shape="rect" ymailto="mailto:e.morovati@yahoo.com" href="mailto:e.morovati@yahoo.com">e.morovati@yahoo.com</a>> wrote:<br clear="none">> Dear Philippe,<br clear="none">><br clear="none">> Thanks a lot for your consideration. I solved former problem. While, I faced<br clear="none">> with a new problem. Indeed, when I create a LTTng session, start it and<br clear="none">> finally stop LTTng, I could not find trace files in mentioned folder. My<br clear="none">> java code is<br clear="none">><br clear="none">> ///////////////////////////////////////<br clear="none">> import java.io.IOException;<br clear="none">> import java.util.logging.Handler;<br clear="none">> import java.util.logging.Logger;<br clear="none">><br clear="none">> import org.lttng.ust.agent.LTTngAgent;<br clear="none">> import org.lttng.ust.agent.jul.LttngLogHandler;<br clear="none"><br clear="none">It looks like you're using the java.util.logging agent...<br clear="none"><br clear="none">><br clear="none">> public class Hello {<br clear="none">> private static final int answer = 42;<br clear="none">> private static LTTngAgent lttngAgent;<br clear="none">><br clear="none">> public static void main(String[] args) throws InterruptedException {<br clear="none">> Logger helloLog = Logger.getLogger("hello");<br clear="none">> lttngAgent = LTTngAgent.getLTTngAgent();<br clear="none">><br clear="none">> Thread.sleep(5000);<br clear="none">> helloLog.info("Hello World, the answer is " + answer);<br clear="none">> lttngAgent.dispose();<br clear="none">> }<br clear="none">><br clear="none">> }<br clear="none">> ///////////////////////<br clear="none">><br clear="none">> Also, I used following LTTng commands.<br clear="none">><br clear="none">> ////////////////////////////////<br clear="none">> lttng create java-test<br clear="none">> lttng enable-event -a -l<br clear="none"><br clear="none">... and the -l/--log4j options applies to the log4j agent.<br clear="none"><br clear="none">Use the -j/--jul option.<br clear="none"><br clear="none">> lttng start<br clear="none">><br clear="none">> ///Start My java Application///<br clear="none">><br clear="none">> lttng stop<br clear="none">> ////////////////////////////<br clear="none">><br clear="none">> Besides, when I used "lttng view" after stopping LTTng, I received following<br clear="none">> error message<br clear="none">><br clear="none">> [error] Cannot open any trace for reading.<br clear="none">> [error] opening trace "/[path]/lttng-traces/java-test10-20171010-130909" for<br clear="none">> reading.<br clear="none">> [error] none of the specified trace paths could be opened.<br clear="none"><br clear="none">This is because your trace is empty (does not even exist).<div class="yqt5117973980" id="yqtfd64953"><br clear="none"><br clear="none">Phil<br clear="none"><br clear="none">><br clear="none">> Could you please help me to resolve it.<br clear="none">><br clear="none">> Regards,<br clear="none">> Mehdi.<br clear="none">><br clear="none">><br clear="none">><br clear="none">><br clear="none">><br clear="none">><br clear="none">><br clear="none">><br clear="none">><br clear="none">> On Monday, October 9, 2017, 1:05:59 AM GMT+3:30, Philippe Proulx<br clear="none">> <<a shape="rect" ymailto="mailto:eeppeliteloop@gmail.com" href="mailto:eeppeliteloop@gmail.com">eeppeliteloop@gmail.com</a>> wrote:<br clear="none">><br clear="none">><br clear="none">> On Sun, Oct 8, 2017 at 4:15 PM, MMM via lttng-dev<br clear="none">> <<a shape="rect" ymailto="mailto:lttng-dev@lists.lttng.org" href="mailto:lttng-dev@lists.lttng.org">lttng-dev@lists.lttng.org</a>> wrote:<br clear="none">>> Dear Users,<br clear="none">>><br clear="none">>> I am beginner in tracing using LTTng. At present, I am going to trace a<br clear="none">>> java<br clear="none">>> program inĀ  Ubuntu, while I faced with a problem. When I install LTTng on<br clear="none">>> Ubuntu, I also install<br clear="none">>><br clear="none">>> "liblttng-ust-agent-java" by "apt-get install liblttng-ust-agent-java"<br clear="none">>> command in Ubuntu. But, when I want to import any libraries related to<br clear="none">>> LTTng<br clear="none">>> such as "org.lttng.ust.agent.jul.LttngLogHandlerorg.lttng.ust.LTTngAgent"<br clear="none">>> to<br clear="none">>> my program, it is marked as unknown package. Indeed, I could not find<br clear="none">>> LTTng<br clear="none">>> Jar file for adding it to my program libraries. Furthermore, I searched in<br clear="none">>> all files and folders, while I could not find Jar file. Could you please<br clear="none">>> help me to understand the cause of this problem and solve it.<br clear="none">><br clear="none">> I'm not a Ubuntu specialist, but from<br clear="none">> <<a shape="rect" href="https://packages.ubuntu.com/zesty/all/liblttng-ust-agent-java/filelist" target="_blank">https://packages.ubuntu.com/zesty/all/liblttng-ust-agent-java/filelist</a>>,<br clear="none">> I would say:<br clear="none">><br clear="none">> * /usr/share/java/lttng-ust-agent-jul.jar<br clear="none">> * /usr/share/java/lttng-ust-agent-log4j.jar<br clear="none">><br clear="none">> On 16.04, it's:<br clear="none">><br clear="none">> * /usr/share/java/liblttng-ust-agent.jar<br clear="none">><br clear="none">> Add the required JAR file to your classpath.<br clear="none">><br clear="none">> Have a look at <<a shape="rect" href="http://lttng.org/docs/v2.9/#doc-java-application" target="_blank">http://lttng.org/docs/v2.9/#doc-java-application</a>>.<br clear="none">><br clear="none">> Phil<br clear="none">><br clear="none">><br clear="none">>><br clear="none">>><br clear="none">>> Best regards,<br clear="none">>><br clear="none">>> Mehdi.<br clear="none">>><br clear="none">>><br clear="none">>> _______________________________________________<br clear="none">>> lttng-dev mailing list<br clear="none">>> <a shape="rect" ymailto="mailto:lttng-dev@lists.lttng.org" href="mailto:lttng-dev@lists.lttng.org">lttng-dev@lists.lttng.org</a><br clear="none">>> <a shape="rect" href="https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev" target="_blank">https://lists.lttng.org/cgi-bin/mailman/listinfo/lttng-dev</a><br clear="none">>><br clear="none"></div></body></html></div></div>
                </div>
            </div></div></body></html>