您的位置:首页 > 其它

jinfo_动态调整JVM参数(无需重启)(实践)

2017-10-03 21:10 204 查看
jinfo使用介绍
可以用来查看正在运行的Java应用程序的扩展参数,甚至支持在运行时,修改部分参数
-flag <name> pid:打印指定JVM的参数值 
-flag [+|-]<name> pid:设置指定JVM参数的布尔值
-flag <name>=<value> pid:设置指定JVM参数的值

启动GC输出
jinfo   -flag +PrintGC pid

jinfo   -flag +PrintGCDetails pid

jinfo   -flag +PrintGCTimeStamps pid

jinfo   -flag +PrintGCDateStamps pid

java虚拟机参数-X 与 -XX的区别

Options that begin with -X are non-standard (not guaranteed to be supported on all VM implementations), and are subject to change without notice in subsequent releases of the JDK.

以 -X 开头的是非标准选项(不能保证被所有的 JVM 实现都支持),如果在后续版本的 JDK 中有变更恕不另行通知。

Options that are specified with -XX are not stable and are not recommended for casual use. These options are subject to change without notice.

指定 -XX 的选项是不稳定、不建议随便使用的。这些选项在今后变更恕不另行通知。
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  jvm