# Metricbeat Kubernetes event module

**URL:** <https://discuss.elastic.co/t/metricbeat-kubernetes-event-module/198186>\
**Category:** Beats\
**Tags:** docker, metricbeat\
**Created:** [September 5, 2019, 7:41am UTC](https://discuss.elastic.co/t/metricbeat-kubernetes-event-module/198186 "2019-09-05T07:41:00Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![baymax\_zhao](https://avatars.discourse-cdn.com/v4/letter/b/fbc32d/32.png) [@baymax\_zhao](https://discuss.elastic.co/u/baymax_zhao)\
**Post date:** [September 5, 2019, 7:41am UTC](https://discuss.elastic.co/t/metricbeat-kubernetes-event-module/198186/1 "2019-09-05T07:41:00Z")

</div>

Metricbeat watch kubernetes event .run for a while, An eof error occurred  
this issue happen in alibaba cloud Container Service, but in aws cloud had not happend

kubernetes module config:

```auto
 79 kubernetes.yml: |-
 80 - module: kubernetes
 81 metricsets:
 82 - event
 83 period: 10s
 84 host: ${NODE_NAME}
 85 # If using Red Hat OpenShift remove the previous hosts entry and 
 86 # uncomment these settings:
 87 #hosts: ["https://${HOSTNAME}:10250"]
 88 #bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token
 89 #ssl.certificate_authorities:
 90 # - /var/run/secrets/kubernetes.io/serviceaccount/ca.crt
 91 #ssl.verification_mode: "none"
 92 add_metadata: true
 93 in_cluster: true
 94 fields_under_root: true
 95 fields:
 96 environment: ${ENVIRONMENT}
 97 REGION: ${REGION

```

log:

```auto
2019-09-05T06:29:12.239Z	DEBUG	[cfgfile]	cfgfile/reload.go:197	Scan for new config files
2019-09-05T06:29:12.239Z	DEBUG	[cfgfile]	cfgfile/cfgfile.go:175	Load config from file: /usr/share/metricbeat/modules.d/kubernetes.yml
2019-09-05T06:29:12.239Z	DEBUG	[cfgfile]	cfgfile/reload.go:216	Number of module configs found: 1
2019-09-05T06:29:12.239Z	DEBUG	[reload]	cfgfile/list.go:62	Starting reload procedure, current runners: 1
2019-09-05T06:29:12.239Z	DEBUG	[reload]	cfgfile/list.go:80	Start list: 0, Stop list: 0
2019-09-05T06:29:20.456Z	DEBUG	[kubernetes]	kubernetes/watcher.go:261	EOF while watching API
2019-09-05T06:29:20.456Z	INFO	kubernetes/watcher.go:242	kubernetes: Watching API for resource events
2019-09-05T06:29:20.479Z	DEBUG	[kubernetes]	kubernetes/watcher.go:261	EOF while watching API
2019-09-05T06:29:20.479Z	INFO	kubernetes/watcher.go:242	kubernetes: Watching API for resource events
2019-09-05T06:29:20.579Z	DEBUG	[kubernetes]	kubernetes/watcher.go:261	EOF while watching API

```

---

<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:** [October 3, 2019, 7:41am UTC](https://discuss.elastic.co/t/metricbeat-kubernetes-event-module/198186/2 "2019-10-03T07:41:05Z")

</div>

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