Practice - 5 Tasks
Answer the questions below
1fill in blank
easyComplete the command to download Kafka using wget.
Kafka
wget [1] Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using the website homepage URL instead of the direct download link.
Downloading a wrong file format like .zip instead of .tgz.
✗ Incorrect
The correct URL points directly to the Kafka 3.5.1 tarball for Scala 2.13.
2fill in blank
mediumComplete the command to extract the Kafka archive.
Kafka
tar [1] kafka_2.13-3.5.1.tgz
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using 'c' which is for creating archives instead of extracting.
Omitting the 'z' option for gzip compressed files.
✗ Incorrect
The option -xzvf extracts a gzip compressed tarball verbosely.
3fill in blank
hardFix the error in the command to start the Kafka server.
Kafka
bin/kafka-server-start.sh [1]/config/server.properties Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using just 'config' without the Kafka folder prefix.
Using an incorrect folder path.
✗ Incorrect
The correct path includes the extracted Kafka folder and the config directory.
4fill in blank
hardFill both blanks to create a topic named 'test' with 1 partition and replication factor 1.
Kafka
bin/kafka-topics.sh --create --topic [1] --partitions [2] --replication-factor 1 --bootstrap-server localhost:9092
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using a different topic name.
Setting partitions to a number other than 1.
✗ Incorrect
The topic name is 'test' and it has 1 partition.
5fill in blank
hardFill both blanks to list all topics using the correct bootstrap server and command.
Kafka
bin/kafka-topics.sh --list --bootstrap-server [1]:[2]
Drag options to blanks, or click blank then click option'
Attempts:
3 left
💡 Hint
Common Mistakes
Using Zookeeper port 2181 instead of Kafka port 9092.
Using IP address instead of localhost.
✗ Incorrect
The bootstrap server is localhost on port 9092 for Kafka.