Skip to content

Linux VPS & VPS Windows Setup Guide | NetCloud24 Apache Kafka on Rocky Linux

Netcloud24
Cloud Infrastructure Expert
HOSTING H1

Free web hosting H1

5 GB of storage and SSL for a small website or WordPress project.

Explore hosting H1
WINDOWS VPS + RDS

Run Windows applications remotely

Windows Server 2022 or 2025 and RDS CALs included in the plan. Choose resources and user capacity for your business.

Explore Windows VPS
NetCloud24 Expert Guides Open the dedicated video page

Video transcript: NetCloud24 Expert Guides. Practical knowledge for a reliable cloud. Cloud and VPS expertise, security, performance, and step-by-step tutorials. Learn, deploy, and keep building with NetCloud24.

 

 

Introduction

Apache Kafka is a distributed event streaming platform capable of handling trillions of events a day. It is commonly used for building real-time data pipelines and streaming applications. In this guide, you will learn how to install Apache Kafka on Rocky Linux, which can be effectively hosted on a for enhanced performance and reliability.

Prerequisites

  • A Rocky Linux server with root access
  • Java Development Kit (JDK) installed
  • Basic knowledge of Linux commands

Step 1: Update Your System

Start by updating your package index and upgrading existing packages:

sudo dnf update -y

Step 2: Install Java JDK

Apache Kafka requires Java, so install the OpenJDK package:

sudo dnf install java-11-openjdk-devel -y

Verify the Java installation:

Visual overview of Linux VPS & VPS Windows Setup Guide | NetCloud24 Apache Kafka on Rocky Linux
Visual overview: Linux VPS & VPS Windows Setup Guide | NetCloud24 Apache Kafka on Rocky Linux
java -version

Step 3: Download Apache Kafka

Download the latest version of Apache Kafka:

wget https://downloads.apache.org/kafka/3.5.0/kafka_2.13-3.5.0.tgz

Extract the downloaded archive:

tar -xzf kafka_2.13-3.5.0.tgz

Move the extracted Kafka folder to /usr/local:

sudo mv kafka_2.13-3.5.0 /usr/local/kafka

Step 4: Start Zookeeper

Kafka requires Zookeeper to manage distributed brokers. Start Zookeeper using the following command:

sudo /usr/local/kafka/bin/zookeeper-server-start.sh /usr/local/kafka/config/zookeeper.properties

Step 5: Start Kafka Server

Open another terminal session to start the Kafka server:

sudo /usr/local/kafka/bin/kafka-server-start.sh /usr/local/kafka/config/server.properties

Step 6: Create a Kafka Topic

Create a new Kafka topic called “test” using the following command:

Key topics covered in Linux VPS & VPS Windows Setup Guide | NetCloud24 Apache Kafka on Rocky Linux
Key topics covered in this NetCloud24 guide.
sudo /usr/local/kafka/bin/kafka-topics.sh --create --topic test --bootstrap-server localhost:9092 --partitions 1 --replication-factor 1

Step 7: Test Kafka

To test your Kafka installation, open a producer terminal and send messages:

sudo /usr/local/kafka/bin/kafka-console-producer.sh --topic test --bootstrap-server localhost:9092

In another terminal, consume the messages:

sudo /usr/local/kafka/bin/kafka-console-consumer.sh --topic test --from-beginning --bootstrap-server localhost:9092

Step 8: Conclusion

You have successfully installed Apache Kafka on Rocky Linux. This powerful messaging platform can significantly benefit from being hosted on a . For additional options, explore various solutions, including Windows VPSVirtual Private Server Hosting and Windows VPS Hosting UK for optimal performance and reliability.

© 2024 Apache Kafka Installation Tutorial. All rights reserved.

Linux VPS & VPS Windows Setup Guide | NetCloud24 Apache Kafka on Rocky Linux
Linux VPS & VPS Windows Setup Guide | NetCloud24 Apache Kafka on Rocky Linux
Explore more

More on this topic

Netcloud24
Netcloud24
Cloud Infrastructure Expert · NetCloud24

Comments are closed.

