JobTracker dump記憶體記錄

2021-06-14 06:40:08 字數 2671 閱讀 1798

1、dump命令列:

jmap -dump:live,format=b,file=heap.bin 9359

2、dump時機:cms gc結束後,這時heap最小,full gc也最快

2012-05-02t22:08:11.226+0800: 470959.079: [gc [1 cms-initial-mark: 103404048k(121634816k)] 103797845k(125409728k), 0.2184710 secs] [times: user=0.22 sys=0.00, real=0.22 secs]

2012-05-02t22:08:11.445+0800: 470959.298: [cms-concurrent-mark-start]

...2012-05-02t22:09:03.533+0800: 471011.386: [cms-concurrent-mark: 51.042/52.088 secs] [times: user=296.93 sys=5.87, real=52.08 secs]

2012-05-02t22:09:03.533+0800: 471011.386: [cms-concurrent-preclean-start]

2012-05-02t22:09:04.432+0800: 471012.285: [cms-concurrent-preclean: 0.855/0.899 secs] [times: user=2.03 sys=0.05, real=0.90 secs]

2012-05-02t22:09:04.432+0800: 471012.285: [cms-concurrent-abortable-preclean-start]

cms: abort preclean due to time 2012-05-02t22:09:06.120+0800: 471013.973: [cms-concurrent-abortable-preclean: 1.686/1.688 secs] [times: user=3.69 sys=0.10, real=1.69 secs]

2012-05-02t22:09:06.137+0800: 471013.990: [gc[yg occupancy: 2860887 k (3774912 k)]471013.990: [rescan (parallel) , 2.3901460 secs]471016.381: [weak refs processing, 0.0181930 secs]471016.399: [class unloading, 0.0240830 secs]471016.423: [scrub symbol & string tables, 0.0026840 secs] [1 cms-remark: 103739059k(121634816k)] 106599946k(125409728k), 2.4389880 secs] [times: user=27.60 sys=0.13, real=2.44 secs]

2012-05-02t22:09:08.577+0800: 471016.430: [cms-concurrent-sweep-start]

...2012-05-02t22:10:49.798+0800: 471117.652: [cms-concurrent-sweep: 98.440/101.222 secs] [times: user=297.82 sys=10.19, real=101.21 secs]

2012-05-02t22:10:49.798+0800: 471117.652: [cms-concurrent-reset-start]

2012-05-02t22:10:50.150+0800: 471118.004: [cms-concurrent-reset: 0.352/0.352 secs] [times: user=0.99 sys=0.03, real=0.35 secs]

3、dump記憶體會觸發full gc這時很悲劇的事情

2012-05-02t22:12:18.273+0800: 471206.127: [full gc 471206.127: [cms: 67912257k->65543780k(121634816k), 260.5313120 secs] 68920123k->65543780k(125409728k), [cms perm : 24838k->24823k(41476k)], 260.5314820 secs] [times: user=259.15 sys=0.20, real=260.49 secs]

這次full gc花了約5分鐘。

4、full gc結束後,立即開始dump,這時才能看到heap.bin檔案在變大

從gc日誌時間可以看出,持續了大約17分鐘。dump的heap檔案約65g,這樣平均dump速度為:

70224599171mb(heap檔案size)/1048s(dump時間)= 63.9mb/s

2012-05-02t22:34:06.579+0800: 472514.433: [gc 472514.433: [parnew: 3355519k->370901k(3774912k), 0.2473880 secs] 68899300k->65914682k(125409728k), 0.2475830 secs] [times: user=2.95 sys=0.02, real=0.24 secs]

5、這次dump記憶體工作總共花了22分鐘,期間jobtracker完全不能工作,影響還是挺大的。

6、下一步期望能在jobtracker上增加乙個工具,dump出其主要記憶體資料。這樣就大大減少了對使用者的影響。

內點法python 內點法

文字理解 內點法屬於約束優化演算法。約束優化演算法的基本思想是 通過引入效用函式的方法將約束優化問題轉換成無約束問題,再利用優化迭代過程不斷地更新效用函式,以使得演算法收斂。內點法 罰函式法的一種 的主要思想是 在可行域的邊界築起一道很高的 圍牆 當迭代點靠近邊界時,目標函式徒然增大,以示懲罰,阻止...

QPixmap loadFromData記憶體洩露

環境 qt 4.6.2 ubuntu 8.10 使用qt4.6.2 中的qpixmap loadfromdata const qbytearray data,const char format 0,qt imageconversionflags flags qt autocolor 發現記憶體有洩露...

內錶 XML互轉 JSON 內錶互轉

轉進內錶 strans try.call transformation id source xml lv text out options clear all 4.7 沒有這個options value handling accept data loss 這個引數也沒有 result data p ...