Community Articles
Find and share helpful community-sourced technical articles
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.
Labels (1)
New Contributor

ISSUE:

FATAL Fatal error during KafkaServerStartable startup. Prepare to shutdown (kafka.server.KafkaServerStartable) kafka.common.KafkaException: Failed to acquire lock on file .lock in /opt/kafka/log. A Kafka instance in another process or thread is using this directory. at kafka.log.LogManager$anonfun$lockLogDirs$1.apply(LogManager.scala:98) at kafka.log.LogManager$anonfun$lockLogDirs$1.apply(LogManager.scala:95) at scala.collection.TraversableLike$anonfun$map$1.apply(TraversableLike.scala:244) at scala.collection.TraversableLike$anonfun$map$1.apply(TraversableLike.scala:244) at scala.collection.IndexedSeqOptimized$class.foreach(IndexedSeqOptimized.scala:33) at scala.collection.mutable.WrappedArray.foreach(WrappedArray.scala:34) at scala.collection.TraversableLike$class.map(TraversableLike.scala:244) at scala.collection.AbstractTraversable.map(Traversable.scala:105) at kafka.log.LogManager.lockLogDirs(LogManager.scala:95) at kafka.log.LogManager.<init>(LogManager.scala:57) at kafka.server.KafkaServer.createLogManager(KafkaServer.scala:589) at kafka.server.KafkaServer.startup(KafkaServer.scala:171) at kafka.server.KafkaServerStartable.startup(KafkaServerStartable.scala:37) at kafka.Kafka$.main(Kafka.scala:67) at kafka.Kafka.main(Kafka.scala)

[2017-03-30 06:32:06,504] INFO shutting down (kafka.server.KafkaServer)

RESOLUTION:

move .lock file from /opt/kafka/log to a temporary location and restart the kafka broker on the node.

3,178 Views
0 Kudos
Comments
New Contributor

I did kafka-server-stop.sh and zkServer.sh stop and then restarted it using zkServer.sh start and kafka-server-start.sh and it worked for me.

Don't have an account?
Coming from Hortonworks? Activate your account here
Version history
Revision #:
1 of 1
Last update:
‎03-30-2017 06:52 AM
Updated by:
 
Contributors
Top Kudoed Authors