Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

k8s환경에서의 pinpoint-collector와 pinpoint-web을 hbase의 service를 바라보도록 설정하는법 #11109

Open
moondal opened this issue Jun 3, 2024 · 5 comments

Comments

@moondal
Copy link

moondal commented Jun 3, 2024

Hello.
I am testing to convert the pinpoints you provided as dockers to the k8s environment.

Hbase and zookeeper built as standalone as the default setting for Apache..

The hbase is also created as a pod, and the master is also displayed as a pod name. The pinpoint-collector and the pinpoint-web are trying to communicate with the hbase pod despite no settings.

I was wondering how can I convert hbase to service IP of kubernetes in pinpoint collector and pinpoint web.

Additionally, I would like to ask if there is any help provided by k8s.
The data I found is two years old, so I'd like to ask if you have the latest data

KakaoTalk_Photo_2024-06-03-14-28-04 001
KakaoTalk_Photo_2024-06-03-14-28-05 002

@donghun-cho
Copy link
Contributor

Please ask questions in English so that all pinpoint users can check the contents.

It seems that the HBase address is correctly configured, so is this issue with resolving address in k8s environments?

@moondal
Copy link
Author

moondal commented Jun 3, 2024

I translated it into English.
You did not set the hbase address, but Pinpoint-collector and pinpoint-web try to call the hbase pod.

@donghun-cho
Copy link
Contributor

hbase.properties

hbase.client.host=${pinpoint.zookeeper.address}
hbase.client.port=2181

in docker-compose instead of hbase.client.host environment variable PINPOINT_ZOOKEEPER_ADDRESS is used

Additionally, I would like to ask if there is any help provided by k8s

https://github.com/pinpoint-apm/pinpoint-kubernetes hasn't been updated recently. Since Docker Compose has been updated well, it would be better to convert and use it.

There are two references that might help

@moondal
Copy link
Author

moondal commented Jun 4, 2024

apiVersion: v1
kind: ConfigMap
metadata:
name: pinpoint-collector-configmap
data:
start-collector-metric.sh: |
#!/bin/bash
hbase.client.host=pinpoint-hbase
hbase.client.port=2181
set -e
set -x
exec java -jar /pinpoint/pinpoint-collector-boot.jar --spring.config.additional-location=/pinpoint/config/pinpoint-collector.properties --pinpoint.collector.type=ALL


apiVersion: apps/v1
kind: Deployment
metadata:
name: pinpoint-collector
spec:
replicas: 1
selector:
matchLabels:
app: pinpoint-collector
template:
metadata:
labels:
app: pinpoint-collector
spec:
containers:
- name: pinpoint-collector
command: ["/bin/bash", "/configmap/start-collector-metric.sh"]
volumeMounts:
- name: configmap
mountPath: /configmap
image: pinpointdocker/pinpoint-collector:2.5.3
command: ["/bin/bash", "/configmap/start-collector-metric.sh"]
ports:
- containerPort: 9991
name: grpc-agent
protocol: TCP
- containerPort: 9992
name: grpc-stat
protocol: TCP
- containerPort: 9993
name: grpc-span
protocol: TCP
- containerPort: 9994
name: base-port
protocol: TCP
- containerPort: 9995
name: stat-udp
protocol: UDP
- containerPort: 9996
name: span-udp
protocol: UDP
env:
- name: SPRING_PROFILES_ACTIVE
value: "release"
- name: PINPOINT_ZOOKEEPER_ADDRESS
value: "zoo1"
- name: CLUSTER_ENABLE
value: "true"
- name: LOGGING_LEVEL_ROOT
value: "INFO"
- name: FLINK_CLUSTER_ENABLE
value: "true"
- name: FLINK_CLUSTER_ZOOKEEPER_ADDRESS
value: "zoo1"
- name: JAVA_OPTS
value: "-Dspring.profiles.active=release"
- name: HBASE_HOST
value: "pinpoint-hbase"
volumeMounts:
- name: configmap
mountPath: /configmap
volumes:
- name: configmap
configMap:
name: pinpoint-collector-configmap
defaultMode: 0755

It is already set to zookeeper. Still looking for dns as a pod.

    - name: PINPOINT_ZOOKEEPER_ADDRESS
      value: "zoo1"

06-04 04:07:17.017 [htable-pool4-t1] INFO o.a.h.h.c.RpcRetryingCaller : Call exception, tries=10, retries=35, started=38416 ms ago, cancelled=false, msg=pinpoint-hbase-6fcd554b99-kxkpq:16201 could not be resolved, details=row 'AgentInfo,,00000000000000' on table 'hbase:meta' at region=hbase:meta,,1.1588230740, hostname=pinpoint-hbase-6fcd554b99-kxkpq,16201,1717390997262, seqNum=0, see https://s.apache.org/timeout

Should I set the Hbase hostname to hbase servicename in the zookeeper setting?

I would like to ask if there is a method or environment variable to change from zookeeper to hbase servicename.

pinpoint-hbase ClusterIP 10.254.158.111 60000/TCP,16010/TCP,60020/TCP,16030/TCP
pinpoint-mysql ClusterIP 10.254.148.85 3306/TCP
pinpoint-web ClusterIP 10.254.244.201 8080/TCP,9997/TCP
zoo1 ClusterIP 10.254.159.95 2181/TCP

Thank you.

@donghun-cho
Copy link
Contributor

I think this is not a problem with the pinpoint collector configuration.
It is an issue with the Kubernetes environment and HBase cluster settings.

You should check the kubernetes and Hbase documentation for things like

  • kubernetes service, fqdn, and hostAlias
  • Hbase cluster configuration

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants