Kafka
[kafka] Mac OS kafka 3.5
닉의네임
2023. 6. 23. 21:15
반응형
kafka 를 3.5로 올려보잣
https://ldh-6019.tistory.com/228
[kafka] MacOs Kafka install / test
kafka를 설치 해보자 https://www.apache.org/dyn/closer.cgi?path=/kafka/2.8.0/kafka_2.13-2.8.0.tgz Apache Download Mirrors Copyright © 2020 The Apache Software Foundation, Licensed under the Apache License, Version 2.0. Apache and the Apache feather l
ldh-6019.tistory.com
kafka를 설치 해보자
https://downloads.apache.org/kafka/3.5.0/kafka_2.13-3.5.0.tgz
#다운로드
wget https://downloads.apache.org/kafka/3.5.0/kafka_2.13-3.5.0.tgz
#압축해제
tar -xvzf kafka_2.13-3.5.0.tgz
zookeeper 실행
cd /Users/doo/kafka/kafka_2.13-3.5.0
bin/zookeeper-server-start.sh -daemon config/zookeeper.properties
kafka 실행
bin/kafka-server-start.sh -daemon config/server.properties
확인
netstat -an | grep 2181
실행 확인
토픽생성
#bin/kafka-topics.sh --create --topic quickstart-event --bootstrap-server localhost:9092
bin/kafka-topics.sh --create --topic 900gle --bootstrap-server localhost:9092
Network 에러 나면
주석제거
listeners=PLAINTEXT://:9092
토픽 확인
bin/kafka-topics.sh --describe --topic 900gle --bootstrap-server localhost:9092
producer 실행
bin/kafka-console-producer.sh --topic 900gle --bootstrap-server localhost:9092
consumer 실행
bin/kafka-console-consumer.sh --topic 900gle --from-beginning --bootstrap-server localhost:9092
producer 에서 메시지 입력하면 consumer 에서 보여진다
좌 : consumer, 우 : producer
반응형