# How to connect prometheus metrics with openTelemtry report trace data

**URL:** <https://discuss.elastic.co/t/how-to-connect-prometheus-metrics-with-opentelemtry-report-trace-data/278259>\
**Category:** APM\
**Tags:** elastic-stack-monitoring, go\
**Created:** [July 9, 2021, 9:16am UTC](https://discuss.elastic.co/t/how-to-connect-prometheus-metrics-with-opentelemtry-report-trace-data/278259 "2021-07-09T09:16:16Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![lisiyu](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/lisiyu/32/91545_2.png) [@lisiyu](https://discuss.elastic.co/u/lisiyu)\
**Post date:** [July 9, 2021, 9:16am UTC](https://discuss.elastic.co/t/how-to-connect-prometheus-metrics-with-opentelemtry-report-trace-data/278259/1 "2021-07-09T09:16:16Z")

</div>

**Kibana version** : 7.13.0

**Elasticsearch version** : 7.13.0

**APM Server version** : 7.13.0

\*\*Original install method : k8s

**Is there anything special in your setup?**  
Using the kafka outputs. No changed index pattern,generated custom templates, changed agent configuration etc

\*\*Description of the problem including expected versus actual behavior. \*\*:  
MetricBeat has been implemented to connect to Prometheus.Discovery can show index for MetricBeat. But apm metric can't connect prometheus data. I want to connect prometheus metrics with openTelemtry report trace data. This MetricBeat config:

```auto
- module: system
      period: 10s
      metricsets:
        - cpu
        - load
        - memory
        - network
        - process
        - process_summary
        #- core
        #- diskio
        #- socket
      processes: ['.*']
      process.include_top_n:
        by_cpu: 5 # include top 5 processes by CPU
        by_memory: 5 # include top 5 processes by memory

    - module: system
      period: 1m
      metricsets:
        - filesystem
        - fsstat
      processors:
      - drop_event.when.regexp:
          system.filesystem.mount_point: '^/(sys|cgroup|proc|dev|etc|host|lib|snap)($|/)'
   - module: kubernetes
        hosts: ["kube-state-metrics:8080"]
        period: 10s
        add_metadata: true
        metricsets:
        - state_node
        - state_deployment
        - state_daemonset
        - state_replicaset
        - state_pod
        - state_container
        - state_cronjob
        - state_resourcequota
        - state_statefulset
        - state_service
    - module: kubernetes
        metricsets:
        - apiserver
        bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token
        ssl.certificate_authorities:
        - /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
        period: 30s
  kubernetes.yml: |-
    - module: kubernetes
      metricsets:
        - node
        - system
        - pod
        - container
        - volume
      period: 10s
      host: ${NODE_NAME}
      hosts: ["https://${NODE_NAME}:10250"]
      bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token
      ssl.verification_mode: "none"

```

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 30, 2021, 5:16am UTC](https://discuss.elastic.co/t/how-to-connect-prometheus-metrics-with-opentelemtry-report-trace-data/278259/2 "2021-07-30T05:16:48Z")

</div>

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.
