Movatterモバイル変換


[0]ホーム

URL:


Loading

Syslog input plugin v3.4.5

For other versions, see theoverview list.

To learn more about Logstash, see theLogstash Reference.

For questions about the plugin, open a topic in theDiscuss forums. For bugs or feature requests, open an issue inGithub. For the list of Elastic supported plugins, please consult theElastic Support Matrix.

Read syslog messages as events over the network.

This input is a good choice if you already use syslog today. It is also a good choice if you want to receive logs from appliances and network devices where you cannot run your own log collector.

Of course,syslog is a very muddy term. By default, this input only supportsRFC3164 syslog with some small modifications. However, some non-standard syslog formats can be read and parsed if a functionalgrok_pattern is provided. The date format is still only allowed to beRFC3164 style orISO8601.

For more information see theRFC3164 page.

Note: This input will start listeners on both TCP and UDP.

This plugin supports the following configuration options plus theCommon options described later.

Also seeCommon options for a list of options supported by all input plugins.

  • Value type isarray
  • Default value is["kernel", "user-level", "mail", "system", "security/authorization", "syslogd", "line printer", "network news", "UUCP", "clock", "security/authorization", "FTP", "NTP", "log audit", "log alert", "clock", "local0", "local1", "local2", "local3", "local4", "local5", "local6", "local7"]

Labels for facility levels defined in RFC3164.

You can use this option to override the integer→label mapping for syslog inputs that behave differently than the RFCs.

Provide a zero-indexed array with all of your facility labelsin order. If a log message contains a facility number with no corresponding entry, the facility_label is not added to the event.

  • Value type isstring
  • Default value is"<%{POSINT:priority}>%{{SYSLOGLINE}}"

The default value should read and properly parse syslog lines which are fully compliant withRFC3164.

You can override this value to parse non-standard lines with a valid grok pattern which will parse the received lines. If the line is unable to be parsed, the_grokparsefailure_sysloginput tag will be added.

The grok pattern must provide atimestamp field. If thetimestamp field is omitted, or is unable to be parsed asRFC3164 style orISO8601, a_dateparsefailure tag will be added.

  • Value type isstring
  • Default value is"0.0.0.0"

The address to listen on.

  • Value type isstring
  • There is no default value for this setting.

Specify a locale to be used for date parsing using either IETF-BCP47 or POSIX language tag. Simple examples areen,en-US for BCP47 oren_US for POSIX. If not specified, the platform default will be used.

The locale is mostly necessary to be set for parsing month names (pattern with MMM) and weekday names (pattern with EEE).

  • Value type isnumber
  • Default value is514

The port to listen on. Remember that ports less than 1024 (privileged ports) may require root to use.

  • Value type isboolean
  • Default value isfalse

Proxy protocol support, only v1 is supported at this timehttp://www.haproxy.org/download/1.5/doc/proxy-protocol.txt

  • Value type isarray
  • Default value is["Emergency", "Alert", "Critical", "Error", "Warning", "Notice", "Informational", "Debug"]

Labels for severity levels defined in RFC3164.

Provide a zero-indexed array with all of your severity labelsin order. If a log message contains a severity label with no corresponding entry, the severity_label is not added to the event.

  • Value type isstring
  • Default value is"message"

Codecs process the data before the rest of the data is parsed. Some codecs, like CEF, put the syslog data into another field after pre-processing the data. Use this option in conjunction with thegrok_pattern configuration to allow the syslog input plugin to fully parse the syslog data in this case.

input {  syslog {    port => 12345    codec => cef    syslog_field => "syslog"    grok_pattern => "<%{POSINT:priority}>%{SYSLOGTIMESTAMP:timestamp} CUSTOM GROK HERE"  }}
  • Value type isstring
  • There is no default value for this setting.

Specify a time zone canonical ID to be used for date parsing. The valid IDs are listed on theJoda.org available time zones page. This is useful in case the time zone cannot be extracted from the value, and is not the platform default. If this is not specified the platform default will be used. Canonical ID is good as it takes care of daylight saving time for you. For example,America/Los_Angeles orEurope/Paris are valid IDs.

  • Value type isboolean
  • Default value istrue

Use label parsing for severity and facility levels.

These configuration options are supported by all input plugins:

  • Value type ishash
  • Default value is{}

Add a field to an event

  • Value type iscodec
  • Default value is"plain"

The codec used for input data. Input codecs are a convenient method for decoding your data before it enters the input, without needing a separate filter in your Logstash pipeline.

  • Value type isboolean
  • Default value istrue

Disable or enable metric logging for this specific plugin instance by default we record all the metrics we can, but you can disable metrics collection for a specific plugin.

  • Value type isstring
  • There is no default value for this setting.

Add a uniqueID to the plugin configuration. If no ID is specified, Logstash will generate one. It is strongly recommended to set this ID in your configuration. This is particularly useful when you have two or more plugins of the same type, for example, if you have 2 syslog inputs. Adding a named ID in this case will help in monitoring Logstash when using the monitoring APIs.

input {  syslog {    id => "my_plugin_id"  }}
  • Value type isarray
  • There is no default value for this setting.

Add any number of arbitrary tags to your event.

This can help with processing later.

  • Value type isstring
  • There is no default value for this setting.

Add atype field to all events handled by this input.

Types are used mainly for filter activation.

The type is stored as part of the event itself, so you can also use the type to search for it in Kibana.

If you try to set a type on an event that already has one (for example when you send an event from a shipper to an indexer) then a new input will not override the existing type. A type set at the shipper stays with that event for its life even when sent to another Logstash server.

Welcome to the docs for thelatest Elastic product versions, including Elastic Stack 9.0 and Elastic Cloud Serverless.To view previous versions, go toelastic.co/guide.


[8]ページ先頭

©2009-2025 Movatter.jp