반응형
Installing a package to use the Kafka command(kafka-topics.sh)
Install Azul Zulu on RPM-based Linux(CentOS 7)
https://docs.azul.com/core/zulu-openjdk/install/rpm-based-linux
Install from Azul RPM repository
yum install -y https://cdn.azul.com/zulu/bin/zulu-repo-1.0.0-1.noarch.rpm
Install the required Azul Zulu package
yum install -y zulu11-jdk
Check the java version
/usr/lib/jvm/zulu11/bin/java --version
$ /usr/lib/jvm/zulu11/bin/java --version
openjdk 11.0.13 2021-10-19 LTS
OpenJDK Runtime Environment Zulu11.52+13-CA (build 11.0.13+8-LTS)
OpenJDK 64-Bit Server VM Zulu11.52+13-CA (build 11.0.13+8-LTS, mixed mode)
Setting environmental variables(JAVA PATH)
vim /etc/profile
export JAVA_HOME=/usr/lib/jvm/zulu11
export PATH=$JAVA_HOME/bin:$PATH
source /etc/profile
728x90
Kafka package installation
Download Kafka URL : https://kafka.apache.org/downloads
Install kafka
wget https://archive.apache.org/dist/kafka/2.8.1/kafka_2.13-2.8.1.tgz
tar xvfz kafka_2.13-2.8.1.tgz
cd kafka_2.13-2.8.1/bin
Kafka(kafka-topics.sh) command execution
./kafka-topics.sh --create --zookeeper 192.168.0.101:2181 –replication-factor 3 --partitions 3 --topic my-topic
./kafka-topics.sh --list --zookeeper 192.168.0.101:2181
$ ./kafka-topics.sh --list --zookeeper 192.168.0.101:2181
my-topic
728x90
반응형
'리눅스' 카테고리의 다른 글
쿠버네티스 실습 환경(플레이그라운드) (0) | 2021.12.07 |
---|---|
[Linux] How to build and push Docker images with GitHub Actions (0) | 2021.11.30 |
도커 컨테이너 터미널 프롬프트(PS1) 색상 변경 (0) | 2021.11.25 |
HAProxy 로깅(haproxy logging) 설정하는 방법 (0) | 2021.11.24 |
[리눅스] 도커 컨테이너로 gitlab-runner 실행하는 방법 (0) | 2021.11.22 |