Not Able to profile web app from Tomcat-6.0.X

Help
G D
2010-02-04
2013-04-17
  • G D
    G D
    2010-02-04

    Hi,

    I set the Java_Opt as told in the doc.
    JAVA_OPTS=-javaagent:E:\JIP\jip-src\profile\profile.jar
    -Dprofile.properties=E:\JIP\jip-src\profile\webapp.profile.properties

    i have changed the webapp.profile.properties accordingly. Here is which am using:-

    ===========================webapp.profile.properties::::::::::::::::::::::::

    #
    # Is the profiler on or off when the app starts?
    # (on | off)
    # default = on
    #
    profiler=off
    #
    # Can the profiler be controlled remotely ?
    # (on | off)
    # default = off
    #
    remote=on
    #
    # TCP listen port for remote control
    # default =15599
    #
    port=8080
    #
    # Class Loader filters for different runtine environments
    # (The system will cycle through these until it finds one that
    # can filter in the current environment)
    #
    ClassLoaderFilter.1=com.mentorgen.tools.profile.instrument.clfilter.WebAppClassLoaderFilter
    #
    # What is the maximum depth for thread dumps
    # (-1 means no limit)
    # default = -1
    # (you may also use 'compact')
    #
    thread-depth=compact
    #
    # When compacting thread dumps, what in the minimum total time you want
    # to show
    # default = 10 (ms)
    #
    thread.compact.threshold.ms=10000
    #
    # What is the maximum number of methods to show in the method dump
    # (-1 means no limit)
    # default = -1
    # (you may also use 'compact')
    #
    max-method-count=compact
    #
    # defaults to 10
    #
    method.compact.threshold.ms=10000
    #
    # What is the default file name for the profile information
    # default=./profile.txt
    #
    file=E:/JIP/profileWebApp.txt
    #
    # What packages are excluded from the display
    # (comma separated)
    # Note: com.mentorgen.tools.profile is always excluded
    #

    #exclude=org.apache.xalan.xsltc
    debug=on
    track.object.alloc=on 
    output=both
    output-summary-only=no
    output-method-signatures=yes
    #profiler-class=net.sourceforge.jiprof.timeline.TimeLineProfiler
    #accept-class-loaders=org.apache.catalina.loader.StandardClassLoader,org.apache.catalina.loader.WebappClassLoader,org.apache.catalina.loader.Reloader
    ==========================file.bat=================================================
    @ECHO OFF
    rem example: file.bat localhost 8080 E:\JIP\output_file\web.txt
    java -jar client.jar file %1 %2 %3
    =====================================start.bat============================================
    @ECHO OFF
    rem example: start.bat localhost 8080
    java -jar client.jar start %1 %2
    =================================finish.bat==========================================
    @ECHO OFF
    rem example: start.bat localhost 8080
    java -jar client.jar start %1 %2
    =======================================================Steps which i am following================
    1. I deploy my war in tomcat's webapps folder
    2.Start the tomcat, which deploy my web application
    3. I click on the "start.bat" file which open command prompt for 1 or 2 s and close it automatically
    4. I use my application to do something
    5.I click the "finish.bat" which also opened for 1 or 2 sec and closed automatically
    =========================================================================================
    i did't get any txt file at specified location in webapp.profile.properties and file.bat
    so please tell me what i am making wrong. Thanks in advance

     
  • G D
    G D
    2010-02-05

    Hi,
    I am able to findout my mistake. Now its working fine for me.
    I didn't properly set the value of "JAVA_OPTS" in the "catalina.bat" for Tomcat.
    now i have done it correctly and it is working fine.