- Filebeat Reference: other versions:
- Overview
- Getting Started With Filebeat
- Setting up and running Filebeat
- Upgrading Filebeat
- How Filebeat works
- Configuring Filebeat
- Specify which modules to run
- Configure inputs
- Manage multiline messages
- Specify general settings
- Load external configuration files
- Configure the internal queue
- Configure the output
- Configure index lifecycle management
- Load balance the output hosts
- Specify SSL settings
- Filter and enhance the exported data
- Define processors
- Add cloud metadata
- Add fields
- Add labels
- Add the local time zone
- Add tags
- Decode CEF
- Decode CSV fields
- Decode JSON fields
- Decode Base64 fields
- Decompress gzip fields
- Community ID Network Flow Hash
- Convert
- Drop events
- Drop fields from events
- Extract array
- Keep fields from events
- Registered Domain
- Rename fields from events
- Add Kubernetes metadata
- Add Docker metadata
- Add Host metadata
- Add Observer metadata
- Dissect strings
- DNS Reverse Lookup
- Add process metadata
- Script Processor
- Timestamp
- Parse data by using ingest node
- Enrich events with geoIP information
- Configure project paths
- Configure the Kibana endpoint
- Load the Kibana dashboards
- Load the Elasticsearch index template
- Configure logging
- Use environment variables in the configuration
- Autodiscover
- YAML tips and gotchas
- Regular expression support
- HTTP Endpoint
- filebeat.reference.yml
- Beats central management
- Modules
- Modules overview
- Apache module
- Auditd module
- AWS module
- CEF module
- Cisco module
- Coredns Module
- Elasticsearch module
- Envoyproxy Module
- Google Cloud module
- haproxy module
- IBM MQ module
- Icinga module
- IIS module
- Iptables module
- Kafka module
- Kibana module
- Logstash module
- MongoDB module
- MSSQL module
- MySQL module
- nats module
- NetFlow module
- Nginx module
- Osquery module
- Palo Alto Networks module
- PostgreSQL module
- RabbitMQ module
- Redis module
- Santa module
- Suricata module
- System module
- Traefik module
- Zeek (Bro) Module
- Exported fields
- Apache fields
- Auditd fields
- AWS fields
- Beat fields
- Decode CEF processor fields fields
- CEF fields
- Cisco fields
- Cloud provider metadata fields
- Coredns fields
- Docker fields
- ECS fields
- elasticsearch fields
- Envoyproxy fields
- Google Cloud fields
- haproxy fields
- Host fields
- ibmmq fields
- Icinga fields
- IIS fields
- iptables fields
- Jolokia Discovery autodiscover provider fields
- Kafka fields
- kibana fields
- Kubernetes fields
- Log file content fields
- logstash fields
- mongodb fields
- mssql fields
- MySQL fields
- nats fields
- NetFlow fields
- NetFlow fields
- Nginx fields
- Osquery fields
- panw fields
- PostgreSQL fields
- Process fields
- RabbitMQ fields
- Redis fields
- s3 fields
- Google Santa fields
- Suricata fields
- System fields
- Traefik fields
- Zeek fields
- Monitoring Filebeat
- Securing Filebeat
- Troubleshooting
- Get help
- Debug
- Common problems
- Can’t read log files from network volumes
- Filebeat isn’t collecting lines from a file
- Too many open file handlers
- Registry file is too large
- Inode reuse causes Filebeat to skip lines
- Log rotation results in lost or duplicate events
- Open file handlers cause issues with Windows file rotation
- Filebeat is using too much CPU
- Dashboard in Kibana is breaking up data fields incorrectly
- Fields are not indexed or usable in Kibana visualizations
- Filebeat isn’t shipping the last line of a file
- Filebeat keeps open file handlers of deleted files for a long time
- Filebeat uses too much bandwidth
- Error loading config file
- Found unexpected or unknown characters
- Logstash connection doesn’t work
- @metadata is missing in Logstash
- Not sure whether to use Logstash or Beats
- SSL client fails to connect to Logstash
- Monitoring UI shows fewer Beats than expected
- Contributing to Beats
Enroll Beats in central management
editEnroll Beats in central management
editThis functionality is in beta and is subject to change. The design and code is less mature than official GA features and is being provided as-is with no warranties. Beta features are not subject to the support SLA of official GA features.
You need to enroll Beats to register them in central management and establish trust. Enrolled Beats will have the credentials needed to retrieve configurations from Kibana.
During the enrollment process:
- The Beat contacts Kibana and tries to register
- Kibana registers the Beat instance and returns an access token for configuration polling
- The enroll command creates a backup of your configuration and then overwrites the current settings so they can be managed centrally
To enroll Beats, use either token-based or username and password-based enrollment.
Prerequisites
edit-
Verify that your Elastic license includes the Beats central management feature.
Don’t have a license? You can start a 30-day trial. At the end of the trial period, you can purchase a subscription to keep using central management. For more information, see https://www.elastic.co/subscriptions and License Management.
- Enable security in Kibana to ensure that only users with sufficient privileges are able to access Beats configurations.
-
Assign the
beats_admin
role to any users who need to enroll Beats or manage configuration settings in central management. - If you plan to use the sample Kibana dashboards provided with Filebeat, load the dashboards before enrolling the Beat.
- If you plan to define module configurations in central management, set up the ingest pipelines before enrolling the Beat. For more information, see Load ingest pipelines manually.
Token-based enrollment
editToken-based enrollment is recommended if you are enrolling Beats manually.
To use token-based enrollment, go to Kibana → Management → Beats and click
Enroll Beat
. Select the Beat type and operating system, then copy and run the
command for enrolling the Beat.
The command has this format:
filebeat enroll KIBANA_URL TOKEN
-
KIBANA_URL
- The URL of the Kibana instance you will use for central management.
-
TOKEN
- The enrollment token generated by the Central Management UI. The enrollment token will expire as soon as it’s used.
For example:
filebeat enroll http://xyz.gov:5601 70f4b584e8024b96b682c46125a8d81
Repeat this process to enroll additional Beats.
Windows users: If you installed Filebeat as a service, you must also set
-path.data
to "C:\ProgramData\filebeat"
when you
run the enroll command. For example:
.\filebeat.exe enroll http://xyz.gov:5601 70f4b584e8024b96b682c46125a8d81a
-path.data "C:\ProgramData\filebeat"
Why? The service installation script, install-service-filebeat.ps1
,
changes the default data path to match the convention used for Windows. If you
run the enroll command without specifying the correct data path, Filebeat
will be enrolled in central management with the wrong UUID and unable to receive
the configuration.
Username and password-based enrollment
editYou can also enroll by specifying a username and password. This is the recommended way for scripted deploys:
filebeat enroll KIBANA_URL --username USER --password METHOD [--force]
-
--username USER
-
The username to use for password-based enrollment. The default
username is
elastic
. -
--password METHOD
-
The method to use for getting the password. Available options are:
-
env:VAR_NAME
gets the password from the environment variableVAR_NAME
-
stdin
prompts the user for a password. This is the default.
-
-
--force
- Overwrites the current settings without asking for confirmation.
For example:
filebeat enroll http://xyz.gov:5601 --username myuser --password stdin
Windows users: If you installed Filebeat as a service, you must also set
-path.data
to "C:\ProgramData\filebeat"
when you
run the enroll command. For example:
.\filebeat.exe enroll http://xyz.gov:5601 --username myuser --password stdin
-path.data "C:\ProgramData\filebeat"
Why? The service installation script, install-service-filebeat.ps1
,
changes the default data path to match the convention used for Windows. If you
run the enroll command without specifying the correct data path, Filebeat
will be enrolled in central management with the wrong UUID and unable to receive
the configuration.