Unrecognized VM option "+ UseCompressedOops" when starting kafka from my ubuntu in vmware

I work with ubuntu using VMware I installed a single cluster node hasoop in it. Then I installed zookeeper and launched zookeeper. then when I start my "Apache kafka", it gives an error.

Unrecognized VM option '+ UseCompressedOops'

Failed to create Java Virtual Machine

single @ubuntu: ~ / yoga / zookeeper-3.4.5 / bin $ ./zkServer.sh start

JMX is enabled by default

Using config: /home/single/yoga/zookeeper-3.4.5/bin /../ conf / zoo.cfg

Running zookeeper ... START

single @ubuntu: ~ / yoga / kafka_2.8.0-0.8.0 $ bin / kafka-server-start.sh config / server.properties

Unrecognized VM + UseCompressedOops Option

Failed to create Java virtual machine.

+4
source share
3 answers

Since your virtual machine does not support the "+ UseCompressedOops" parameter. To fix this, remove this option from the kafka configuration, which will help you start both servers (zookeeper and kafka).

1) Go to the Kafka installation directory:

cd kafka_2.8.0-0.8

2) Edit the installer of the kafka script class:

vi bin/kafka-run-class.sh

3) Find the token "KAFKA_JVM_PERFORMANCE_OPTS" and remove the '-XX: + UseCompressedOops' from this line.

ie, before deleting:

KAFKA_JVM_PERFORMANCE_OPTS="-server -XX:+UseCompressedOops -XX:+UseParNewGC -XX:+UseConcMarkSweepGC -XX:+CMSClassUnloadingEnabled -XX:+CMSScavengeBeforeRemark -XX:+DisableExplicitGC -Djava.awt.headless=true"

after removal:

KAFKA_JVM_PERFORMANCE_OPTS="-server -XX:+UseParNewGC -XX:+UseConcMarkSweepGC -XX:+CMSClassUnloadingEnabled -XX:+CMSScavengeBeforeRemark -XX:+DisableExplicitGC -Djava.awt.headless=true"

4) Run both instances of zookeeper and kafka server

./bin/zookeeper-server-start.sh config/zookeeper.properties
./bin/kafka-server-start.sh config/server.properties
+12
source

VM, . 2
1)
2)

+UseCompressedOops VM , , , .. , VM, java -version, -

    Java HotSpot(TM) Client VM (build 24.51-b03, mixed mode, sharing)

. @VonC .


JOPM UseCompressedOops ?
http://www.oracle.com/technetwork/java/javase/tech/index-jsp-136373.html http://www.oracle.com/technetwork/java/whitepaper-135217.html

+3

32- 64- ? , , :

1) kafka ( kafka-0.7.2-incubating-src)

2)

3) cd to kafka home ( tgz)

/home/kuntal/Kuntal/BIG_DATA/kafka-0.7.2-incubating-src

4)

./sbt . /sbt package

5) cd kafaka home bin

/home/kuntal/Kuntal/BIG_DATA/kafka-0.7.2-incubating-src/bin

6) type

kafka-server-start.sh/home/kuntal/Kuntal/BIG_DATA/kafka-0.7.2-incubating-src/config/server.properties

You will see that the Kafka server is running in the terminal. Hope this helps someone! :)

0
source

Source: https://habr.com/ru/post/1531154/


All Articles