Chat now with support
Chat with Support

syslog-ng Premium Edition 7.0.22 - Administration Guide

Preface Introduction to syslog-ng The concepts of syslog-ng Installing syslog-ng The syslog-ng PE quick-start guide The syslog-ng PE configuration file Collecting log messages — sources and source drivers
How sources work default-network-drivers: Receive and parse common syslog messages internal: Collecting internal messages file: Collecting messages from text files google-pubsub: collecting messages from the Google Pub/Sub messaging service wildcard-file: Collecting messages from multiple text files linux-audit: Collecting messages from Linux audit logs mssql, oracle, sql: collecting messages from an SQL database network: Collecting messages using the RFC3164 protocol (network() driver) office365: Fetching logs from Office 365 osquery: Collect and parse osquery result logs pipe: Collecting messages from named pipes program: Receiving messages from external applications python: writing server-style Python sources python-fetcher: writing fetcher-style Python sources snmptrap: Read Net-SNMP traps syslog: Collecting messages using the IETF syslog protocol (syslog() driver) system: Collecting the system-specific log messages of a platform systemd-journal: Collecting messages from the systemd-journal system log storage systemd-syslog: Collecting systemd messages using a socket tcp, tcp6, udp, udp6: Collecting messages from remote hosts using the BSD syslog protocol udp-balancer: Receiving UDP messages at very high rate unix-stream, unix-dgram: Collecting messages from UNIX domain sockets windowsevent: Collecting Windows event logs
Sending and storing log messages — destinations and destination drivers
elasticsearch2: Sending messages directly to Elasticsearch version 2.0 or higher (DEPRECATED) elasticsearch-http: Sending messages to Elasticsearch HTTP Event Collector file: Storing messages in plain-text files google_pubsub: Sending logs to the Google Cloud Pub/Sub messaging service hdfs: Storing messages on the Hadoop Distributed File System (HDFS) http: Posting messages over HTTP kafka: Publishing messages to Apache Kafka logstore: Storing messages in encrypted files mongodb: Storing messages in a MongoDB database network: Sending messages to a remote log server using the RFC3164 protocol (network() driver) pipe: Sending messages to named pipes program: Sending messages to external applications python: writing custom Python destinations sentinel: Sending logs to the Microsoft Azure Sentinel cloud snmp: Sending SNMP traps smtp: Generating SMTP messages (email) from logs splunk-hec: Sending messages to Splunk HTTP Event Collector sql: Storing messages in an SQL database stackdriver: Sending logs to the Google Stackdriver cloud syslog: Sending messages to a remote logserver using the IETF-syslog protocol syslog-ng(): Forward logs to another syslog-ng node tcp, tcp6, udp, udp6: Sending messages to a remote log server using the legacy BSD-syslog protocol (tcp(), udp() drivers) unix-stream, unix-dgram: Sending messages to UNIX domain sockets usertty: Sending messages to a user terminal — usertty() destination Client-side failover
Routing messages: log paths, flags, and filters Global options of syslog-ng PE TLS-encrypted message transfer Advanced Log Transfer Protocol Reliability and minimizing the loss of log messages Manipulating messages parser: Parse and segment structured messages Processing message content with a pattern database Correlating log messages Enriching log messages with external data Monitoring statistics and metrics of syslog-ng Multithreading and scaling in syslog-ng PE Troubleshooting syslog-ng Best practices and examples The syslog-ng manual pages Glossary

Preface

Welcome to the syslog-ng Premium Edition 7 Administration Guide.

This document describes how to configure and manage syslog-ng Premium Edition (syslog-ng PE). Background information for the technology and concepts used by the product is also discussed.

Summary of contents

Introduction to syslog-ng describes the main functionality and purpose of syslog-ng PE.

The concepts of syslog-ng discusses the technical concepts and philosophies behind syslog-ng PE.

Installing syslog-ng describes how to install syslog-ng PE on various UNIX-based platforms using the precompiled binaries.

