[ https://issues.apache.org/jira/browse/KAFKA-6406?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16443083#comment-16443083 ]
Kevin Vasko commented on KAFKA-6406: ------------------------------------ I get this same error message. I am on windows 10 and Kafka 2.11-1.1.0. To reproduce simply do {{bin}}{{/zookeeper-server-start}}{{.sh config}}{{/zookeeper}}{{.properties}} {{bin}}{{/kafka-server-start}}{{.sh config}}{{/server}}{{.properties}}{{}} {{bin}}{{/kafka-topics}}{{.sh --create --zookeeper localhost:2181 --replication-factor 1 --partitions 1 --topic }}{{test}}{{}} {{bin\windows\kafka-topics.bat --zookeeper localhost:2181 --delete test --topic test}} {{Kafka immediately throws an access denied error message.}} {{[2018-04-18 14:29:02,843] ERROR Error while renaming dir for test-0 in log dir C:\tmp\kafka-logs (kafka.server.LogDirFailureChannel)}} {{java.nio.file.AccessDeniedException: C:\tmp\kafka-logs\test-0 -> C:\tmp\kafka-logs\test-0.9b7da533fd9d4b1f8ad0e783f16ad1ee-delete}} {{ at sun.nio.fs.WindowsException.translateToIOException(Unknown Source)}} {{ at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source)}} {{ at sun.nio.fs.WindowsFileCopy.move(Unknown Source)}} {{ at sun.nio.fs.WindowsFileSystemProvider.move(Unknown Source)}} {{ at java.nio.file.Files.move(Unknown Source)}} {{ at org.apache.kafka.common.utils.Utils.atomicMoveWithFallback(Utils.java:697)}} {{ at kafka.log.Log$$anonfun$renameDir$1.apply$mcV$sp(Log.scala:579)}} {{ at kafka.log.Log$$anonfun$renameDir$1.apply(Log.scala:577)}} {{ at kafka.log.Log$$anonfun$renameDir$1.apply(Log.scala:577)}} {{ at kafka.log.Log.maybeHandleIOException(Log.scala:1678)}} {{ at kafka.log.Log.renameDir(Log.scala:577)}} {{ at kafka.log.LogManager.asyncDelete(LogManager.scala:813)}} {{ at kafka.cluster.Partition$$anonfun$delete$1.apply(Partition.scala:240)}} {{ at kafka.cluster.Partition$$anonfun$delete$1.apply(Partition.scala:235)}} {{ at kafka.utils.CoreUtils$.inLock(CoreUtils.scala:250)}} {{ at kafka.utils.CoreUtils$.inWriteLock(CoreUtils.scala:258)}} {{ at kafka.cluster.Partition.delete(Partition.scala:235)}} {{ at kafka.server.ReplicaManager.stopReplica(ReplicaManager.scala:347)}} {{ at kafka.server.ReplicaManager$$anonfun$stopReplicas$2.apply(ReplicaManager.scala:377)}} {{ at kafka.server.ReplicaManager$$anonfun$stopReplicas$2.apply(ReplicaManager.scala:375)}} {{ at scala.collection.Iterator$class.foreach(Iterator.scala:891)}} {{ at scala.collection.AbstractIterator.foreach(Iterator.scala:1334)}} {{ at scala.collection.IterableLike$class.foreach(IterableLike.scala:72)}} {{ at scala.collection.AbstractIterable.foreach(Iterable.scala:54)}} {{ at kafka.server.ReplicaManager.stopReplicas(ReplicaManager.scala:375)}} {{ at kafka.server.KafkaApis.handleStopReplicaRequest(KafkaApis.scala:198)}} {{ at kafka.server.KafkaApis.handle(KafkaApis.scala:109)}} {{ at kafka.server.KafkaRequestHandler.run(KafkaRequestHandler.scala:69)}} {{ at java.lang.Thread.run(Unknown Source)}} {{ Suppressed: java.nio.file.AccessDeniedException: C:\tmp\kafka-logs\test-0 -> C:\tmp\kafka-logs\test-0.9b7da533fd9d4b1f8ad0e783f16ad1ee-delete}} {{ at sun.nio.fs.WindowsException.translateToIOException(Unknown Source)}} {{ at sun.nio.fs.WindowsException.rethrowAsIOException(Unknown Source)}} {{ at sun.nio.fs.WindowsFileCopy.move(Unknown Source)}} {{ at sun.nio.fs.WindowsFileSystemProvider.move(Unknown Source)}} {{ at java.nio.file.Files.move(Unknown Source)}} {{ at org.apache.kafka.common.utils.Utils.atomicMoveWithFallback(Utils.java:694)}} {{ ... 23 more}} {{[2018-04-18 14:29:02,847] INFO [ReplicaManager broker=0] Stopping serving replicas in dir C:\tmp\kafka-logs (kafka.server.ReplicaManager)}} {{[2018-04-18 14:29:02,850] INFO [ReplicaFetcherManager on broker 0] Removed fetcher for partitions (kafka.server.ReplicaFetcherManager)}} {{[2018-04-18 14:29:02,851] INFO [ReplicaAlterLogDirsManager on broker 0] Removed fetcher for partitions (kafka.server.ReplicaAlterLogDirsManager)}} {{[2018-04-18 14:29:02,855] INFO [ReplicaManager broker=0] Broker 0 stopped fetcher for partitions and stopped moving logs for partitions because they are in the failed log directory C:\tmp\kafka-logs. (kafka.server.ReplicaManager)}} {{[2018-04-18 14:29:02,855] INFO Stopping serving logs in dir C:\tmp\kafka-logs (kafka.log.LogManager)}} {{[2018-04-18 14:29:02,858] ERROR Shutdown broker because all log dirs in C:\tmp\kafka-logs have failed (kafka.log.LogManager)}} > Topic deletion fails and kafka shuts down (on windows only) > ----------------------------------------------------------- > > Key: KAFKA-6406 > URL: https://issues.apache.org/jira/browse/KAFKA-6406 > Project: Kafka > Issue Type: Bug > Components: core > Affects Versions: 1.0.0 > Environment: Windows only, > Linux is ok > Reporter: pre sto > Priority: Major > Labels: windows > > [2017-12-28 21:30:40,593] INFO [GroupMetadataManager brokerId=1] Removed 0 > expired offsets in 0 milliseconds. > (kafka.coordinator.group.GroupMetadataManager) > [2017-12-28 21:30:40,607] INFO [ReplicaFetcherManager on broker 1] Removed > fetcher for partitions skytest-0 (kafka.server.ReplicaFetcherManager) > [2017-12-28 21:30:40,610] INFO [ReplicaFetcherManager on broker 1] Removed > fetcher for partitions (kafka.server.ReplicaFetcherManager) > [2017-12-28 21:30:40,611] INFO [ReplicaFetcherManager on broker 1] Removed > fetcher for partitions skytest-0 (kafka.server.ReplicaFetcherManager) > [2017-12-28 21:30:40,633] ERROR Error while deleting skytest-0 in dir > E:\dev\trunkA\runtime\target\x86_64\windows\skyboxview\server\bin\..\..\data\kafka\db. > (kafka.server.LogDirFailureChannel) > java.io.IOException: Failed to rename log directory from > E:\dev\trunkA\runtime\target\x86_64\windows\skyboxview\server\bin\..\..\data\kafka\db\skytest-0 > to > E:\dev\trunkA\runtime\target\x86_64\windows\skyboxview\server\bin\..\..\data\kafka\db\skytest-0.2397c4520a0946f0a1887e31f056477b-delete > at kafka.log.LogManager.asyncDelete(LogManager.scala:671) > at kafka.cluster.Partition$$anonfun$delete$1.apply(Partition.scala:178) > at kafka.cluster.Partition$$anonfun$delete$1.apply(Partition.scala:173) > at kafka.utils.CoreUtils$.inLock(CoreUtils.scala:217) > at kafka.utils.CoreUtils$.inWriteLock(CoreUtils.scala:225) > at kafka.cluster.Partition.delete(Partition.scala:173) > at kafka.server.ReplicaManager.stopReplica(ReplicaManager.scala:341) > at > kafka.server.ReplicaManager$$anonfun$stopReplicas$2.apply(ReplicaManager.scala:373) > at > kafka.server.ReplicaManager$$anonfun$stopReplicas$2.apply(ReplicaManager.scala:371) > at scala.collection.Iterator$class.foreach(Iterator.scala:891) > at scala.collection.AbstractIterator.foreach(Iterator.scala:1334) > at scala.collection.IterableLike$class.foreach(IterableLike.scala:72) > at scala.collection.AbstractIterable.foreach(Iterable.scala:54) > at kafka.server.ReplicaManager.stopReplicas(ReplicaManager.scala:371) > at kafka.server.KafkaApis.handleStopReplicaRequest(KafkaApis.scala:190) > at kafka.server.KafkaApis.handle(KafkaApis.scala:104) > at kafka.server.KafkaRequestHandler.run(KafkaRequestHandler.scala:65) > at java.lang.Thread.run(Thread.java:748) > [2017-12-28 21:30:40,634] INFO [ReplicaManager broker=1] Stopping serving > replicas in dir > E:\dev\trunkA\runtime\target\x86_64\windows\skyboxview\server\bin\..\..\data\kafka\db > (kafka.server.ReplicaManager) > [2017-12-28 21:30:40,635] INFO [ReplicaManager broker=1] Partitions are > offline due to failure on log directory > E:\dev\trunkA\runtime\target\x86_64\windows\skyboxview\server\bin\..\..\data\kafka\db > (kafka.server.ReplicaManager) > [2017-12-28 21:30:40,636] INFO [ReplicaFetcherManager on broker 1] Removed > fetcher for partitions (kafka.server.ReplicaFetcherManager) > [2017-12-28 21:30:40,637] INFO [ReplicaManager broker=1] Broker 1 stopped > fetcher for partitions because they are in the failed log dir > E:\dev\trunkA\runtime\target\x86_64\windows\skyboxview\server\bin\..\..\data\kafka\db > (kafka.server.ReplicaManager) > [2017-12-28 21:30:40,637] INFO Stopping serving logs in dir > E:\dev\trunkA\runtime\target\x86_64\windows\skyboxview\server\bin\..\..\data\kafka\db > (kafka.log.LogManager) > [2017-12-28 21:30:40,638] FATAL Shutdown broker because all log dirs in > E:\dev\trunkA\runtime\target\x86_64\windows\skyboxview\server\bin\..\..\data\kafka\db > have failed (kafka.log.LogManager) -- This message was sent by Atlassian JIRA (v7.6.3#76005)