ibm monitoring and diagnostic tools - gcmv 2.8

12
GCMV 2.8 Memory Analysis for Java and Node.js

Upload: chris-bailey

Post on 13-Jul-2015

791 views

Category:

Software


2 download

TRANSCRIPT

GCMV 2.8Memory Analysis for Java and Node.js

© 2014 International Business Machines Corporation 2

Offline memory monitoring capability for:● Java and Node.js Garbage Collection (GC)● Operating System memory usage

Provides ability to:● Monitor process and system memory usage● Identify application memory usage and leaks● Analyse and tune GC performance

Visualization provided via Eclipse Client UI● Available from Eclipse Marketplace● Available from IBM Support Assistant

Headless/batch mode ● Run automated analysis

IBM Monitoring and Diagnostics: Garbage Collection and Memory Visualizer (GCMV)

© 2014 International Business Machines Corporation 3

IBM Monitoring and Diagnostics: GCMV

Available for JavaAvailable for Node.js

Garbage CollectionGarbage Collection performance and memory usageGraphical visualization including cropping and zoomingStatistical analysis of dataRecommendations for tuning garbage collectionMemory leak detection

Memory Usage Process and System memory usageGraphical visualization including cropping and zoomingStatistical analysis of dataMemory leak detection

© 2014 International Business Machines Corporation 4

CollectingData

© 2014 International Business Machines Corporation 5

Process and System memory monitoring data

#!/bin/shPID=$1INTERVAL=3

# Echo time at start of monitoring.echo timestamp = `date +%s`

# Echo the interval frequency.echo "ps interval = $INTERVAL"

# Run the system command at intervals.while ([ -d /proc/$PID ]) do ps -p $PID -o pid,vsz,rss sleep $INTERVALdone

#!/bin/shPID=$1INTERVAL=3

# Echo time at start of monitoring.echo timestamp = `date +%s`

# Echo the interval frequency.echo "svmon interval = $INTERVAL"

# Run the system command at intervals.while ([ -d /proc/$PID ]) do svmon -r -m -P $PID sleep $INTERVALdone

#!/bin/shPID=$1INTERVAL=3

# Echo time at start of monitoring.echo timestamp = `date +%s`

# Echo the interval frequency.echo "svmon interval = $INTERVAL"

# Run the system command at intervals.while true ; do ps -p $PID -o pid,vsz sleep $INTERVALdone

Run perfmonSelect “Performance Logs and Alerts > Counter Logs”Create a log file name, eg. Memory UsageClick “Add Counters...”Select “Process > Virtual Bytes” from CountersSelect you process from InstancesSelect “Add” and “Close”Click “Log Files” and “Text File (Comma delimited)”Select “Schedule” and then “Manually” in Start logStart logging by clicking “Start”

Linux AIX

Windows zOS

Note: Scripts are provided in the Help documentation

© 2014 International Business Machines Corporation 6

Garbage Collection monitoring data

-Xverbosegclog:[FILE_NAME] --trace_gc--trace_gc_nvp--trace_gc_verbose

Java : IBM SDKs Node.js

Java: Oracle and Open JDKs

Note: Scripts are provided in the Help documentation

Log verbose GC data to a given file name

-Xverbosegclog:[FILE_NAME],[FILES],[ENTRIES]

Log verbose GC data to a rolling number of files, eachWith a maximum number of GC cycle entries

-Xverbosegclog:vgc.%Y%m%d.%H%M%S.%pid.txt

Log data to a file name including token substitutions

-XX:+PrintGCDateStamps-XX:+PrintGCDetails-XX:+PrintGCTimeStamps

-Xloggc:[FILE_NAME]

Log verbose GC data to a given file name

Enable collection of date and time stamped GC data

Log detailed verbose GC data to the console

--trace_gc--trace_gc_nvp--trace_gc_verbose[APPLICATION] > [FILE_NAME] 2>&1

Capture the console to a given file name

© 2014 International Business Machines Corporation 7

PerformanceOverhead

© 2014 International Business Machines Corporation 8

Performance Overhead (IBM SDK for Java)

Measured using WebSphere App Server and the DayTrader benchmark with 50 clients

Running WAS 8.5.5, IBM Java 7 SR5, AIX 7.1, POWER7

Throughput determined by number of completed transactions on 4 saturated CPUs

0

500

1000

1500

2000

2500

3000

3500

4000

Throughput Runs Min Max Stddev

Without verbose:gc 3743.953 8 3637.019 3855.971 71.6304964862

With verbose:gc

© 2014 International Business Machines Corporation 9

Performance Overhead (IBM SDK for Java)

Measured using WebSphere App Server and the DayTrader benchmark with 50 clients

Running WAS 8.5.5, IBM Java 7 SR5, AIX 7.1, POWER7

Throughput determined by number of completed transactions on 4 saturated CPUs

0

500

1000

1500

2000

2500

3000

3500

4000

Throughput Runs Min Max Stddev

Without verbose:gc 3743.953 8 3637.019 3855.971 71.6304964862

With verbose:gc 3748.779 8 3654.9945 3877.9495 83.5641336842

0.1289% ?

© 2014 International Business Machines Corporation 10

IBM Developer Kits for Javaibm.biz/javasdk

WebShere Liberty Profilewasdev.net

IBM Bluemixibm.com/bluemix

IBM Developer Kits for Node.jsibm.biz/nodesdk

© 2014 International Business Machines Corporation 11

References

• IBM Monitoring and Diagnostics - Health Center:• https://www.ibm.com/developerworks/java/jdk/tools/gcmv/

• IBM SDKs for Java:• https://www.ibm.com/developerworks/java/jdk/

• IBM SDKs for Node.js:• http://www.ibm.com/developerworks/web/nodesdk/

© 2014 International Business Machines Corporation 12

Copyrights and Trademarks

© IBM Corporation 2014. All Rights Reserved

IBM, the IBM logo, ibm.com are trademarks or registered

trademarks of International Business Machines Corp.,

registered in many jurisdictions worldwide. Other product and

service names might be trademarks of IBM or other companies.

A current list of IBM trademarks is available on the Web at

“Copyright and trademark information” at

www.ibm.com/legal/copytrade.shtml

Node.js is an official trademark of Joyent. IBM SDK for Node.js is not formally related to or endorsed by the official Joyent Node.js open source or

commercial project.

Java, JavaScript and all Java-based trademarks and logos are trademarks or registered trademarks of Oracle and/or its affiliates.