How to set up and install Apache Kafka on Ubuntu

Apache Kafka is a powerful distributed streaming platform that allows you make streaming apps and real-time data pipelines. It can handle trillions of events every day, which makes it the backbone of modern data infrastructure.

In this article we will see how to set up and install Apache Kafka on Ubuntu step by step in this guide. 


Requirements                                                                                                                                               

Before we begin the installation, make sure your Ubuntu system meets these requirements:                        

  • Java Development Kit (JDK): Kafka is written in Java and needs Java 8 or later to work.
  • For smooth operation, at least 4GB of RAM is recommended, but it can run on less for testing.

Step 1: Install Java

Since Kafka runs on the Java Virtual Machine (JVM), the first step is to install a compatible JDK. We will use OpenJDK 11, which is widely used and stable.
  • Update the package repository: Open the terminal and copy the below command and paste in the terminal then hit enter then package list will be updated.
sudo apt update

  • Install OpenJDK: copy the below command and paste in the terminal then hit enter to install the JDK. 

  •  Verify the installation: Once the installation finishes, copy the below command to check the Java version if you will able to see the version of java the java is successfully installed.
java -version

Step 2: Download Apache Kafka

Download the latest version of Apache Kafka: We will use wget command to download version 3.7.1 (Download the latest version of Apache Kafka from this link click here). copy the link of latest version of Apache Kafka from the website and paste in front of the wget to download it. same as you can see below.
wget https://downloads.apache.org/kafka/3.7.1/kafka_2.13-3.7.1.tgz
Extract the archive: Unzip the downloaded file using the tar command.
tar -xvzf kafka_2.13-3.7.1.tgz
Rename the folder (Optional): To make it easier to navigate, rename the extracted directory to simply kafka.
mv kafka_2.13-3.7.1 kafka

Conclusion

At this point, Apache Kafka is successfully downloaded and installed on Ubuntu system. In the next article we test the installation of Apache Kafka.

 




Comments

Popular posts from this blog

Virtual Private Network - VPN

Windows Registry Forensics: Detecting Malware Persistence with Process Monitor

Mastering Incident Response: Complete Guide to CrowdResponse Forensic Tool