swift/etc/drive-audit.conf-sample
Tim Burke 405a2b2a55 py3: Fix swift-drive-audit
Walking through the kernel logs backwards requires that we open them
in binary mode. Add a new option to allow users to specify which
encoding should be used to interpret those logs; default to the same
encoding that open() uses for its default.

Change-Id: Iae332bb58388b5521445e75beba6ee2e9f06bfa6
Closes-Bug: #1847955
2019-10-13 21:55:58 -07:00

43 lines
1.4 KiB
Plaintext

[drive-audit]
# Set owner of the drive-audit recon cache to this user:
# user = swift
#
# device_dir = /srv/node
#
# You can specify default log routing here if you want:
# log_name = drive-audit
# log_facility = LOG_LOCAL0
# log_level = INFO
# log_address = /dev/log
# The following caps the length of log lines to the value given; no limit if
# set to 0, the default.
# log_max_line_length = 0
#
# minutes = 60
# error_limit = 1
# recon_cache_path = /var/cache/swift
# unmount_failed_device = True
#
# By default, drive-audit logs only to syslog. Setting this option True
# makes drive-audit log to console in addition to syslog.
# log_to_console = False
#
# Location of the log file with globbing
# pattern to check against device errors.
# log_file_pattern = /var/log/kern.*[!.][!g][!z]
#
# On Python 3, the encoding to use when reading the log file. Defaults
# to the result of locale.getpreferredencoding(), like Python's open().
# log_file_encoding = auto
#
# Regular expression patterns to be used to locate
# device blocks with errors in the log file. Currently
# the default ones are as follows:
# \berror\b.*\b(sd[a-z]{1,2}\d?)\b
# \b(sd[a-z]{1,2}\d?)\b.*\berror\b
# One can overwrite the default ones by providing
# new expressions using the format below:
# Format: regex_pattern_X = regex_expression
# Example:
# regex_pattern_1 = \berror\b.*\b(dm-[0-9]{1,2}\d?)\b