jstat 命令 详解

jstat -gccause pid 1 每格1毫秒输出结果

jstat -gccause pid 2000 每格2秒输出结果

不断的在屏幕打印出结果

  S0     S1     E      O      P     YGC     YGCT    FGC    FGCT     GCT   LGCC                 GCC                  

 87.71   0.00  94.71  59.45  59.03  20832 1961.089   121   74.676 2035.765 Allocation Failure   No GC               

 87.71   0.00  94.71  59.45  59.03  20832 1961.089   121   74.676 2035.765 Allocation Failure   No GC               

 87.71   0.00  94.71  59.45  59.03  20832 1961.089   121   74.676 2035.765 Allocation Failure   No GC               

 87.71   0.00  94.71  59.45  59.03  20832 1961.089   121   74.676 2035.765 Allocation Failure   No GC               

 87.71   0.00  94.71  59.45  59.03  20832 1961.089   121   74.676 2035.765 Allocation Failure   No GC               

正好对应JVM 的内存分代

 图中参数含义如下: 

    S0 — Heap上的 Survivor space 0 区已使用空间的百分比    

    S1 — Heap上的 Survivor space 1 区已使用空间的百分比    

    E   — Heap上的 Eden space 区已使用空间的百分比    

    O   — Heap上的 Old space 区已使用空间的百分比    

    P   — Perm space 区已使用空间的百分比 

    YGC — 从应用程序启动到采样时发生 Young GC 的次数 

    YGCT– 从应用程序启动到采样时 Young GC 所用的时间(单位秒)     FGC — 从应用程序启动到采样时发生 Full GC 的次数 

    FGCT– 从应用程序启动到采样时 Full GC 所用的时间(单位秒)     GCT — 从应用程序启动到采样时用于垃圾回收的总时间(单位秒) 

猜你喜欢

转载自ihenu.iteye.com/blog/2351589