Switch CLI Reference Guide

Syslog Commands

show logging-server
Command Objective

This command displays the information about the syslog logging server table.

Syntax

show logging-server

ModePrivileged EXEC Mode
show logging
Command Objective

This command displays all the logging status and configuration information.

Syntax

show logging

ModePrivileged EXEC Mode
logging
Command Objective

This command enables syslog server and configures the syslog related parameters The logging process controls the distribution of logging messages to the various destinations.

Syntax

logging severity { alerts | critical | debugging | emergencies | errors | informational | notification | warnings }

Parameter Description
  • severity - Message severity level. Messages with severity level equal to or high than the specified value are printed asynchronously. This can be configured using numerical value or using the available option. The options are:

    • 0 | emergencies - System is unusable

    • 1 | alerts - Immediate action needed.

    • 2 | critical - Critical conditions.

    • 3 | errors - Error conditions.

    • 4 | warnings - Warning conditions.

    • 5 | notification - Normal but significant conditions.

    • 6 | informational - Informational messages.

    • 7 | debugging - Debugging messages.

ModeGlobal Configuration Mode
logging-service
Command Objective

This command enables/disables syslog server.

Syntax

logging-service { enable | disable }

Parameter Description
  • enable - Syslog enabled.

  • disable - Syslog disabled.

ModeGlobal Configuration Mode
clear logs
Command Objective

This command clears the system syslog buffers.

Syntax

clear logs

ModeGlobal Configuration Mode
logging server
Command Objective

This command configures a server table to log an entry in it.

The no form of command deletes an entry from the server table.

Syntax

logging-server {facility {local0 | local1 | local2 | local3 | local4

| local5 | local6 | local7}} {severity { emergencies | alerts | critical | errors | warnings | notification | informational| debugging}} {ipv4 <ucast_addr> |ipv6 <ip6_addr> | <string>} [ port <integer(0-65535)>]

Parameter Description
  • facility - The facility that is indicated in the message. Can be one of the following values: local0, local1, local2, local3, local4, local5, local 6, local7..

  • severity - Message severity level. Messages with severity level equal to or high than the specified value are printed asynchronously. This can be configured using numerical value or using the available option. The options are:

    • 0 | emergencies - System is unusable

    • 1 | alerts - Immediate action needed.

    • 2 | critical - Critical conditions.

    • 3 | errors - Error conditions.

    • 4 | warnings - Warning conditions.

    • 5 | notification - Normal but significant conditions.

    • 6 | informational - Informational messages.

    • 7 | debugging - Debugging messages.

  • ipv4 <ucast_addr> - Sets the server address type as internet protocol version 4.

  • ipv6 <ip6_addr> - Sets the server address type as internet protocol version 6.

  • <string> - Configures the host name for a server to log an entry.

  • port<integer(0-65535)> - Sets the port number through which it sends the syslog message. The value ranges between 0 and 65535.

ModeGlobal Configuration Mode

Was This Article Helpful?

Help us to improve our support portal

Techdocs Article Helpful form

Techdocs Article NOT Helpful form

  • Still can't find what you're looking for? Try our knowledge base or ask our community for more help.