660 likes | 804 Views
Tools for Measuring System and Application Performance. Introduction GlancePlus Introduction Glance Motif Glance Character Mode Glance Command-line Xverbosegc HPjmeter and –Xeprof Other Tools gdb. G lance P lus M otif /opt/perf/bin/ gpm. GlancePlus Motif.
E N D
Tools for Measuring System and Application Performance • Introduction • GlancePlus • Introduction • Glance Motif • Glance Character Mode • Glance Command-line • Xverbosegc • HPjmeter and –Xeprof • Other Tools • gdb
GlancePlus Motif /opt/perf/bin/gpm
GlancePlus Motif • Open multiple windows to simultaneously view: • Machine’s behavior • Process’s behavior • Thread behavior • We will learn how to use it with Java applications
GlancePlus MotifMain Window – Overview of System CPU Memory I/O Network
GlancePlus MotifConfigure Sampling Time Configure:Measurement Sample Interval: Minutes: 0 Seconds: 1 Graph Points: 50
Active Button: CPU Graph GlancePlus MotifMain Window – CPU Usage
GlancePlus MotifCPU Graph CPU Queue Length • CPU Usage Categories: • Real • Negative Nice (-20 to 0) • Nice (greater than 0) • Normal User • System 8 CPUs
GlancePlus MotifCPU Graph – Garbage Collection 1 Thread Active during GC
GlancePlus MotifMain Window - Reports:Process List Reports:Process List
GlancePlus MotifProcess List 8 CPU System: 800% Maximum CPU%
GlancePlus MotifProcess List – Arrange Columns Configure:Arrange Columns
GlancePlus MotifProcess List – Arrange Columns • Interesting values: • CPU% • User CPU% • System CPU% • Virtual Memory • Res(ident) Memory • Physical I/O • Configure:Choose Metrics: • PROC_THREAD_COUNT
GlancePlus MotifProcess List - Reports Process Resources Process Open Files Process Memory Regions Process System Calls Process Thread List
GlancePlus MotifProcess System Calls Sorted on: SysCall Rate
GlancePlus MotifProcess System Calls - Sort Configure:Sort Fields
GlancePlus MotifProcess System Calls System Calls for Idling JVM
GlancePlus MotifProcess List - Reports Process Resources Process Open Files Process Memory Regions Process System Calls Process Thread List
Total Number of Memory Regions GlancePlus MotifProcess Memory Regions VSS – Virtual Set Size Total Reserved Space RSS – Resident Set Size Space Actively in Use
GlancePlus MotifProcess Memory Regions Data == C Heap Text == Executable Stack == For 1st Thread Other == Java Heap Shared Libraries Thread Stacks
GlancePlus MotifProcess Memory Regions - Sort Sort on VSS
GlancePlus MotifProcess Memory Regions - Metrics Add Page Size Metrics
GlancePlus MotifProcess Memory Regions - Metrics Select All PROC_REGION_PAGE_COUNT*
GlancePlus MotifProcess Memory Regions - Metrics For Address: Select PROC_REGION_VIRT_ADDRS
GlancePlus MotifProcess Memory Regions – Pages Page Sizes Allocated In Java Heap All: 4 KB Too Many Total!!
GlancePlus MotifProcess Memory Regions – Pages Page Sizes Allocated In Java Heap All: 4 MB Very Few Total!!
GlancePlus MotifProcess List - Reports Process Resources Process Open Files Process Memory Regions Process System Calls Process Thread List
Thread Id Total Number of Threads Active Threads JVM Threads GlancePlus MotifProcess Thread List
GlancePlus MotifProcess List - Reports Process Resources Process Open Files Process Memory Regions Process System Calls Process Thread List
File Name Total Number of Open Files Sockets – Monitor Bytes Read and Written! GlancePlus MotifProcess Open Files File Type File Offset
GlancePlus MotifMain Window - Reports System Info: System Tables Graph
GlancePlus MotifSystem Tables Graph Process Table File Table Shared Memory Table Semaphore Table File Locks Swap Space
GlancePlus MotifIdentifying Performance Problems • Patterns to recognize • High System CPU time • Often associated with monitor contention • Check by looking at System Calls • High sched_yield, ksleep, kwakeup call rate confirms • Increasing memory usage • Thread stacks • C Heap • Percentage of the Java Heap in active use
Class header header C++ vtable Object method table ptr non-static fields static fields GC maps HotSpot JVMObject Model • Efficient and low overhead