The syslog-ng PE quick-start guide provides a briefly explains how to perform the most common log collecting tasks with syslog-ng PE.

The syslog-ng PE configuration file discusses the configuration file format and syntax in detail, and explains how to manage large-scale configurations using included files and reusable configuration snippets.

Collecting log messages — sources and source drivers explains how to collect and receive log messages from various sources.

Sending and storing log messages — destinations and destination drivers describes the different methods to store and forward log messages.

Routing messages: log paths, flags, and filters explains how to route and sort log messages, and how to use filters to select specific messages.

Global options of syslog-ng PE lists the global options of syslog-ng PE and explains how to use them.

TLS-encrypted message transfer shows how to secure and authenticate log transport using TLS encryption.

Advanced Log Transfer Protocol shows how to log using the Advanced Log Transfer Protocol protocol.

Manipulating messages describes how to customize message format using templates and macros, how to rewrite and modify messages, and how to use regular expressions.

parser: Parse and segment structured messages describes how to segment and process structured messages like comma-separated values.

Processing message content with a pattern database explains how to identify and process log messages using a pattern database.

Correlating log messages details how to correlate log messages.

Enriching log messages with external data details how to import data from external sources to include in the log messages, thus extending, enriching, and complementing the data found in the log message.

Monitoring statistics and metrics of syslog-ng details the available statistics that syslog-ng PE collects about the processed log messages.

Multithreading and scaling in syslog-ng PE describes how to configure syslog-ng PE to use multiple processors, and how to optimize its performance.

Troubleshooting syslog-ng offers tips to solving problems.

Best practices and examples gives recommendations to configure special features of syslog-ng PE.

The syslog-ng manual pages contains the manual pages of the syslog-ng PE application.

Target audience and prerequisites

This guide is intended for system administrators and consultants responsible for designing and maintaining logging solutions and log centers. It is also useful for IT decision makers looking for a tool to implement centralized logging in heterogeneous environments.

The following skills and knowledge are necessary for a successful syslog-ng administrator:

  • At least basic system administration knowledge.

  • An understanding of networks, TCP/IP protocols, and general network terminology.

  • Working knowledge of the UNIX or Linux operating system.

  • In-depth knowledge of the logging process of various platforms and applications.

  • An understanding of the legacy syslog (BSD-syslog) protocol and the new syslog (IETF-syslog) protocol standard.

Summary of changes

This section lists the changes of The syslog-ng Premium Edition(syslog-ng PE) Administration Guide.

Version 7.0.21 - 7.0.22

Version 7.0.22 of syslog-ng PE includes the following main features.

  • Collecting messages from Google Pub/Sub with the google-pubsub() source.

    For more information, see google-pubsub: collecting messages from the Google Pub/Sub messaging service.

  • More robust upgrade from syslog-ng PE 6LTS

    NOTE: The upgrade from syslog-ng PE 6LTS has been made more robust starting with this version. If you are upgrading from syslog-ng PE 6LTS, first upgrade to the latest available syslog-ng PE 6LTS release, then upgrade to syslog-ng PE 7LTS.

Version 7.0.20 - 7.0.21

Version 7.0.21 of syslog-ng PE includes the following main features.

Version 7.0.19 - 7.0.20

Version 7.0.20 of syslog-ng PE includes the following main features.

  • Red Hat EL 8 support

    Starting with version 7.0.20, syslog-ng PE supports Red Hat EL 8 (kernel version 4.18).

    For more information, see Supported platforms and udp-balancer: Receiving UDP messages at very high rate.

  • SNMP destination

    The snmp() destination of syslog-ng PE can send log messages to an SNMP destination.

    For more information, see snmp: Sending SNMP traps.

  • The syslog-ng PE application uses its own Python interpreter

    Starting from version 7.0.20, the syslog-ng PE application uses its own Python interpreter (shipped with the default syslog-ng PE installation) instead of the system's Python interpreter.

    NOTE: The syslog-ng PE application's built-in Python interpreter only supports Python 3. As a result, any custom Python code used in syslog-ng PE must be compatible with Python 3.

  • Disabling and forcing TLSv1.3 in TLS contexts
    • The tlsv1_3 value has been added to the available values of ssl-version() for drivers based on the http() destination.

    • The no-tlsv13 value has been added to the available values of ssl-options() in TLS contexts.

  • New statistics item: the connections counter

    The connections counter of syslog-ng PE displays the number of active connections for network-based sources in the syslog-ng-ctl stats statistics information.

    For more information, see connections statistics counter.

