1. Get you cluster ARN
$ aws kafka list-clusters --output text | grep arn | grep CLUSTERINFOLIST
CLUSTERINFOLIST arn:aws:kafka:ap-northeast-2:369647062832:cluster/oss-bmt-msk/ffa0a81d-7c80-4483-a6cd-ad85fec473f9-2
oss-bmt-msk
2021-05-08T23:57:13.969Z K3P5ROKL5A1OLE
PER_TOPIC_PER_BROKER 3 ACTIVE
z-2.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:2181,
z-3.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:2181,
z-1.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:2181
z-2.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:2182,
z-3.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:2182,
z-1.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:2182
여기서 Cluster ARN인 arn:aws:kafka:ap-northeast-2:369647062832:cluster/oss-bmt-msk/ffa0a81d-7c80-4483-a6cd-ad85fec473f9-2 값으로 향후 이 Kafka Cluster의 다양한 정보를 조회하도록 한다.
$ export CLUSTER_ARN="arn:aws:kafka:ap-northeast-2:369647062832:cluster/oss-bmt-msk/ffa0a81d-7c80-4483-a6cd-ad85fec473f9-2"
$ aws kafka get-bootstrap-brokers --cluster-arn $CLUSTER_ARN
{
"BootstrapBrokerStringTls": "b-2.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:9094,b-3.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:9094,b-1.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:9094",
"BootstrapBrokerString": "b-2.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:9092,b-3.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:9092,b-1.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:9092"
}
Client Integration Information
아래 Console 또는 아래 Command로 확인 가능
aws kafka get-bootstrap-brokers --cluster-arn arn:aws:kafka:ap-northeast-2:369647062832:cluster/oss-bmt-msk/ffa0a81d-7c80-4483-a6cd-ad85fec473f9-2 --output text
Zookeeper connection 정보 확인
$ aws kafka describe-cluster --cluster-arn $CLUSTER_ARN --output json | jq ".ClusterInfo.ZookeeperConnectString"
"z-2.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:2181,z-3.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:2181,z-1.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:2181"
다른 곳에서 사용을 위해 변수 처리를 한다.
$ export MYZK=$(aws kafka describe-cluster --cluster-arn $CLUSTER_ARN --output json | jq ".ClusterInfo.ZookeeperConnectString" | tr -d \")
Bootstrap server
TLS
b-3.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:9094,b-2.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:9094,b-1.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:9094
Plaintext
b-3.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:9092,b-2.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:9092,b-1.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:9092
Apache Zookeeper connection
TLS
z-2.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:2182,z-3.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:2182,z-1.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:2182
Plaintext
z-2.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:2181,z-3.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:2181,z-1.oss-bmt-msk.621e1j.c2.kafka.ap-northeast-2.amazonaws.com:2181
'TANGO > 기본 환경 구성' 카테고리의 다른 글
EKS Cluster 접속을 위한 kubeconfig 설정 (0) | 2021.05.10 |
---|---|
MSK 구성 (미완료) (0) | 2021.05.09 |
Prometheus와 Grafana 구성 (0) | 2021.05.08 |
Amazon EFS CSI Driver (0) | 2021.05.08 |
AMAZON EBS CSI DRIVER (1) | 2021.05.08 |