WARNING: Version 5.3 of Metricbeat has passed its EOL date.
This documentation is no longer being maintained and may be removed. If you are running this version, we strongly advise you to upgrade. For the latest information, see the current release documentation.
This functionality is in technical preview and may be changed or removed in a future release. Elastic will apply best effort to fix any issues, but features in technical preview are not subject to the support SLA of official GA features.
You can configure Metricbeat to dynamically reload configuration files when there are changes. To do this, you specify a path (Glob) to watch for module configuration changes. When the files found by the Glob change, new modules are started/stopped according to changes in the configuration files.
This feature is especially useful in container environments where one container is used to monitor all services running in other containers on the same host. Because new containers appear and disappear dynamically, you may need to change the Metricbeat configuration frequently to specify which modules are needed and which hosts must be monitored.
To enable dynamic config reloading, you specify the
in the main
metricbeat.yml config file. For example:
metricbeat.config.modules: path: configs/*.yml reload.enabled: true reload.period: 10s
- A Glob that defines the files to check for changes.
When set to
true, enables dynamic config reload.
Specifies how often the files are checked for changes. Do not
periodto less than 1s because the modification time of files is often stored in seconds. Setting the
periodto less than 1s will result in unnecessary overhead.
Each file found by the Glob must contain a list of one or more module definitions. For example:
- module: system metricsets: ["cpu"] enabled: false perdiod: 1s - module: system metricsets: ["network"] enabled: true period: 10s