Version 7.0.18 - 7.0.19

Version 7.0.19 of syslog-ng PE includes the following main features.

  • Sending logs to Microsoft Azure Sentinel

    Version 7.0.19 of syslog-ng PE can directly post log messages to the Microsoft Azure Sentinel cloud using Microsoft Azure Sentinel's public HTTP Data Collector API interface.

    For more information, see sentinel: Sending logs to the Microsoft Azure Sentinel cloud.

  • Persist name assigned to Python sources and destinations

    NOTE: Starting with 7.0.19, syslog-ng PE assigns a persist name to Python sources and destinations. The persist name is generated from the class name. If you want to use the same Python class multiple times in your syslog-ng PE configuration, add a unique persist-name() to each source or destination, otherwise syslog-ng PE will not start. For example:

    log {
        source { python(class(PyNetworkSource) options("port" "8080") persist-name("<unique-string>); };
        source { python(class(PyNetworkSource) options("port" "8081")); };
      };

    Alternatively, you can include the following line in the Python package: @staticmethod generate_persist_name. For example:

    from syslogng import LogSource
      class PyNetworSource(LogSource):
        @staticmethod
        def generate_persist_name(options):
            return options["port"]
        def run(self):
            pass
        def request_exit(self):
            pass
  • OpenSSL version 1.1.1d

    From version 7.0.19, syslog-ng PE supports OpenSSL 1.1.1d for Linux glibc 2.11 and Ubuntu Bionic.

    For more information, see Prerequisites to installing syslog-ng PE.

  • Changes in documentation
Version 7.0.14 - 7.0.16
Changes in product
Changes in documentation
Version 7.0.14 - 7.0.16
Changes in product
Changes in documentation
Version 7.0.13 - 7.0.14
Changes in product
Version 7.0.12 - 7.0.13
Changes in product
  • The Linux Audit Parser can parse the log messages of the Linux Audit subsystem (auditd). The syslog-ng PE application can separate these log messages to name-value pairs. For details, see "Linux audit parser" in the Administration Guide.

  • The windowsevent() source can now automatically process XML arrays, making the array elements available as name-value pairs. For details, see "windowsevent: Collecting Windows event logs" in the Administration Guide.

  • Installing the syslog-ng Premium Edition application in Docker containers is now officially supported on CentOS 7, Red Hat EL 7.5, and Ubuntu 18.04 (Bionic Beaver) platforms. For details, see "Installing syslog-ng in Docker" in the Administration Guide.

  • The persist-tool utility is now part of the syslog-ng PE package. For details, see the persist-tool manual page.

  • Since ElasticSearch version 1.x has reached its end of life, its support has been removed from syslog-ng PE. Use the elasticsearch2 destination instead.

Version 7.0.11 - 7.0.12
Changes in product
  • Version 7.0.12 of syslog-ng PE can directly post log messages to a Splunk deployment using the HTTP Event Collector (HEC) over the HTTP and Secure HTTP (HTTPS) protocols. The solution is optimized for performance, and supports sending messages in batch mode, multithreaded message sending, and load-balancing to multiple Splunk indexer nodes.

    HTTPS connection, as well as password- and certificate-based authentication is supported. The content of the events is sent in JSON format.

    For details, see "splunk-hec: Sending messages to Splunk HTTP Event Collector" in the Administration Guide.

  • The http() destination now supports load balancing, so a single syslog-ng PE instance can feed log data to multiple HTTP servers, for example, multiple ingestion nodes of an Elasticsearch cluster. For details, see "Batch mode and load balancing" in the Administration Guide.

    HTTP and HTTPS redirections now also handled automatically.

  • The syslog() and network() drivers now support the so-reuseport() option that allows multiple sockets on the same host to bind to the same port, improving the performance of multithreaded network server applications running on top of multicore systems.

  • The Cisco parser now supports Cisco Catalyst formatted triplets.

  • Version 7.0.12 of syslog-ng PE is now available on the Ubuntu 18.04 platform. Note that the Java-based drivers of syslog-ng PE (used for Apache Kafka, Elasticsearch, HDFS) require Java 8, Java 10 is not supported.

  • The allow-compress() option of the ALTP communication has been renamed to allow-plain-compress().

Version 7.0.10 - 7.0.11
Changes in product
Changes in documentation

Extending syslog-ng PE in Python has been supported for several releases, but so far this feature was mostly undocumented. Now you can find more details about this feature in "python: writing custom Python destinations" in the Administration Guide.

Version 7.0.9 - 7.0.10
Changes in product
  • It is now possible to not only receive but also send messages using ALTP to hosts that are running version 6 or at least version 7.0.9 of syslog-ng PE or the syslog-ng Agent for Windows application. For details, see Advanced Log Transfer Protocol .
  • The global flush-lines() option does not affect the batch size of ALTP any more. Instead, a new ALTP has been introduced, called batch-size(). For details, see ALTP options.
  • The failover() option allows you to specify what happens after syslog-ng PE fails over to a secondary server. Additionally, the failover-servers() option has been deprecated and removed from the document. For more information about the failover() option, see Client-side failover.

  • You can now refer to any additional parameters at the end of the argument in a block by adding three dots to it (). It tells syslog-ng PE that this macro accepts `__VARARGS__`, therefore any name-value pair can be passed without validation. For details, see Passing arguments to configuration blocks.

  • You can now make parameters mandatory in block definitions by defining them with empty brackets (). For details, see Mandatory parameters.

Changes in documentation
  • A note about JVM still running after deleting all Java destinations and reloading syslog-ng has been added to the description of Java destinations.

  • The default value of the --skip-tokens parameter of the loggen application has been changed to 0. For details, see The loggen manual page.

Version 7.0.8 - 7.0.9
Changes in product
Version 7.0.7 - 7.0.8
Changes in product
  • A new log path flag, drop-unmatched, has been added. The new flag causes messages to be dropped along a log path when they do not match a filter or are discarded by a parser. For details, see "Log path flags" in the Administration Guide.

  • Support for Elasticsearch's Shield has been removed.

  • Support for POSIX regular expressions has been removed.

    All "posix" regular expressions are automatically switched to "pcre". In case you have POSIX regular expressions configured, ensure that they work with PCRE, and also specify type("pcre") explicitly.

Version 7.0.6 - 7.0.7
Changes in product
Changes in documentation
Version 7.0.5 - 7.0.6
Changes in product
Changes in documentation
Version 7.0.4 - 7.0.5
Changes in product
Changes in documentation
Version 7.0.3 - 7.0.4
Changes in product
Changes in documentation
  • Several corrections and editorial changes.

Version 7.0.2 - 7.0.3
Changes in product
Changes in documentation
Version 7.0 - 7.0.2
Changes in product
Changes in documentation
  • Several corrections and editorial changes.

Version 6 LTS - 7.0
Changes in product

Several features that are available in syslog-ng Premium Edition 6 LTS are not yet available in syslog-ng PE 7. For a list of features that are available in syslog-ng PE 6 LTS but not in 7 see "Differences in features between syslog-ng PE 6 LTS and 7" in the Release Notes.

Changes in documentation
Self Service Tools
Knowledge Base
Notifications & Alerts
Product Support
Software Downloads
Technical Documentation
User Forums
Video Tutorials
RSS Feed
Contact Us
Licensing Assistance
Technical Support
View All
Related Documents