configure log target filter

configure log target [console | memory-buffer | | primary-node | | backup-node | nvram | session | syslog [all | ipaddress {udp-port {udp_port}} | ipPort | ipaddress tls-port {tls_port} ]{vr vr_name} {local0...local7}] filter filter-name {severity severity {only}}

Description

Associates a filter to a target.

In a stack, this command is applicable only to Master and Backup nodes. This command is not applicable to standby nodes.

Syntax Description

target Specifies the device to send the log entries.
console Specifies the console display.
memory-buffer Specifies the switch memory buffer.
primary-node Specifies the primary node in a stack.
backup-node Specifies the backup node in a stack.
nvram Specifies the switch NVRAM.
session Specifies the current session (including console display).
syslog Specifies a syslog remote server.
all Specifies all of the syslog remote servers.
ipaddress Specifies the syslog IP address.
ipPort Specifies the UDP port number for the syslog target.
vr_name Specifies the virtual router that can reach the server IP address.
Note: User-created VRs are supported only on the platforms listed for this feature in the ExtremeXOS 22.6 Feature License Requirements document.
local0 ... local7 Specifies the local syslog facility.
filter-name Specifies the filter to associate with the target.
severity Specifies the minimum severity level to send (if the keyword only is omitted).
only Specifies that only the specified severity level is to be sent.

Default

If severity is not specified, the severity level for the target is left unchanged. If a virtual router is not specified, VR-Mgmt is used.

Usage Guidelines

This command associates the specified filter and severity with the specified target. A filter limits messages sent to a target.

Although each target can be configured with its own filter, by default, all targets are associated with the built-in filter, DefaultFilter. Each target can also be configured with its own severity level. This provides the ability to associate multiple targets with the same filter, while having a configurable severity level for each target.

A message is sent to a target if the target has been enabled, the message passes the associated filter, the message is at least as severe as the configured severity level, and the message output matches the regular expression specified. By default, the memory buffer and NVRAM targets are enabled. For other targets, use the command enable log target. The following table describes the default characteristics of each type of target.

Click to expand in new window

Default target log characteristics

Target Enabled Severity Level
console display no info
memory buffer yes debug-data
NVRAM yes warning
session no info
syslog no debug-data

The built-in filter, DefaultFilter, and a severity level of info are used for each new telnet session. These values may be overridden on a per-session basis using the configure log target filter command and specify the target as session. Use the following form of the command for per-session configuration changes:

configure log target session filter filtername {severity severity {only}}

Configuration changes to the current session target are in effect only for the duration of the session, and are not saved in FLASH memory. The session option can also be used on the console display, if the changes are desired to be temporary. If changes to the console-display are to be permanent (saved to FLASH memory), use the following form of the command:

configure log target console filter filtername {severity severity {only}}

SummitStack Only

The backup-node target is only active on the primary-node, and the primary-node target is active on backup-node and standby-nodes.

Example

The following example sends log messages to the previously syslog host at 10.31.8.25, port 8993, and facility local3, that pass the filter myFilter and are of severity warning and above:

configure log target syslog 10.31.8.25:8993 local3 filter myFilter severity warning

The following example sends log messages to the current session, that pass the filter myFilter and are of severity warning and above:

configure log target session filter myFilter severity warning

History

This command was first available in ExtremeXOS 10.1.

The ipPort parameter was first available in ExtremeXOS 11.1.

The udp-port parameter was added in ExtremeXOS 21.1.

Platform Availability