# Metrics from metricbeat do not display in elk but exist in metricbeat console

**URL:** https://discuss.elastic.co/t/metrics-from-metricbeat-do-not-display-in-elk-but-exist-in-metricbeat-console/266966
**Category:** Beats
**Tags:** docker, metricbeat
**Created:** [March 11, 2021, 3:26pm UTC](https://discuss.elastic.co/t/metrics-from-metricbeat-do-not-display-in-elk-but-exist-in-metricbeat-console/266966 "2021-03-11T15:26:44Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![111451](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/111451/32/85402_2.png) [@111451](https://discuss.elastic.co/u/111451)
#### Post date: [March 11, 2021, 3:26pm UTC](https://discuss.elastic.co/t/metrics-from-metricbeat-do-not-display-in-elk-but-exist-in-metricbeat-console/266966/1 "2021-03-11T15:26:44Z")

</div>

**docker-compose.yml**

```
metricbeat:
    container_name: metricbeat
    user: root #To read the docker socket
    image: docker.elastic.co/beats/metricbeat:7.11.1
    logging:
      options:
        max-file: "3"
        max-size: "50m"
    volumes:
      #Mount the metricbeat configuration so users can make edits.
      - ./metricbeat.yml:/usr/share/metricbeat/metricbeat.yml
      - ./system.yml:/usr/share/metricbeat/system.yml
      #Mount the modules.d directory into the container. This allows user to potentially make changes to the modules and they will be dynamically loaded.
      - ./modules.d/:/usr/share/metricbeat/modules.d/
      #The commented sections below enable Metricbeat to monitor the Docker host rather than the Metricbeat container. These are used by the system module.
      - /proc:/hostfs/proc:ro
      - /sys/fs/cgroup:/hostfs/sys/fs/cgroup:ro
      #Allows us to report on docker from the hosts information.
      - /var/run/docker.sock:/var/run/docker.sock:ro
      #We mount the host filesystem so we can report on disk usage with the system module.
      - /:/hostfs:ro
    command: metricbeat -e -system.hostfs=/hostfs -strict.perms=false
    restart: on-failure

```

**metricbeat.yml**

```
metricbeat.config.modules:
path: ${path.config}/modules.d/*.yml
reload.period: 5s
reload.enabled: true
processors:
- add_docker_metadata: ~
monitoring.enabled: true
setup.ilm.enabled: false
output.elasticsearch:
hosts: ["elasticsearch:9200"]

logging.to_files: false
setup:
kibana.host: "kibana:5601"
dashboards.enabled: true

```

**system.yml**

```
- module: system
  metricsets:
    - core
    - cpu
    - load
    - diskio
    - filesystem
    - fsstat
    - memory
    - network
    - process
    - socket
  enabled: true
  period: 5s
  processes: ['.*']
  cpu_ticks: true
  process.cgroups.enabled: true
  process.include_top_n:
    enabled: true
    by_cpu: 20
    by_memory: 20

```

 ![Container instance 2021-03-11 17.22.39](https://us1.discourse-cdn.com/elastic/original/3X/7/e/7e25636fd6dc82e9ee81693f05c9cb6f69ccc949.png)

 ![localhost_9200_metricbeat-___search_pretty - Google Chrome 2021-03-11 17.43.11](https://us1.discourse-cdn.com/elastic/original/3X/c/9/c9483c54ddf7a1b10a8ad351ce77c66dd59292e2.png)

---

<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: [April 8, 2021, 5:27pm UTC](https://discuss.elastic.co/t/metrics-from-metricbeat-do-not-display-in-elk-but-exist-in-metricbeat-console/266966/2 "2021-04-08T17:27:08Z")

</div>

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