From 11fef2ceeebb0ceed214071c49b80bb2c2f6ed3e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?No=C3=A9mi=20V=C3=A1nyi?= Date: Tue, 14 Jul 2020 10:13:22 +0200 Subject: [PATCH] doc fixes --- .../docs/inputs/input-common-file-options.asciidoc | 4 ++-- filebeat/docs/inputs/input-log.asciidoc | 12 +++++++----- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/filebeat/docs/inputs/input-common-file-options.asciidoc b/filebeat/docs/inputs/input-common-file-options.asciidoc index be64eb20ad2e..b52e4660d44d 100644 --- a/filebeat/docs/inputs/input-common-file-options.asciidoc +++ b/filebeat/docs/inputs/input-common-file-options.asciidoc @@ -406,7 +406,7 @@ limit of harvesters. ===== `file_identity` Different `file_identity` methods can be configured to suit the -environment you are collecting log messages from. +environment where you are collecting log messages. *`inode_deviceid`*:: The default behaviour of {beatname_uc} is to differentiate @@ -433,7 +433,7 @@ file_identity.path: ~ ---- *`inode_marker`*:: If the device id changes from time to time, you must use -this method to tell apart files. Set the location of the marker file the following way: +this method to distinguish files. Set the location of the marker file the following way: [source,yaml] ---- diff --git a/filebeat/docs/inputs/input-log.asciidoc b/filebeat/docs/inputs/input-log.asciidoc index 42ff673c924c..0a69a9b65c29 100644 --- a/filebeat/docs/inputs/input-log.asciidoc +++ b/filebeat/docs/inputs/input-log.asciidoc @@ -70,12 +70,12 @@ device IDs. However, on network shares and cloud providers these values might change during the lifetime of the file. If this happens {beatname_uc} thinks that file is new and resends the whole content of the file. To solve this problem you can configure `file_identity` option. Possible -values are besides the default `inode_deviceid` are `path` and `inode_marker`. +values besides the default `inode_deviceid` are `path` and `inode_marker`. Selecting `path` instructs {beatname_uc} to identify files based on their paths. This is a quick way to aviod rereading files if inode and device ids might change. However, keep in mind if the files are rotated (renamed), they -are going to be reread and resent. +will be reread and resubmitted. The option `inode_marker` can be used if the inodes stay the same even if the device id is changed. You should choose this method if your files are @@ -85,7 +85,8 @@ readable by {beatname_uc} and set the path in the option `path` of `inode_marker The content of this file must be unique to the device. You can put the UUID of the device or mountpoint where the input is stored. The following example oneliner generates a hidden marker file for the selected mountpoint `/logs`: -Please note that you should not use this option on Windows. +Please note that you should not use this option on Windows as file identifiers might be +more volatile. ["source","sh",subs="attributes"] ---- @@ -114,8 +115,9 @@ a pattern that matches the file you want to harvest and all of its rotated files. Also make sure your log rotation strategy prevents lost or duplicate messages. For more information, see <>. -Furthermore, do not use `path` method for `file_identity` to avoid duplication -of the rotated log messages. +Furthermore, to avoid duplicate of rotated log messages, do not use the +`path` method for `file_identity`. Or exclude the rotated files with `exclude_files` +option. [id="{beatname_lc}-input-{type}-options"] ==== Configuration options