vmoption
西瓜猿
# vmoption
vmoption
在线教程 (opens new window)
查看,更新 VM 诊断相关的参数
# 使用参考
# 查看所有的 option
[arthas@56963]$ vmoption
KEY VALUE ORIGIN WRITEABLE
---------------------------------------------------------------------------------------------
HeapDumpBeforeFullGC false DEFAULT true
HeapDumpAfterFullGC false DEFAULT true
HeapDumpOnOutOfMemory false DEFAULT true
Error
HeapDumpPath DEFAULT true
CMSAbortablePrecleanW 100 DEFAULT true
aitMillis
CMSWaitDuration 2000 DEFAULT true
CMSTriggerInterval -1 DEFAULT true
PrintGC false DEFAULT true
PrintGCDetails true MANAGEMENT true
PrintGCDateStamps false DEFAULT true
PrintGCTimeStamps false DEFAULT true
PrintGCID false DEFAULT true
PrintClassHistogramBe false DEFAULT true
foreFullGC
PrintClassHistogramAf false DEFAULT true
terFullGC
PrintClassHistogram false DEFAULT true
MinHeapFreeRatio 0 DEFAULT true
MaxHeapFreeRatio 100 DEFAULT true
PrintConcurrentLocks false DEFAULT true
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
# 查看指定的 option
$ vmoption PrintGC
KEY VALUE ORIGIN WRITEABLE
---------------------------------------------------------------------------------
PrintGC false MANAGEMENT true
1
2
3
4
2
3
4
# 更新指定的 option
$ vmoption PrintGC true
Successfully updated the vm option.
NAME BEFORE-VALUE AFTER-VALUE
------------------------------------
PrintGC false true
1
2
3
4
5
2
3
4
5
$ vmoption PrintGCDetails true
Successfully updated the vm option.
NAME BEFORE-VALUE AFTER-VALUE
-------------------------------------------
PrintGCDetails false true
1
2
3
4
5
2
3
4
5