Kafka中错误:Unrecognized VM option ‘UseCompressedOops’ Error: Clould not create the Java Vritual Machin
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Kafka中错误:Unrecognized VM option ‘UseCompressedOops’ Error: Clould not create the Java Vritual Machin相关的知识,希望对你有一定的参考价值。
错误的描述:
在kafka安装目录下,执行 $ bin/zookeeper-server-start.sh config/zookeeper.properties &
Unrecognized VM option ‘UseCompressedOops’
Error: Clould not create the Java Vritual Machine.
Error: A fatal exception has occurres . Program will exit.
解决方法:
找到bin/kafka-run-class.sh 文件,使用vim打开,我的这个版本是在115行
113 # JVM performance options
114 if [ -z "$KAFKA_JVM_PERFORMANCE_OPTS" ]; then
115 KAFKA_JVM_PERFORMANCE_OPTS="-server -XX:+UseCompressedOops -XX:+UseParNewGC -XX:+UseConcMarkSweepGC -XX:+CMSClassUnloadingEnabled -XX:+CMSScavengeBeforeRe mark -XX:+DisableExplicitGC -Djava.awt.headless=true"
116 fi
去掉-XX:+UseCompressedOops这个设置
去掉,之后的结果:
111 # JVM performance options
112 if [ -z "$KAFKA_JVM_PERFORMANCE_OPTS" ]; then
113 KAFKA_JVM_PERFORMANCE_OPTS="-server -XX:+UseParNewGC -XX:+UseConcMarkSweepGC -XX:+CMSClassUnloadingEnabled -XX:+CMSScavengeBefo reRemark -XX:+DisableExplicitGC -Djava.awt.headless=true"
114 fi
然后,保存,退出。再次,执行,
在kafka安装目录下,执行 $ bin/zookeeper-server-start.sh config/zookeeper.properties &
即,此问题,得到了解决!
参考链接: kafka入门介绍及环境搭建-Kafka-about云开发
以上是关于Kafka中错误:Unrecognized VM option ‘UseCompressedOops’ Error: Clould not create the Java Vritual Machin的主要内容,如果未能解决你的问题,请参考以下文章
Windows启动RocketMq报错:Unrecognized VM option ‘UseCMSCompactAtFullCollection‘
Windows启动RocketMq报错:Unrecognized VM option ‘UseCMSCompactAtFullCollection‘
elasticsearch Unrecognized VM option 'UseParNewGC'
JMeter学习 JMeter使用中遇到的问题:Jmeter Debug - "Unrecognized VM option '+HeapDumpOnOutOfMemoryEr