Initial commit.

This commit is contained in:
2021-05-24 22:18:33 +03:00
commit e2954d55f4
3701 changed files with 330017 additions and 0 deletions

View File

@@ -0,0 +1,42 @@
###############################################################################
# Log forwarder configuration file example #
# Source: file #
# Available customization parameters: attributes, max_line_kb, pattern #
###############################################################################
logs:
# Basic tailing of a single file
- name: basic-file
file: /var/log/logFile.log
# File with spaces in its path. No need to use quotes.
- name: file-with-spaces-in-path
file: /var/log/folder with spaces/logFile.log
# Specify a list of custom attributes, as key-value pairs, to be included
# in each log record
- name: file-with-attributes
file: /var/log/logFile.log
attributes:
application: tomcat
department: sales
maintainer: example@mailprovider.com
# Use wildcards to refer to multiple files having a common extension or
# prefix. Newly generated files will be automatically detected every 60
# seconds.
#
# WARNING: avoid using wildcards that include the file extension, since
# it'll cause logs to be forwarded repeatedly if log rotation is enabled.
- name: log-files-in-folder
file: /var/log/logF*.log
# Lines longer than 128 KB will be automatically skipped. Use 'max_line_kb'
# to increase this limit.
- name: log-file-with-long-lines
file: /var/log/logFile.log
max_line_kb: 256
# Use 'pattern' to filter records using a regular expression
- name: only-records-with-warn-and-error
file: /var/log/logFile.log
pattern: WARN|ERROR

View File

@@ -0,0 +1,21 @@
###############################################################################
# Log forwarder configuration file example #
# Source: fluentbit #
# Available customization parameters: <none> #
###############################################################################
logs:
# Use an external configuration file in the Fluentbit native format. You can
# also define your own 'parsers.conf' file if your native Fluentbit
# configuration file defines custom parsers for your log records.
#
# WARNING: do not define an output using the 'newrelic' plugin in external
# configuration files, as you'd potentially end up with duplicated log
# records in New Relic. The New Relic agent already sets an output plugin
# for you.
#
# NOTE: 'rfc3164', 'rfc3164-local' and 'rfc5424' are reserved parser names
# and must not be used in your custom parsers.conf
- name: external-fluentbit-config-and-parsers-file
fluentbit:
config_file: /home/user/Configs/fluent-bit.conf
parsers_file: /home/user/Configs/parsers.conf

View File

@@ -0,0 +1,4 @@
# Remember to only use spaces for indentation
logs:
- name: "postfix"
file: /var/log/maillog

View File

@@ -0,0 +1,80 @@
###############################################################################
# Log forwarder configuration file example #
# Source: syslog #
# Available customization parameters: attributes, max_line_kb #
###############################################################################
logs:
# Syslog RFC3164 via TCP IP socket
- name: syslog-tcp-rfc3164
syslog:
uri: tcp://127.0.0.1:5140
parser: rfc3164
# Syslog RFC5424 via TCP IP socket
- name: syslog-tcp-rfc5424
syslog:
uri: tcp://127.0.0.1:5141
parser: rfc5424
# Syslog RFC3164 via UDP IP socket
- name: syslog-udp-rfc3164
syslog:
uri: udp://127.0.0.1:6140
parser: rfc3164
# Syslog RFC5424 via UDP IP socket
- name: syslog-udp-rfc5424
syslog:
uri: udp://127.0.0.1:6141
parser: rfc5424
# General WARNINGS on Syslog via Unix (domain) sockets:
# - Default socket permissions are changed to 0644 by Fluentbit, so only
# processes running as root (if the agent runs as root) or nri-agent (if
# the agent runs as nri-agent) will be able to write to the logs. You can
# use 0666 to allow processes run by other users to write into the socket,
# at your own risk.
# - Sockets must either exist and be readable by the user executing the
# Infrastructure Agent, or defined in a folder where such user can create a
# new socket file.
# Syslog RFC3164 via TCP Unix (domain) socket
- name: syslog-unix-tcp-rfc3164
syslog:
uri: unix_tcp:///home/user/Sockets/unix-tcp-socket-rfc3164
parser: rfc3164
# unix_permissions: 0666
# Syslog RFC5424 via TCP Unix (domain) socket
- name: syslog-unix-tcp-rfc5424
syslog:
uri: unix_tcp:///home/user/Sockets/unix-tcp-socket-rfc5424
parser: rfc5424
# unix_permissions: 0666
# Syslog RFC3164 via UDP Unix (domain) socket
- name: syslog-unix-udp-rfc3164
syslog:
uri: unix_udp:///home/user/Sockets/unix-udp-socket-rfc3164
parser: rfc3164
# unix_permissions: 0666
# Syslog RFC5424 via UDP Unix (domain) socket
- name: syslog-unix-udp-test-rfc5424
syslog:
uri: unix_udp:///home/user/Sockets/unix-udp-socket-rfc5424
parser: rfc5424
# unix_permissions: 0666
# You can optionally include the 'attributes' and 'max_line_kb parameters'
# (refer to file.yml.example or to the official documentation for more
# details)
- name: customized-syslog-tcp-rfc5424
syslog:
uri: tcp://127.0.0.1:5142
parser: rfc5424
attributes:
application: tomcat
department: sales
maintainer: example@mailprovider.com
max_line_kb: 256

View File

@@ -0,0 +1,22 @@
###############################################################################
# Log forwarder configuration file example #
# Source: systemd #
# Available customization parameters: attributes, max_line_kb, pattern #
###############################################################################
logs:
# Systemd 'cupsd' service
# WARNING: Infrastructure Agent must run as *root* to use this source
- name: systemd-cups
systemd: cupsd
# You can optionally include the 'attributes', 'max_line_kb' and 'pattern'
# parameters (refer to file.yml.example or to the official documentation for
# more details)
- name: customized-systemd-cupsd
systemd: cupsd
attributes:
application: tomcat
department: sales
maintainer: example@mailprovider.com
max_line_kb: 256
pattern: WARN|ERROR

View File

@@ -0,0 +1,31 @@
###############################################################################
# Log forwarder configuration file example #
# Source: tcp #
# Available customization parameters: attributes, max_line_kb #
###############################################################################
logs:
# TCP log ingestion with no specific format. Records separated by line breaks.
- name: tcp-with-no-format
tcp:
uri: tcp://127.0.0.1:5170
format: none
separator: \n
# TCP log ingestion in JSON format.
- name: tcp-json
tcp:
uri: tcp://127.0.0.1:5171
format: json
# You can optionally include the 'attributes' and 'max_line_kb' parameters
# (refer to file.yml.example or to the official documentation for more
# details)
- name: customized-tcp-json
tcp:
uri: tcp://127.0.0.1:5172
format: json
attributes:
application: tomcat
department: sales
maintainer: example@mailprovider.com
max_line_kb: 256