Hi, Asaf,
thank you for the tip!
I have enabled the logging and immediately saw what
the problem was - I did not set the JAVA_PROFILER_HOME
env variable. I just added the correct path to the
PATH env var and thought that was enough. I was wrong.

So, after I set all env vars, I was able to start
Tomcat just fine. Next, I tried attaching to the
Tomcat from the Eclipse Workbench.

I went to the Profile Dialog -> Attach to Agent -> New
configuration -> Agents tab - and there were no
available agents listed. 

Should I try to connect to Tomcat in some other way?

Thank you!
Marina


--- "Yaffe, Asaf" <[EMAIL PROTECTED]> wrote:

> Hi Marina,
> 
> Please enable the JVMTI Profiler logging and post
> the log file to this
> mailing list.
> 
> To enable logging:
> 1. set MARTINI_LOGGER_DIRECTORY=<an existing
> directory of your choice>
> 2. set MARTINI_LOGGER_LOG_LEVEL=5
> 3. Launch Tomcat. 
> 
> A log file named MLog<process_id>.log will be
> generated in
> MARTINI_LOGGER_DIRECTORY
> 
> Thanks,
> Asaf
> 
> --
> Asaf Yaffe, Eclipse TPTP Committer, JVMTI Profiler
> 
> 
> -----Original Message-----
> From:
> [EMAIL PROTECTED]
>
[mailto:[EMAIL PROTECTED]
> On Behalf
> Of Marina
> Sent: Thursday, October 04, 2007 4:16 PM
> To: TPTP mailing list
> Subject: Re: [tptp-tracing-profiling-tools-dev]
> cannot connect to Tomcat
> 
> Hi, Eugene,
> 
> thank you for your response.
> First, I did not use the "Profile on Server"
> functionality because it requires my project to be
> in
> the WTP web app format. Right now, I'm using
> MyEclipse
> and its own web application format, and changing
> that
> to WTP is not an option at this time (unless it
> would
> be the last resort one...)
> 
> So, I have done the following to install and
> configure
> the Agent Controller:
> -- installed Agent Controller in
> C:\Marina\Tools\tptp4.4
> -- ran SetConfig.bat
> -- added C:\Marina\Tools\tptp4.4\bin  and
>
C:\Marina\Tools\tptp4.4\plugins\org.eclipse.tptp.javaprofiler
> to the system PATH env var
> -- started ACServer (tested it with the SampleClient
> -
> OK)
> -- started Tomcat with the same parameters
> (-agentlib:...)
> 
> -- got a different error this time (actually, I am
> not
> seeing any errors when I start Tomcat - the start
> window just flashes by and disappears, but when I
> stop
> Tomcat - I do see the errors):
> [Error: EC JPIAgent received message (FATAL ERROR):
> Internal error (see log file).]
> 
> Here is the content from the servicelog.log of the
> ACServer:
> 
> <CommonBaseEvent
> creationTime="2007-10-04T13:34:15.440000Z"
> globalInstanceId="A02308B756B14EE5A5165C5EC07D0450"
> msg="Received command for unrecognized interface:
> iid=org.eclipse.tptp.eventProvider,
> cmd=listenerAccepted" severity="50" version="1.0.1">
>       <sourceComponentId component="AgentController"
> componentIdType="TPTPComponent"
>
executionEnvironment="D:\cygwin\home\build\TPTP\4.4.0\TPTP-4.4.0-2007061
>
40100C\agntctrl\src\transport\TPTPClientCompTL\Connect2AC.c,
> line 2238" instanceId="1004"
> location="mpopova-xeon.Burlington.Emptoris.com"
> locationType="IPV4" processId="968"
> subComponent="Client Compatibility TL"
> threadId="2092"
> componentType="Eclipse_TPTP"/>
>       <situation categoryName="ReportSituation">
>               <situationType
>
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
> xsi:type="ReportSituation" reasoningScope="INTERNAL"
> reportCategory="LOG"/>
>       </situation>
> </CommonBaseEvent>
> <CommonBaseEvent
> creationTime="2007-10-04T13:34:16.128000Z"
> globalInstanceId="A0D2B1B3E50D4141856A149C02A8FB03"
> msg="File server started listening on port 10005"
> severity="10" version="1.0.1">
>       <sourceComponentId component="AgentController"
> componentIdType="TPTPComponent"
>
executionEnvironment="D:\cygwin\home\build\TPTP\4.4.0\TPTP-4.4.0-2007061
>
40100C\agntctrl\src\transport\TPTPClientCompTL\fileServer.c,
> line 177" instanceId="1004"
> location="mpopova-xeon.Burlington.Emptoris.com"
> locationType="IPV4" processId="968"
> subComponent="Client Compatibility TL"
> threadId="2328"
> componentType="Eclipse_TPTP"/>
>       <situation categoryName="ReportSituation">
>               <situationType
>
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
> xsi:type="ReportSituation" reasoningScope="INTERNAL"
> reportCategory="LOG"/>
>       </situation>
> </CommonBaseEvent>
> <CommonBaseEvent
> creationTime="2007-10-04T13:36:02.410000Z"
> globalInstanceId="A359FED2A1D2451E8B463D202E666E9A"
> msg="PC handleProcessEvents: Process has exited with
> status 0." severity="50" version="1.0.1">
>       <sourceComponentId component="ProcessController"
> componentIdType="TPTPComponent"
> componentType="Eclipse_TPTP"
>
executionEnvironment="D:\cygwin\home\build\TPTP\4.4.0\TPTP-4.4.0-2007061
>
40100C\agntctrl\src\agents\tptpProcessController\ProcessController_md.cp
> p,
> line 284" instanceId="101"
> location="mpopova-xeon.Burlington.Emptoris.com"
> locationType="IPV4" processId="336"
> subComponent="ProcessController" threadId="2936"/>
>       <situation categoryName="ReportSituation">
>               <situationType reasoningScope="INTERNAL"
> reportCategory="LOG"
>
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
> xsi:type="ReportSituation"/>
>       </situation>
> </CommonBaseEvent>
> 
> 
> thanks,
> Marina
> 
> 
> >>>>>>
> Hi Marina,
> 
> Thanks for your interested in TPTP.
> 
> To profile in standalone mode, you need to setup the
> system path in order for the JVM to load the
> necessary
> libraries. Please see the following link for
> details.
>    
>
http://www.eclipse.org/tptp/platform/documents/tutorials/jvmti/Java_Appl
> ication_Profiling_using_TPTP-v2.0.html#3.3
> 
> Since you are starting your Tomcat server in Run
> mode,
> the Integrated Agent Controller(IAC) is not started
> automatically. You can however profile Web
> Application
> on Tomcat using the Profile on Server function,
> which
> will automatically starts the IAC on demand, and
> note
> that with this approach you won't have to manually
> add
> the JVM argument
>
(-agentlib:JPIBootLoader=JPIAgent:server=enabled;HeapProf:allocsites=tru
> e)
> It will be done by the profile launch configuration.
> Detail of the feature is available in the following
> link
>   
>
http://help.eclipse.org/help33/index.jsp?topic=/org.eclipse.tptp.platfor
> m.profile.server.doc.user/tasks/prfserver.xhtml
> 
> Please continue the discussion offline if you have
> further question.
> 
> I hope this helps.
>
------------------------------------------------------------------------
> ------
> Eugene Chan
> IBM Toronto Laboratory, Canada
> 
> 
> 
> _______________________________________________
> tptp-tracing-profiling-tools-dev mailing list
> tptp-tracing-profiling-tools-dev@eclipse.org
>
https://dev.eclipse.org/mailman/listinfo/tptp-tracing-profiling-tools-de
> v
>
---------------------------------------------------------------------
> Intel Israel (74) Limited
> 
=== message truncated ===

_______________________________________________
tptp-tracing-profiling-tools-dev mailing list
tptp-tracing-profiling-tools-dev@eclipse.org
https://dev.eclipse.org/mailman/listinfo/tptp-tracing-profiling-tools-dev

Reply via email to