Дерево страниц
Перейти к концу метаданных
Переход к началу метаданных

SYSLOG message filters are set up in the LOGFILTER mode. This mode is available from the CONFIG mode.

To configure a custom SYSLOG filter, run the command:

ma4000(config)# logging filter <NAME>
ma4000(pp4x-config-log-filter-<NAME>)#

where <NAME> – filter name.

To set a predefined SYSLOG filter for a given PLC8 or PP4X module (by default), execute the command:

ma4000(pp4x-config)# logging builtin-filter <NAME>
ma4000(pp4x-config-log-filter-<NAME>)#

where <NAME> – PLC8 or PP4X module name, may take values: 'pp' 'pp-other' 'slot0' 'slot1' 'slot2' 'slot3' 'slot4' 'slot5' 'slot6' 'slot7' 'slot8' 'slot9' 'slot10' 'slot11' 'slot12' 'slot13' 'slot14' 'slot15'.

destination

This command configures the destination for outputting SYSLOG messages of the filter being configured:

  • to the file;
  • to the console;
  • to the remote host.

The use of a negative form (no) of the command cancels the specified direction.

Syntax     

[no] destination <TYPE>

Parameters

<TYPE> – SYSLOG message destination:

  • console – output to the console;
  • file – output to the file, specified in the format: file <FILE>, where: <FILE> – file name in the local file system;
  • host – output to the remote address, specified in the format: host <HOST> port <PORT> transport <TRANSPORT>, where:
    • <HOST> – remote host IP address;
    • <PORT> – connection port number [1..65535];
    • <TRANSPORT> – connection protocol: tcp, udp.
  • monitor – output to the PC monitor.

Command mode

LOG FILTER

Example

ma4000(pp4x-config-log-filter-test)# destination console

match-source

This command configures the message source for analysis: PP4X module (master/slave), PLC8 module number. Multiple sources can be set for analysis.

For the filter to be active, you must specify at least one source.

The use of a negative form (no) of the command cancels the specified source analysis.

Syntax     

[no] match-source  <SOURCE>

Parameters

<SOURCE> – source, used for SYSLOG messages analysis:

  • pp – master PP4X board;
  • pp-other – slave PP4X board;
  • slot – slot number, specified in the format: slot <num>, where:
  • <num> – slot number [0..15].

Command mode

LOG FILTER

Example

ma4000(pp4x-config-log-filter-test)# match-source pp-other	

facility

This command specifies the level of SYSLOG messages to be analyzed.

The use of a negative form (no) of the command cancels the specified analysis level.

Syntax     

[no] facility <FACILITY> <SEVERITY>

Parameters

<FACILITY> – SYSLOG message source class:

  • kernel  – core;
  • user – user level;
  • any – any.

<SEVERITY> – syslog message level: 'emerg', 'alert', 'crit', 'error', 'warning', 'notice', 'info', 'debug'.

Command mode

LOG FILTER

Example

ma4000(pp4x-config-log-filter-test)# facility all debug	

match

This command adds a regexp expression that serves as a filter. The line entering the filter must be checked by this expression.

The use of the not-match command configures the regexp filter for the opposite purpose – the incoming line should NOT be checked by this expression.

The use of a negative form (no) of the command removes the regexp filter.

Syntax     

match <REGEXP>
not-match <REGEXP>
no match

Parameters

<REGEXP> – regular expression, string up to 63 characters.         

Command mode

LOG FILTER

Example

ma4000(pp4x-config-log-filter-test)# no match		
  • Нет меток