Setting up Metricbeat is an admin-level task that requires extra privileges. As a best practice, grant the setup role to administrators only, and use a more restrictive role for event publishing.
Administrators who set up Metricbeat typically need to load mappings, dashboards, and other objects used to index data into Elasticsearch and visualize it in Kibana.
To grant users the required privileges:
Create a setup role, called something like
metricbeat_setup, that has the following privileges:
Type Privilege Purpose
Retrieve cluster details (e.g. version)
Set up and manage index lifecycle management (ILM) policy
Set up aliases used by ILM
Omit any privileges that aren’t relevant in your environment.
These instructions assume that you are using the default name for Metricbeat indices. If
metricbeat-*is not listed, or you are using a custom name, enter it manually and modify the privileges to match your index naming pattern.
Assign the setup role, along with the following built-in roles, to users who need to set up Metricbeat:
Load dependencies, such as example dashboards, if available, into Kibana
Set up index templates and, if available, ingest pipelines
Enroll and manage configurations in Beats central management
Omit any roles that aren’t relevant in your environment.