How to create a Kafka topic in a broker

0 votes

Hi Team,

I have configured a single node single broker Kafka cluster. Now I want to create a topic in the broker. How can I create a topic?

Dec 7, 2020 in Apache Kafka by akhtar
• 38,170 points
106 views

1 answer to this question.

0 votes

Hi@akhtar,

To create a Kafka topic, you need to tell the location of the zookeeper with the same port no, you mentioned in the zoo.cfg file. You can run the below command to create a Kafka topic.

$ bin/kafka-topics.sh --zookeeper localhost:2181 --create --topic topic-edu --replication-factor 1 --partitions 1
Created topic topic-edu.
answered Dec 7, 2020 by MD
• 95,180 points

Related Questions In Apache Kafka

0 votes
1 answer

How to delete a topic in Kafka 0.8.1.1?

Deleting topic isn't always working in 0.8.1.1 Deletion ...READ MORE

answered Sep 4, 2018 in Apache Kafka by nitinrawat895
• 11,380 points
826 views
0 votes
1 answer

Is there any change in consumer offsets if a new partition(s) is added to a Kafka topic?

Yes, it stays the same. An offset is ...READ MORE

answered Jul 9, 2018 in Apache Kafka by nitinrawat895
• 11,380 points
928 views
0 votes
1 answer

How to check pending messages in KAFKA topic?

kafka-run-class.bat kafka.tools.ConsumerOffsetChecker --broker-info --group test-consumer-group --topic test ...READ MORE

answered May 29, 2020 in Apache Kafka by chandra
4,773 views
0 votes
0 answers

how to delete the topic in kafka

How to stop Kafka server from crashing ...READ MORE

May 13, 2020 in Apache Kafka by sreeveena
• 140 points
246 views
+1 vote
1 answer

Hadoop Mapreduce word count Program

Firstly you need to understand the concept ...READ MORE

answered Mar 16, 2018 in Data Analytics by nitinrawat895
• 11,380 points
7,246 views
0 votes
1 answer

hadoop.mapred vs hadoop.mapreduce?

org.apache.hadoop.mapred is the Old API  org.apache.hadoop.mapreduce is the ...READ MORE

answered Mar 16, 2018 in Data Analytics by nitinrawat895
• 11,380 points
1,176 views
+2 votes
11 answers

hadoop fs -put command?

Hi, You can create one directory in HDFS ...READ MORE

answered Mar 16, 2018 in Big Data Hadoop by nitinrawat895
• 11,380 points
53,201 views
–1 vote
1 answer

Hadoop dfs -ls command?

In your case there is no difference ...READ MORE

answered Mar 16, 2018 in Big Data Hadoop by kurt_cobain
• 9,390 points
2,746 views
0 votes
1 answer

How can I create a topic in apache kafka?

Hi@akhtar, To create kafka topic you can use ...READ MORE

answered Feb 6, 2020 in Apache Kafka by MD
• 95,180 points
208 views
0 votes
1 answer