Replies: 4 comments 8 replies
-
I'm not sure how you run it, but the error says that the file probably doesn't exist. Keep in mind that if you run it using |
Beta Was this translation helpful? Give feedback.
-
Hi Jakub, |
Beta Was this translation helpful? Give feedback.
-
Below are the logs when executed in kubernetes and individual docker containers Kubernetes exception:
kafka@f58f63a9a695 kafka]$ cd bin
|
Beta Was this translation helpful? Give feedback.
-
attached screenshots for reference. this will be helpful |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi Team,
I'm trying to update replication factor to 3 for already created topic by creating json file and executing the kubectl command /kafka-reassign-partitions.sh --bootstrap-server localhost:9092 --reassignment-json-file /home/localen/demotesttopic.json --execute
but getting below error even after I have admin rights
Error: Unable to read file /home/localen/demotesttopic.json
java.io.IOException: Unable to read file /home/localen/demotesttopic.json
at org.apache.kafka.common.utils.Utils.readFileAsString(Utils.java:698)
at kafka.admin.ReassignPartitionsCommand$.handleAction(ReassignPartitionsCommand.scala:256)
at kafka.admin.ReassignPartitionsCommand$.main(ReassignPartitionsCommand.scala:215)
at kafka.admin.ReassignPartitionsCommand.main(ReassignPartitionsCommand.scala)
Caused by: java.nio.file.NoSuchFileException: /home/localen/demotesttopic.json
at java.base/sun.nio.fs.UnixException.translateToIOException(UnixException.java:92)
at java.base/sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:111)
at java.base/sun.nio.fs.UnixException.rethrowAsIOException(UnixException.java:116)
at java.base/sun.nio.fs.UnixFileSystemProvider.newByteChannel(UnixFileSystemProvider.java:219)
at java.base/java.nio.file.Files.newByteChannel(Files.java:371)
at java.base/java.nio.file.Files.newByteChannel(Files.java:422)
at java.base/java.nio.file.Files.readAllBytes(Files.java:3206)
at org.apache.kafka.common.utils.Utils.readFileAsString(Utils.java:695)
... 3 more
Below is my json file and its valid json
{
"version": 1,
"partitions": [{
"topic": "demotesttopic",
"partition": 0,
"replicas": [0, 1, 2]
},
{
"topic": "demotesttopic",
"partition": 1,
"replicas": [0, 1, 2]
},
{
"topic": "demotesttopic",
"partition": 2,
"replicas": [0, 1, 2]
},
{
"topic": "demotesttopic",
"partition": 3,
"replicas": [0, 1, 2]
}
]
}
Could you please suggest is there any way to update replication factor .
Thanks in advance
Beta Was this translation helpful? Give feedback.
All reactions