Linux VPS & VPS Windows Setup Guide | NetCloud24 Apache Kafka on Rocky Linux

Netcloud24
Cloud Infrastructure Expert
HOSTING H1

Free web hosting H1

5 GB of storage and SSL for a small website or WordPress project.

Explore hosting H1
WINDOWS VPS + RDS

Run Windows applications remotely

Windows Server 2022 or 2025 and RDS CALs included in the plan. Choose resources and user capacity for your business.

Explore Windows VPS
NetCloud24 Expert Guides Open the dedicated video page

Video transcript: NetCloud24 Expert Guides. Practical knowledge for a reliable cloud. Cloud and VPS expertise, security, performance, and step-by-step tutorials. Learn, deploy, and keep building with NetCloud24.

 

 

Introduction

Apache Kafka is a distributed event streaming platform capable of handling trillions of events a day. It is commonly used for building real-time data pipelines and streaming applications. In this guide, you will learn how to install Apache Kafka on Rocky Linux, which can be effectively hosted on a for enhanced performance and reliability.

Prerequisites

  • A Rocky Linux server with root access
  • Java Development Kit (JDK) installed
  • Basic knowledge of Linux commands

Step 1: Update Your System

Start by updating your package index and upgrading existing packages:

sudo dnf update -y

Step 2: Install Java JDK

Apache Kafka requires Java, so install the OpenJDK package:

sudo dnf install java-11-openjdk-devel -y

Verify the Java installation:

Visual overview of Linux VPS & VPS Windows Setup Guide | NetCloud24 Apache Kafka on Rocky Linux
Visual overview: Linux VPS & VPS Windows Setup Guide | NetCloud24 Apache Kafka on Rocky Linux
java -version

Step 3: Download Apache Kafka

Download the latest version of Apache Kafka:

wget https://downloads.apache.org/kafka/3.5.0/kafka_2.13-3.5.0.tgz

Extract the downloaded archive:

tar -xzf kafka_2.13-3.5.0.tgz

Move the extracted Kafka folder to /usr/local:

sudo mv kafka_2.13-3.5.0 /usr/local/kafka

Step 4: Start Zookeeper

Kafka requires Zookeeper to manage distributed brokers. Start Zookeeper using the following command:

sudo /usr/local/kafka/bin/zookeeper-server-start.sh /usr/local/kafka/config/zookeeper.properties

Step 5: Start Kafka Server

Open another terminal session to start the Kafka server:

sudo /usr/local/kafka/bin/kafka-server-start.sh /usr/local/kafka/config/server.properties

Step 6: Create a Kafka Topic

Create a new Kafka topic called “test” using the following command:

Key topics covered in Linux VPS & VPS Windows Setup Guide | NetCloud24 Apache Kafka on Rocky Linux
Key topics covered in this NetCloud24 guide.
sudo /usr/local/kafka/bin/kafka-topics.sh --create --topic test --bootstrap-server localhost:9092 --partitions 1 --replication-factor 1

Step 7: Test Kafka

To test your Kafka installation, open a producer terminal and send messages:

sudo /usr/local/kafka/bin/kafka-console-producer.sh --topic test --bootstrap-server localhost:9092

In another terminal, consume the messages:

sudo /usr/local/kafka/bin/kafka-console-consumer.sh --topic test --from-beginning --bootstrap-server localhost:9092

Step 8: Conclusion

You have successfully installed Apache Kafka on Rocky Linux. This powerful messaging platform can significantly benefit from being hosted on a . For additional options, explore various solutions, including Windows VPSVirtual Private Server Hosting and Windows VPS Hosting UK for optimal performance and reliability.

© 2024 Apache Kafka Installation Tutorial. All rights reserved.

Linux VPS & VPS Windows Setup Guide | NetCloud24 Apache Kafka on Rocky Linux
Linux VPS & VPS Windows Setup Guide | NetCloud24 Apache Kafka on Rocky Linux
Explore more

More on this topic

Netcloud24
Netcloud24
Cloud Infrastructure Expert · NetCloud24

Comments are closed.