-
Notifications
You must be signed in to change notification settings - Fork 4.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add ZooKeeper Module to Filebeat (#25128)
Adds a new module for ZooKeeper audit and service logs.
- Loading branch information
1 parent
89d2b36
commit d09dfb0
Showing
24 changed files
with
1,954 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,93 @@ | ||
//// | ||
This file is generated! See scripts/docs_collector.py | ||
//// | ||
|
||
[[filebeat-module-zookeeper]] | ||
:modulename: zookeeper | ||
:has-dashboards: false | ||
|
||
== ZooKeeper module | ||
|
||
The +{modulename}+ module collects and parses the logs created by https://zookeeper.apache.org/[Apache ZooKeeper] | ||
|
||
include::../include/what-happens.asciidoc[] | ||
|
||
include::../include/gs-link.asciidoc[] | ||
|
||
[float] | ||
=== Compatibility | ||
|
||
The +{modulename}+ module was tested with logs from versions 3.7.0. | ||
|
||
include::../include/configuring-intro.asciidoc[] | ||
|
||
The following example shows how to set paths in the +modules.d/{modulename}.yml+ | ||
file to override the default paths for logs: | ||
|
||
[source,yaml] | ||
----- | ||
- module: zookeeper | ||
audit: | ||
enabled: true | ||
var.paths: | ||
- "/path/to/logs/zookeeper_audit.log*" | ||
log: | ||
enabled: true | ||
var.paths: | ||
- "/path/to/logs/zookeeper.log*" | ||
----- | ||
|
||
|
||
To specify the same settings at the command line, you use: | ||
|
||
[source,yaml] | ||
----- | ||
-M "zookeeper.audit.var.paths=[/path/to/logs/zookeeper_audit.log*]" -M "zookeeper.log.var.paths=[/path/to/logs/zookeeper.log*]" | ||
----- | ||
|
||
[float] | ||
=== Audit logging | ||
|
||
Audit logging is available since Zookeeper 3.6.0, but it is disabled by default. To enable it, you can add the following setting to the configuration file: | ||
["source","sh"] | ||
---------------------- | ||
audit.enable=true | ||
---------------------- | ||
|
||
//set the fileset name used in the included example | ||
:fileset_ex: audit | ||
|
||
include::../include/config-option-intro.asciidoc[] | ||
|
||
[float] | ||
==== `audit` fileset settings | ||
|
||
include::../include/var-paths.asciidoc[] | ||
|
||
include::../include/timezone-support.asciidoc[] | ||
|
||
:fileset_ex!: | ||
|
||
//set the fileset name used in the included example | ||
:fileset_ex: log | ||
|
||
include::../include/config-option-intro.asciidoc[] | ||
|
||
[float] | ||
==== `log` fileset settings | ||
|
||
include::../include/var-paths.asciidoc[] | ||
|
||
include::../include/timezone-support.asciidoc[] | ||
|
||
:fileset_ex!: | ||
|
||
:modulename!: | ||
|
||
|
||
[float] | ||
=== Fields | ||
|
||
For a description of each field in the module, see the | ||
<<exported-fields-zookeeper,exported fields>> section. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
- module: zookeeper | ||
# All logs | ||
audit: | ||
enabled: true | ||
|
||
# Set custom paths for the log files. If left empty, | ||
# Filebeat will choose the paths depending on your OS. | ||
#var.paths: | ||
# All logs | ||
log: | ||
enabled: true | ||
|
||
# Set custom paths for the log files. If left empty, | ||
# Filebeat will choose the paths depending on your OS. | ||
#var.paths: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,80 @@ | ||
:modulename: zookeeper | ||
:has-dashboards: false | ||
|
||
== ZooKeeper module | ||
|
||
The +{modulename}+ module collects and parses the logs created by https://zookeeper.apache.org/[Apache ZooKeeper] | ||
|
||
include::../include/what-happens.asciidoc[] | ||
|
||
include::../include/gs-link.asciidoc[] | ||
|
||
[float] | ||
=== Compatibility | ||
|
||
The +{modulename}+ module was tested with logs from versions 3.7.0. | ||
|
||
include::../include/configuring-intro.asciidoc[] | ||
|
||
The following example shows how to set paths in the +modules.d/{modulename}.yml+ | ||
file to override the default paths for logs: | ||
|
||
[source,yaml] | ||
----- | ||
- module: zookeeper | ||
audit: | ||
enabled: true | ||
var.paths: | ||
- "/path/to/logs/zookeeper_audit.log*" | ||
log: | ||
enabled: true | ||
var.paths: | ||
- "/path/to/logs/zookeeper.log*" | ||
----- | ||
|
||
|
||
To specify the same settings at the command line, you use: | ||
|
||
[source,yaml] | ||
----- | ||
-M "zookeeper.audit.var.paths=[/path/to/logs/zookeeper_audit.log*]" -M "zookeeper.log.var.paths=[/path/to/logs/zookeeper.log*]" | ||
----- | ||
|
||
[float] | ||
=== Audit logging | ||
|
||
Audit logging is available since Zookeeper 3.6.0, but it is disabled by default. To enable it, you can add the following setting to the configuration file: | ||
["source","sh"] | ||
---------------------- | ||
audit.enable=true | ||
---------------------- | ||
|
||
//set the fileset name used in the included example | ||
:fileset_ex: audit | ||
|
||
include::../include/config-option-intro.asciidoc[] | ||
|
||
[float] | ||
==== `audit` fileset settings | ||
|
||
include::../include/var-paths.asciidoc[] | ||
|
||
include::../include/timezone-support.asciidoc[] | ||
|
||
:fileset_ex!: | ||
|
||
//set the fileset name used in the included example | ||
:fileset_ex: log | ||
|
||
include::../include/config-option-intro.asciidoc[] | ||
|
||
[float] | ||
==== `log` fileset settings | ||
|
||
include::../include/var-paths.asciidoc[] | ||
|
||
include::../include/timezone-support.asciidoc[] | ||
|
||
:fileset_ex!: | ||
|
||
:modulename!: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
- key: zookeeper | ||
title: "ZooKeeper" | ||
release: beta | ||
description: > | ||
ZooKeeper Module | ||
fields: | ||
- name: zookeeper | ||
type: group | ||
description: > | ||
fields: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
- name: audit | ||
type: group | ||
description: > | ||
ZooKeeper Audit logs. | ||
release: beta | ||
fields: | ||
- name: session | ||
type: keyword | ||
description: > | ||
Client session id | ||
- name: znode | ||
type: keyword | ||
description: > | ||
Path of the znode | ||
- name: znode_type | ||
type: keyword | ||
description: > | ||
Type of znode in case of creation operation | ||
- name: acl | ||
type: keyword | ||
description: > | ||
String representation of znode ACL like cdrwa(create, delete,read, write, admin). This is logged only for setAcl operation | ||
- name: result | ||
type: keyword | ||
description: > | ||
Result of the operation. Possible values are (success/failure/invoked). Result "invoked" is used for serverStop operation because stop is logged before ensuring that server actually stopped. | ||
- name: user | ||
type: keyword | ||
description: > | ||
Comma separated list of users who are associate with a client session |
Oops, something went wrong.