Switch Administration Commands

Switch Name Configuration Commands

Banner Configuration Commands

Prompt Configuration Command

Event Manager Commands

Email Configuration Command

System Clock Commands

NTP Commands

Syslog Configuration Commands

Power Configuration Commands

banner login

The banner login command configures a message that the switch displays before login and password prompts. The login banner is available on console, telnet, and ssh connections.

The no banner login and default banner login commands delete the login banner.

 

Command Mode

Global Configuration

 

Command Syntax

banner login

no banner login

default banner login

 

Parameters
  • banner_text To configure the banner, enter a message when prompted. The message may span multiple lines. Banner text supports the following keywords:
    • $(hostname) displays the switch's host name.
  • EOF To end the banner editing session, type EOF on its own line and press enter.

 

Examples
  • These commands create a two-line login banner.
    switch(config)# banner login
    Enter TEXT message. Type 'EOF' on its own line to end.
    This is a login banner for $(hostname).
    Enter your login name at the prompt.
    EOF
    switch(config)#

     

  • This output displays the login banner.
    This is a login banner for switch.
    Enter your login name at the prompt.
    switch login:john
    Password:
    Last login: Mon Jan 14 09:05:23 2013 from adobe-wrks.aristanetworks.com
    switch>

     

banner motd

The banner motd command configures a message of the day (motd) that the switch displays after a user logs in. The motd banner is available on console, telnet, and ssh connections.

The no banner motd and default banner motd commands delete the motd banner.

 

Command Mode

Global Configuration

 

Command Syntax

banner motd

no banner motd

default banner motd

 

Parameters
  • banner_text To configure the banner, enter a message when prompted. The message may span multiple lines. Banner text supports this keyword:
    • $(hostname) displays the switch's host name.
  • EOF To end the banner editing session, type EOF on its own line and press enter.

     

Examples
  • These commands create an motd banner.
    switch(config)# banner motd
    Enter TEXT message. Type 'EOF' on its own line to end.
    This is an motd banner for $(hostname)
    EOF
    switch(config)#

     

  • This output displays the motd banner.
    switch login: john
    Password:
    Last login: Mon Jan 14 09:17:09 2013 from adobe-wrks.aristanetworks.com
    This is an motd banner for Switch
    switch>

     

clear ptp interface counters

The clear ptp interface counters command resets the Precision Time Protocol (PTP) packet counters.

 

Command Mode

Privileged EXEC

 

Command Syntax

clear ptp interface [INTERFACE_NAME] counters

 

Parameters

INTERFACE_NAME Interface type and numbers. Options include:
  • no parameter Displays information for all interfaces.
    • ethernet e_range Ethernet interface range specified by e_range.
    • loopback l_range Loopback interface specified by l_range.
    • management m_range Management interface range specified by m_range.
    • port-channel p_range Port-Channel Interface range specified by p_range.
    • vlan v_range VLAN interface range specified by v_range.
    • VXLAN vx_range VXLAN interface range specified by vx_range.

       

    Valid parameter formats include number, number range, or comma-delimited list of numbers and ranges.

     

Example

This command clears all PTP counters.
switch# clear ptp counters
switch#

clock set

The clock set command sets the system clock time and date. If the switch is configured with an NTP server, NTP time synchronizations override manually entered time settings.

Time entered by this command is local, as configured by the clock timezone command.

 

Command Mode

Privileged EXEC

 

Command Syntax

clock set hh:mm:ss date

 

Parameters
  • hh:mm:ss is the current time (24-hour notation).
  • date is the current date. Date formats include:
    • mm/dd/yy example: 05/15/2012
    • example: May 15 2012
    • example: 15 May 2012

       

Example

This command manually sets the switch time.
switch# clock set 08:15:24 14 Jan 2013
Mon Jan 14 08:15:25 2013
timezone is US/Central

clock timezone

The clock timezone command specifies the UTC offset that converts system time to local time. The switch uses local time for time displays and to time-stamp system logs and messages.

The no clock timezone and default clock timezone commands delete the timezone statement from running-config, setting local time to UTC.

 

Command Mode

Global Configuration

 

Command Syntax

clock timezone zone_name

no clock timezone

default clock timezone

 

Parameters

zone_name the time zone. Settings include a list of predefined time zone labels.

 

Examples
  • This command configures the switch for the United States Central Time Zone.
    switch(config)# clock timezone US/Central
    switch(config)# show clock
    Fri Jan 11 18:42:49 2013
    timezone is US/Central
    switch(config)#

     

  • To view the predefined time zone labels, enter clock timezone with a question mark.
    switch(config)# clock timezone ?
      Africa/Abidjan                    Africa/Accra
      Africa/Addis_Ababa                Africa/Algiers
      Africa/Asmara                     Africa/Asmera
      Africa/Bamako                     Africa/Bangui
    
      W-SU                              W-SU timezone
      WET                               WET timezone
      Zulu                              Zulu timezone
    
    switch(config)#clock timezone

     

  • This command displays all time zone labels that start with America.
    switch(config)# clock timezone AMERICA?
    America/Adak                    America/Anchorage
    America/Anguilla                America/Antigua
    America/Araguaina               America/Argentina/Buenos_Aires
    
    America/Virgin                  America/Whitehorse
    America/Winnipeg                America/Yakutat
    America/Yellowknife
    
    switch(config)#clock timezone AMERICA

dns domain

The dns domain command configures the switchs domain name. The switch uses this name to complete unqualified host names.

The no dns domain and default dns domain commands delete the domain name by removing the dns domain command from running-config.

 

Command Mode

Global Configuration

 

Command Syntax

dns domain string

no dns domain

default dns domain

 

Parameter

string domain name (text string).

 

Example

This command configures aristanetworks.com as the switchs domain name.
switch(config)# dns domain aristanetworks.com
switch(config)#

email

The email command places the switch in email client configuration mode. If you configure a from-user and an outgoing SMTP server on the switch, you can then use an email address as an output modifier to a show command and receive the output as email.

 

Command Mode

Global Configuration

 

Command Syntax

email

 

Example

This command places the switch in email client configuration mode.
switch(config)# email
switch(config)#

event-monitor backup max-size

The event-monitor backup max-size command specifies the quantity of event monitor backup files the switch maintains. Values range from 1 to 200 files with a default of ten files.

The event-monitor backup path command specifies the path/name of these files. The switch appends an extension to the file name that tracks the creation order of backup files. When the quantity of files exceeds the configured limit, the switch deletes the oldest file.

The no event-monitor backup max-size and default event-monitor backup max-size command restores the default maximum number of backup files the switch can store to ten by removing the corresponding event-monitor backup max-size command from running-config.

 

Command Mode

Global Configuration

 

Command Syntax

event-monitor backup max-size file_quantity

no event-monitor backup max-size

default event-monitor backup max-size

 

Parameter

file_quantity maximum number of backup files. Value ranges from 1 to 200. Default is 10.

 

Example

These commands configure the switch to back up the event buffer to a series of files named sw-event.log. The switch can store a maximum of four files.
switch(config)# event-monitor backup path sw-event.log
switch(config)# event-monitor backup max-size 4
switch(config)#

 

The first five files that the switch creates to store event monitor buffer contents are:

sw-event.log.0

sw-event.log.1

sw-event.log.2

sw-event.log.3

sw-event.log.4

The switch deletes sw-event.log.0 the first time it verifies the number of existing backup files after the creation of sw-event.log.4.

event-monitor backup path

The event-monitor backup path command enables the storage of the event monitor buffer to switch files and specifies the path/name of these files. The command references the file location either from the flash drive root directory (/mnt/flash) where the CLI operates or from the switch root directory (/).

The event monitor buffer is circular after the buffer is filled, new data is written to the beginning of the buffer, replacing old data. At the conclusion of each buffer writing cycle, it is copied into a new backup file before the switch starts re-writing the buffer. The switch appends a extension number to the file name when it creates a new file. After every 500 events, the switch deletes the oldest backup file if the file limit specified by the event-monitor backup max-size command is exceeded.

running-config can contain a maximum of one event-monitor backup path statement. Subsequent event-monitor backup path commands replace the existing statement in running-config, changing the name of the file where event monitor backup files are stored.

The no event-monitor backup path and default event-monitor backup path commands disable the storage of the event monitor buffer to switch files by deleting the event-monitor backup path command from running-config.

 

Command Mode

Global Configuration

 

Command Syntax

event-monitor backup path URL_FILE

no event-monitor backup path

default event-monitor backup path

 

Parameters

URL_FILE path and file name of the backup file:
  • path_string specified path is appended to /mnt/flash/.
  • file: path_string specified path is appended to /.
  • flash: path_string specified path is appended to /mnt/flash/.

     

Example

These commands configure the switch to store the event monitor buffer in sw-event.log, then display the new file in the flash directory.
switch(config)# event-monitor backup path eventmon_backup_dir/event.log
switch(config)#
bash-4.3# ls /mnt/flash/eventmon_backup_dir/

arpevent.log.1  lacpevent.log.1  neighborevent.log.1  routeevent.log.1
igmpsnoopingevent.log.1  macevent.log.1   route6event.log.1    
stpunstableevent.log.1

event-monitor buffer max-size

The event-monitor buffer max-size command specifies the size of the event monitor buffer. The event monitor buffer is a fixed-size circular data structure that receives event records from the event monitor. When event monitor backup is enabled (event-monitor backup path), the buffer is copied to a backup file before each rollover.

Buffer size ranges from 6 Kb to 50 Kb. The default size is 32 Kb.

The no event-monitor buffer max-size and default event-monitor buffer max-size commands restore the default buffer size of 32 Kb by removing the event-monitor buffer max-size command from running-config.

 

Command Mode

Global Configuration

 

Command Syntax

event-monitor buffer max-size buffer_size

no event-monitor buffer max-size

default event-monitor buffer max-size

 

Parameters

buffer_size buffer capacity (Kb). Values range from 6 to 50. Default value is 32.

 

Example

This command configures a buffer size of 48 Kb.
switch(config)# event-monitor buffer max-size 48
switch(config)#

event-monitor clear

The event-monitor clear command removes the contents of the event monitor buffer. If event monitor backup is enabled, this command removes the contents from all event monitor backup files.

 

Command Mode

Privileged EXEC

 

Command Syntax

event-monitor clear

 

Example

This command clears the contents of the event monitor buffer.
switch# event-monitor clear
switch#

event-monitor sync

The event-monitor buffer sync command combines the event monitor buffer and all backup logs and synchronizes them into a single SQLite file, which is stored at /var/log/eventMon.db.

 

Command Mode

Privileged EXEC

 

Command Syntax

event-monitor sync

 

Example

This command synchronizes the buffer and backup logs into a single SQLite file.
switch(config)# event-monitor sync
switch(config)#

event-monitor

The event-monitor command enables the event monitor and specifies the types of events that are logged. The event monitor is an event logging service that records system events to a local database.

The database maintains a separate table for each event type.

The event monitor is disabled by default.
  • The no event-monitor all command disables the event monitor.
  • The no event-monitor command, followed by a log type parameter, disables event recording for the specified type.
  • The event-monitor command enables the specified event logging type by removing the corresponding no event-monitor command from running-config.

     

The no event-monitor and default event-monitor commands, without a LOG_TYPE parameter, restore the default event monitor settings by deleting all event monitor related commands from running-config.

 

Command Mode

Global Configuration

 

Command Syntax

event-monitor LOG_TYPE

no event-monitor LOG_TYPE

default event-monitor LOG_TYPE

 

Parameters

LOG_TYPE specifies the event logging type. Options include:
  • all all event logging types.
  • arp changes to ARP table.
  • backup backed up log files.
  • buffer changes to the local buffer settings.
  • igmpsnooping changes to IGMP snooping table.
  • lacp changes to the LACP table events.
  • mac changes to MAC address table.
  • mroute changes to multicast routing table.
  • neighbor changes to the neighbor routing table.
  • route changes to IP routing table.
  • route6 changes to IP route6 table.
  • stpunstable events that cause STP instability.

     

Related Command

no event-monitor

 

Examples
  • This command disables the event monitor for all types of events.
    switch(config)# no event-monitor all
    switch(config)#

     

  • This command enables the event monitor for routing table changes.
    switch(config)# event-monitor route
    switch(config)#

hostname

The hostname command assigns a text string as the switch's host name. The default host name is localhost.

The prompt displays the host name when appropriately configured through the prompt command.

The no hostname and default hostname commands return the switch's host name to the default value of localhost.

 

Command Mode

Global Configuration

 

Command Syntax

hostname string

no hostname

default hostname

 

Parameter

string host name assigned to the switch.

 

Example

This command assigns the string main-host as the switchs host name.
switch(config)# hostname main-host
main-host(config)#

 

The prompt was previously configured to display the host name.

ip domain lookup

The ip domain lookup command specifies the source interface for all DNS requests sent from the specified VRF.

The no ip domain lookup and default ip domain lookup commands return the switch to its default state, in which the switch selects source IP addresses for each DNS request from the specified VRF.

 

Command Mode

Global Configuration

 

Command Syntax

ip domain lookup [VRF_INSTANCE] source-interface INTF_NAME

no ip domain lookup [VRF_INSTANCE] source-interface

default ip domain lookup [VRF_INSTANCE] source-interface

 

Parameters
  • VRF_INSTANCE specifies the VRF instance being modified.
    • no parameter changes are made to the default VRF.
    • vrf vrf_name changes are made to the specified VRF.

       

  • INTF_NAME name of source interface to be used for DNS requests. Options include:
    • ethernet e_num Ethernet interface specified by e_num.
    • loopback l_num Loopback interface specified by l_num.
    • management m_num Management interface specified by m_num.
    • port-channel p_num Port-channel interface specified by p_num.
    • vlan v_num VLAN interface specified by v_num.

       

Examples
  • This command specifies VLAN 5 as the source interface for DNS requests originating from the default VRF.
    switch(config)# ip domain lookup source-interface Vlan5
    switch(config)#

     

  • This command specifies VLAN 10 as the source interface for DNS requests originating from VRF purple.
    switch(config)# ip domain lookup vrf purple source-interface Vlan10
    switch(config)#

ip domain-list

The ip domain-list command specifies a domain name to add to the IP domain list.

The no ip domain-list and default ip domain-list commands return the IP domain list to its default state, in which the switch selects source IP addresses for each DNS request from the specified VRF.

 

Command Mode

Global Configuration

 

Command Syntax

ip domain-list [IP_DOMAIN_NAME]

no ip domain-list [IP_DOMAIN_NAME]

default ip domain-list [IP_DOMAIN_NAME]

 

Parameter

IP_DOMAIN_NAME specifies the IP domain name.

 

Examples
  • This command specifies foo.com as the IP domain name to add to the IP domain list.
    switch(config)# ip domain-list foo.com
    switch(config)#

     

  • This command removes foo.com and returns the IP domain list to its default state.
    switch(config)# no ip domain-list foo.com
    switch(config)#

ip host

The ip host command associates a hostname to an IPv4 address. This command supports local hostname resolution based on local hostname IP address maps. Multiple hostnames can be mapped to an IP address. IPv4 and IPv6 addresses can be mapped to the same hostname. To map an IPv6 address to a hostname, use the ipv6 host command. The show hosts command displays the local hostname IP address mappings.

The no ip host and default ip host commands remove hostname IP address maps by deleting the corresponding ip host command from running-config, as specified by the following command parameters:
  • no parameters -Removes all hostname IP address maps.
  • hostname - Removes all IP address maps for the specified hostname.
  • hostname and IP address - Removes specified hostname IP address maps.

     

Command Mode

Global Configuration

 

Command Syntax

ip host hostname hostadd_1 [hostadd_2] ...[hostadd_X]

no ip host [hostname] [hostadd_1 [hostadd_2] [hostadd_X]

default ip host [hostname] [hostadd_1 [hostadd_2] [hostadd_X]

 

Parameters
  • hostname - hostname (text).
  • hostadd_N - IPv4 address associated with hostname in dotted decimal notation.

     

Related Commands
Examples
  • This command associates the hostname MyTestLab with the IP addresses 10.24.18.5 and 10.24.16.3.
    switch(config)#ip host MyTestLab 10.24.18.5 10.24.16.3

     

  • This command removes all IP address maps for the hostname production_lab.
    switch(config)#no ip host production_lab
    switch(config)#

ip name-server

The ip name-server command adds name server addresses to running_config. The switch uses name servers for name and address resolution. The switch can be configured with up to 32 name servers: 16 IPv4 addresses and 16 IPv6 addresses. Although a command can specify multiple name server addresses, running_config stores each address in a separate statement.

Name server addresses can be configured in the different VRFs. When adding IP addresses, also set the priority for the name server.

The no ip name-server and default ip name-server commands remove specified name servers from running_config. Commands that do not list an address remove all name servers.

 

Command Mode

Global Configuration

 

Command Syntax

ip name-server vrf [vrf_instance] [server_ip_address] [priority priority

no ip name-server vrf [vrf_instance] [server_ip_address] [priority priority

default ip name-server vrf [vrf_instance] [server_ip_address] [priority priority

 

Parameters
  • vrfvrf_instance - Specify the VRF instance with the IP addresses.
    • no parameter - If you do not specify a VRF, the default VRF becomes the name server.
  • server_ip_address IP address of the name server in dotted decimal notation. Options include the following:
    • ipv4_addr - IPv4 address in A.B.C.D format up to a maximum of 16 servers.
    • ipv6_addr - IPv4 address in A:B:C:D:E:F:G:H format up to a maximum of 16 servers. A command can contain both IPv4 and IPv6 address types.
  • priority priority - Specify a priority from 0 (highest) to 15 (lowest) for the name server. If not specified, the priority sets to 0 by default.

Guidelines

Multiple VRFs can be configured as a name server. Specify up to 16 IPv4 or 16 IPv6 addresses per VRF.

 

Examples
  • This command adds two name servers to the default VRF configuration.
    switch(config)# ip name-server 172.0.14.21 3:4F21:1902::
    switch(config)#

     

  • This command adds two name servers to the VRF, kindablue:
    switch(config)# ip name-server vrf kindablue 172.21.16.35 192.168.1.101
  • This command attempts to add a name server when the configuration already lists 16 servers.
    switch(config)# ip name-server 172.1.10.22
    % Maximum number of nameservers reached. '172.1.10.22' not added
    switch(config)#

ipv6 host

The ipv6 host command associates a hostname to an IPv6 address. This command supports local hostname resolution based on local hostname IP address maps. Multiple hostnames can be mapped to an IPv6 address. IPv4 and IPv6 addresses can be mapped to the same hostname. To map IPv4 addresses to a hostname, use the ip host command. The show hosts command displays the local hostname IP address mappings.

The no ipv6 host and default ipv6 host commands remove hostname IP address maps by deleting the corresponding ipv6 host command from running-config, as specified by command parameters:
  • no parameters - Removes all hostname IPv6 address maps.
  • hostname - Removes all IPv6 address maps for the specified hostname.
  • hostname and IP address - Removes specified hostname IP address maps.

     

Command Mode

Global Configuration

 

Command Syntax

ipv6 host hostname hostadd1 [hostadd2] ...[hostaddX]

no ipv6 host [hostname] [hostadd1 [hostadd2] [hostaddX]

default ipv6 host [hostname] [hostadd1 [hostadd2] [hostaddX]

 

Parameters
  • hostname - hostname in a text format.
  • hostaddN IPv6 addresses associated with the hostname in dotted decimal notation.

     

Related Commands

Example

This command associates the hostname MySupportLab with the IPv6 address 2001:0DB8:73:ff:ff:26:fd:90.
switch(config)#ipv6 host MySupportLab 2001:0DB8:73:ff:ff:26:fd:90
switch(config)#

logging buffered

The logging buffered command in the Global Configuration Mode configures the system logging buffer on the switch. The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging buffered [alerts | critical | debugging | emergencies | informational | notifications | warnings] severity_level logging_buffer_size

no ->

logging buffered [alerts | critical | debugging | emergencies | informational | notifications | warnings] severity_level logging_buffer_size

 

Parameters

  • alerts - Log events that require immediate action.
  • critical - Log events with critical conditions.
  • debugging - Log debugging messages.
  • emergencies - Log emergency events.
  • errors - Log error conditions.
  • informational - Log informational messages.
  • notifications - Log events with normal but significant conditions.
  • warnings - Log log messages with warning conditions.
  • severity_level - Log messages with a specific severity level from 0 to 7.
  • logging_buffer_size - Specify the size of the logging buffer in the number of messages from 10 to 214,748,364.

 

Example

Use the following commands to set the logging buffer to log up to 5000 notifications :

switch(config)# buffered notifications
            switch(config)# buffered 5000

 

logging console

The logging console command in Global Configuration Mode controls which system log events display directly on the switch physical console port or on an administrator's remote terminal session such as SSH or Telnet. It acts as a real-time filter and destination for log events.

Configuring this parameter sets the primary role of logging console as setting a severity threshold for log events. The switch displays any log event with the severity set to equal or lower than the configured setting. By default, EOS sets the severity to 3 (errors). If you set the severity to 7 (debugging), the maximum number of log messages display on the console as 7 has the least severe level of logging.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging console [alerts | critical | debugging | emergencies | informational | notifications | warnings]

no | default logging console [alerts | critical | debugging | emergencies | informational | notifications | warnings]

 

Parameters

  • console - Specify console logging parameters.
  • alerts (severity=1) - Immediate action needed
  • critical (severity=2) - Critical conditions
  • debugging (severity=7) - Debugging messages
  • emergencies (severity=0) - System is unusable
  • errors (severity=3) - Error conditions
  • informational (severity=6) - Informational messages
  • notifications (severity=5) - Normal but significant conditions
  • warnings (severity=4) - Warning conditions
  • 0_7 - Specify a severity level.

 

Example

Use the following command to specify a severity level of 3:

switch(config)# logging console 3

 

logging event

The logging event command in the Global Configuration Mode configures specify logging events not included in system logging on the switch. These events include congestion drops and spanning tree as well as others.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging event [congestion-drops interval seconds] [link-status global] [login root] [port-channel member-status global] [spanning-tree global] [storm-control discards [global | interval seconds]

[no | default] logging event [congestion-drops interval seconds] [login root] [port-channel member-status global] [spanning-tree global] [storm-control discards [global | interval seconds]>

 

Parameters

  • event - Configure logging events.
  • congestion-drops interval seconds - Specify the interval between congestion drop event messages from 1 to 65535 seconds.
  • link-status global - Specify to globally log link status messages.
  • login root - Specify to log root login activities.
  • port-channel member-status global - Specify to globally log port-channel member status.
  • spanning-tree global - Specify to globally log spanning tree events.
  • storm-control discards - Specify to log storm-control discard events.
    • global - Specify to globally log events.
    • interval seconds - Specify an interval between log events in seconds from 10 to 65535.

 

Example

Use the following command to log link-status events to the system logging:

switch(config)# log event link-status global
switch(config)#

 

logging facility

The logging facility command in the Global Configuration Mode categorizes the source of a system log event using a facility code from 0 to 23.

When specifying a local facility, configure a remote server to collect logs with the tag and send the message to a file.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging facility source_name facility_code

[no | default] logging facility source_name facility_code

 

Parameters

  • facility source_name facility_value - Configure logging messages with a specific facility value from 0 to 23:
    • auth (facility=4) - Authorization messages
    • cron (facility=15) - Clock daemon
    • daemon (facility=3) - System daemons
    • kern (facility=0) - Kernel messages
    • local0 (facility=16) - Local use 0
    • local1 (facility=17) - Local use 1
    • local2 (facility=18) - Local use 2
    • local3 (facility=19) - Local use 3
    • local4 (facility=20) - Local use 4
    • local5 (facility=20) - Local use 5
    • local6 (facility=21) - Local use 6
    • local7 (facility=22) - Local use 7
    • lpr (facility=2) - Line printer subsystem
    • mail (facility=7) - Mail system
    • news (facility=7) - Network news subsystem
    • sys10 (facility=10) - System use 10
    • sys11 (facility=11) - System use 11
    • sys12 (facility=12) - System use 12
    • sys13 (facility=13) - System use 13
    • sys14 (facility=14) - System use 14
    • sys9 (facility=9) - System use 9
    • syslog (facility=5) - Internal syslogd messages
    • user (facility=1) - User-level messages
    • uucp (facility=8) - UUCP subsy

 

Example

Use the following command to log system daemons, daemon, to the system logging messages:

logging facility daemon

logging format

The logging format command in the Global Configuration Mode to format log messages on the switch.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging format [hostname [fqdn |ipv4]] [rfc5424] [sequence-numbers] [timestamp high-resolution [traditional timezone| year] ]

[no | default] logging format [hostname [fqdn |ipv4]] [rfc5424] [sequence-numbers] [timestamp high-resolution [traditional timezone| year] ]

 

Parameters

  • format - Configure the format of the system log messages.
  • hostname [fqdn |ipv4] - Specify the host name format as a Fully Qualified Domain Name (FQDN) or as an IPv4 address.
  • rfc5424 - Specify the log message format in the format described in RFC5424 (Modern Format) which provides greater precision and flexibility.
  • sequence-numbers - Configure the log messages to use sequence numbers.
  • timestamp high-resolution [traditional timezone| year] - Configure the log message format to use a timestamp in high-resolution (RFC5424) or a traditional timestamp with a timezone and year.

 

Example

Use the following command to configure the log message in the format rfc5424:

switch(config)# logging format rfc5424
switch(config)#

 

logging host

The logging host command in Global Configuration Mode configures remote syslog server IP addresses and parameters.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging host syslog_name [add port_number protocol [tcp | tls | udp]] [protocol [tcp | tls | udp] [remove port_number [protocol [tcp | tls | udp]] port_number

[no | default] logging host syslog_name

 

Parameters

  • host - Configure the syslog server IP address and parameters.
  • add protocol [tcp | tls | udp] port_number - Add a protocol and specify a port number.
    • tcp - Specify Transmission Control Protocol (TCP).
    • tls - Specify Transport Layer Protocol (TLS).
    • udp - Specify User Datagram Protocol (UDP).
    • port_number - Specify a port number from 1 to 65535 for the syslog server. By default, the syslog server uses port 514.
  • protocol [tcp | tls | udp] - Specify a protocol used to communicate with the syslog server.
    • tcp - Specify Transmission Control Protocol (TCP).
    • tls - Specify Transport Layer Protocol (TLS).
    • udp - Specify User Datagram Protocol (UDP).
  • remove [protocol [tcp | tls | udp] port_number - Specify a protocol to remove from the configuration.
    • tcp - Specify Transmission Control Protocol (TCP).
    • tls - Specify Transport Layer Protocol (TLS).
    • udp - Specify User Datagram Protocol (UDP).
  • port_number - Specify a port number from 1 to 65535 for the syslog server. By default, the syslog server uses port 514.

 

Example

Use the following commands to add the protocol, TCP, with port 6514 (modern syslog security), to host 192.168.96.147:

switch(config)# logging host 192.168.96.147 add 6514 protocol tcp

 

logging level

The logging level command in the Global Configuration Mode configures the level of logging severity at the feature level to add to the syslog.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging level facility [all | default] [alerts | critical | debugging | emergencies | informational | notifications | warnings | 0_7]

[no | default] logging level feature_name [all | default]

 

Parameters

  • level - Configure logging severity for a specified feature.
  • facility - Specify the facility to configure for log messages.
  • all | default - Specify all to generate log messages for all facilities or the default value for the level.
  • alerts (severity=1) - Immediate action needed
  • critical (severity=2) - Critical conditions
  • debugging (severity=7) - Debugging messages
  • emergencies (severity=0) - System is unusable
  • errors (severity=3) - Error conditions
  • informational (severity=6) - Informational messages
  • notifications (severity=5) - Normal but significant conditions
  • warnings (severity=4) - Warning conditions
  • 0_7 - Specify a severity level.

 

Example

Use the following command to set the severity to notifications for the feature, AAA:

switch(config)# logging level AAA notifications

Setting the level to notifications sends all AAA log messages with a severity of 5 or lower to the syslog.

 

logging local-interface

The logging local-interface command in the Global Configuration Mode configures an IP address of an interface as a source IP of log messages.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging local-interface [Ethernet port_number | Loopback inf_number | Management port_number | Port Channel lag sub_inf | Tunnel inf_number | VLAN inf_number]

[no | default] logging local-interface

Parameters

  • Ethernet port_number - Specify the Ethernet interface and port number.
  • Loopback inf_number - Specify the Loopback interface number.
  • Management port_number - Specify the Management interface and port number.
  • Port-Channel lag sub_inf - Specify the Port Channel as Link Aggregation Group (LAG) or Port-Channel subinterface.
  • Tunnel inf_number - Specify the Tunnel interface number.
  • VLAN inf_number - Specify the VLAN interface number.

 

Example

Use the following command to add the interface, Ethernet1/1, as a local interface for log messages:

switch(config)# logging local-interface Ethernet1/1
switch(config)#

 

logging message

The logging message command in the Global Configuration Mode configures the second half of the crucial identifier used within a system log message to categorize the source and event type. It allows you to quickly understand which part of the switch generated the message and what specific event occurred on the system.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging message facility_mnenonic severity [alerts | critical | debugging | emergencies | informational | notifications | warnings] 0_7

[no | default] logging local-interface

Parameters

  • message facility_mnenonic - Configure the severity for specific log messages. The facility_mnenonic has the following sections:
    • facility - Identifies the application or system originating the message.
    • severity - Describes the urgency level of the message.
    • mnenonic - Uses a short descriptive keyword identifying the specific event that triggered the log message.
    For example, the message, %OSPF-5-ADJCHANGE, describes an OSPF change, neighbor adjacency, with a severity of 5.
  • severity - Specify the severity for the log message.
    • alerts (severity=1) - Immediate action needed
    • critical (severity=2) - Critical conditions
    • debugging (severity=7) - Debugging messages
    • emergencies (severity=0) - System is unusable
    • errors (severity=3) - Error conditions
    • informational (severity=6) - Informational messages
    • notifications (severity=5) - Normal but significant conditions
    • warnings (severity=4) - Warning conditions
    • 0_7 - Specify a severity level.

 

Example

Use the following command to change the message, %OSPF-5-ADJCHANGE, from severity 5 to severity 3:

switch(config)# logging message %OSPF-5-ADJCHANGE severity 3
switch(config)#

 

logging monitor

The logging monitor command in Global Configuration Mode controls the display of system log events on a switch, specifically for remote terminal sessions such as SSH or Telnet. You must enable this feature for each session open in SSH or Telnet.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging monitor [alerts | critical | debugging | emergencies | informational | notifications | warnings] 0_7

[no | default] logging monitor [alerts | critical | debugging | emergencies | informational | notifications | warnings] 0_7

 

Parameters

  • monitor - Configure the display of log events on remote terminal sessions.
  • severity - Specify the severity of the log messages to send to the remote session:
    • console - Specify console logging parameters.
    • alerts (severity=1) - Immediate action needed
    • critical (severity=2) - Critical conditions
    • debugging (severity=7) - Debugging messages
    • emergencies (severity=0) - System is unusable
    • errors (severity=3) - Error conditions
    • informational (severity=6) - Informational messages
    • notifications (severity=5) - Normal but significant conditions
    • warnings (severity=4) - Warning conditions
    • 0_7 - Specify a severity level.

 

Example

Use the following command to configure the syslog to send log messages with severity notifications to the remote terminal sessions:

switch(config)# logging monitor notifications
switch(config)#

 

logging persistent

The logging persistent command logs the files stored on the flash disk. It can store upto 30MB logs.

The no logging persistent command disables the logging from the running-config.

 

Command Mode

Global Configuration Mode

 

Command Syntax

logging persistent logging file size

no logging persistent logging file size

 

Parameter
  • logging file size The maximum size (in bytes) of logging file stored on flash disk. The value ranges from 1024 to 2147483647.

     

Example
  • This command configures logging persistent on the switch.
    switch# config
    switch(config)# logging persistent 1024
    ! Note: writing system log message on non-volatile flash will affect the life 
    expectancy of the flash drive due to heavy writing. Please disable persistent logging unless needed.

     

logging policy

The logging policy command in the Global Configuration Mode creates a set of rules and guidelines that dictate what, when, where, and how the system log handles events.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging policy match [invert-result] match-list list_name discard

[no | default] logging policy match

 

Parameters

  • policy match - Configure logging message filtering on matching messages.
  • invert-result - Specify to invert the match of the match list.
  • match-list list_name - Specify the name of the match list.
  • discard - Specify to discard the matching messages.

 

Example

Use the following command to match the list, test_match, and discard the messages:

switch(config)# logging policy match match-list test_match discard
            switch(config)#

 

logging qos

The logging qos command in Global Configuration Mode describes how the Quality of Service (QoS) log events apply to the system log and manage the traffic policy and internal buffers.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging qos dscp dscp_value

[no | default] logging qos

 

Parameters

  • qos - Configure QoS parameters.
  • dscp dscp_value - Specify a DSCP value between 0 and 63.

 

Example

Use the following command to set the DSCP value to 25:

switch(config)# logging qos dscp 25
switch(config)#

 

logging relogging-interval

The logging relogging-interval command in the Global Configuration Mode configures the interval between relogging critical log messages. This prevents the log buffer or console from a flood of the exact same rapidly occurring log messages.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging relogging-interval minutes

[no | default] logging relogging-interval

 

Parameters

  • relogging-interval minutes - Specify the relogging interval in seconds for critical log messages. Configure the number of minutes from 1 to 720.

 

Example

Use the following command to configure a relogging interval of 30 minutes:

switch(config)# logging relogging-interval 30

 

logging repeat-messages

The logging repeat-messages command configures repetition of syslog messages instead of summarizing the count of repeats.

The no logging repeat-messages and default logging repeat-messages commands disable the functionality to repeat logging messages in running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging repeat-messages

no logging repeat-messages

default logging repeat-messages

 

Examples
  • This command repeats syslog messages instead of summarizing the count of repeats.
    switch(config)# logging repeat-messages
    switch(config)#

     

  • This command displays the status of logging repeat messages command.
    switch(config)# show logging
    Syslog logging: enabled
        Buffer logging: level debugging
        Console logging: level debugging
        Monitor logging: level debugging
        Synchronous logging: disabled
        Trap logging: level informational
        Sequence numbers: disabled
        Syslog facility: local4
        Hostname format: Hostname only
        Repeat logging interval: disabled
        Repeat messages: enabled
    
    Facility             Severity            Effective Severity
    --------------       -------------       ------------------
    aaa                  debugging           debugging
    accounting           debugging           debugging
    
    switch(config)#

logging source-interface

The logging source-interface command in Global Configuration Mode configures an interface as the source IP of log messages. This can be crucial for maintaining consistency, reachability, and filtering of logs in large environments.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging source-interface [Ethernet port_number | Loopback inf_number | Management port_number | Port Channel lag sub_inf | Tunnel inf_number | VLAN inf_number]

[no | default] logging source-interface

 

Parameters

  • source-interface - Specify the interface to use for source IP addresses in log messages.
    • Ethernet port_number - Specify the Ethernet interface and port number.
    • Loopback inf_number - Specify the Loopback interface number.
    • Management port_number - Specify the Management interface and port number.
    • Port-Channel lag sub_inf - Specify the Port Channel as Link Aggregation Group (LAG) or Port-Channel subinterface.
    • Tunnel inf_number - Specify the Tunnel interface number.
    • VLAN inf_number - Specify the VLAN interface number.

 

Example

Use the following command to specify using Loopback0 as the source interface:

switch(config)# logging source-interface Loopback0
switch(config)#

 

logging synchronous

The logging synchronous command in Global Configuration Mode ensures that system log messages do not disrupt or interfere with command line input. This maintains a clean, usable command line environment by synchronizing the display of log messages with user activity.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration Mode

 

Command Syntax

logging synchronous level [alerts | critical | debugging | emergencies | informational | notifications | warnings] 0_7

[no | default] logging synchronous

 

Parameters

  • synchronous - Configure synchronizing log messages on the command line.
  • level - Specify the severity of the log messages to send to synchronize:
    • all - Synchronize all log messages.
    • alerts (severity=1) - Immediate action needed
    • critical (severity=2) - Critical conditions
    • debugging (severity=7) - Debugging messages
    • emergencies (severity=0) - System is unusable
    • errors (severity=3) - Error conditions
    • informational (severity=6) - Informational messages
    • notifications (severity=5) - Normal but significant conditions
    • warnings (severity=4) - Warning conditions
    • 0_7 - Specify a severity level.

 

Example

Use the following command to synchronize notifications on the command line:

switch(config)# logging synchronous level notifications
switch(config)#

 

logging trap

The logging trap command in Global Configuration Mode controls the minimum severity level of system log events eligible to forward to a remote syslog server. The switch only sends log events to hosts with a severity equal or lower than the specified trap.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging trap

[no | default] logging trap [alerts | critical | debugging | emergencies | informational | notifications | warnings] 0_7

 

Parameters

  • trap - Configure the level of severity for the trap.
    • alerts (severity=1) - Immediate action needed
    • critical (severity=2) - Critical conditions
    • debugging (severity=7) - Debugging messages
    • emergencies (severity=0) - System is unusable
    • errors (severity=3) - Error conditions
    • informational (severity=6) - Informational messages
    • notifications (severity=5) - Normal but significant conditions
    • system - Configure the system log buffer.
      • contain - Specify the text contained in a log message.
      • facility - Specify a facility for the system buffer.
        • auth (facility=4) - Authorization messages
        • cron (facility=15) - Clock daemon
        • daemon (facility=3) - System daemons
        • kern (facility=0) - Kernel messages
        • local0 (facility=16) - Local use 0
        • local1 (facility=17) - Local use 1
        • local2 (facility=18) - Local use 2
        • local3 (facility=19) - Local use 3
        • local4 (facility=20) - Local use 4
        • local5 (facility=20) - Local use 5
        • local6 (facility=21) - Local use 6
        • local7 (facility=22) - Local use 7
        • lpr (facility=2) - Line printer subsystem
        • mail (facility=7) - Mail system
        • news (facility=7) - Network news subsystem
        • sys10 (facility=10) - System use 10
        • sys11 (facility=11) - System use 11
        • sys12 (facility=12) - System use 12
        • sys13 (facility=13) - System use 13
        • sys14 (facility=14) - System use 14
        • sys9 (facility=9) - System use 9
        • syslog (facility=5) - Internal syslogd messages
        • user (facility=1) - User-level messages
        • uucp (facility=8) - UUCP subsy
      • severity - Specify the severity.
        • alerts (severity=1) - Immediate action needed
        • critical (severity=2) - Critical conditions
        • debugging (severity=7) - Debugging messages
        • emergencies (severity=0) - System is unusable
        • errors (severity=3) - Error conditions
        • informational (severity=6) - Informational messages
        • notifications (severity=5) - Normal but significant conditions
        • warnings (severity=4) - Warning conditions
      • tag - Specify a program name to tag for log messages.
    • 0_7 - Specify a severity level.

 

Example

Use the following command to configurethe level of the trap to errors

switch(config)# logging trap errors
switch(config)#

 

logging vrf host

The logging vrf command in the Global Configuration Mode ensures that syslog messages use a specific, non-default Virtual Routing and Forwarding (VRF) instance when sent to a remote syslog servers. Without specifying a VRF, the switch attempts to send syslog packets using the default global routing table. Specifying a VRF configures the switch to generate, encapsulate, and route the syslog messages within the specified VRF routing table.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging vrf vrf_name host ip_address [add port_number protocol [tcp | tls | udp]] [protocol [tcp | tls | udp]][remove port_number protocol [tcp | tls | udp]]

no logging vrf vrf_name

default logging vrf vrf_name

 

Parameters

  • vrf vrf_name
  • host ip_address
    • add port_number
    • protocol [tcp | tls | udp] - Specify a protocol used to communicate with the syslog server.
      • tcp - Specify Transmission Control Protocol (TCP).
      • tls - Specify Transport Layer Protocol (TLS).
      • udp - Specify User Datagram Protocol (UDP).
    • [remove port_number
    • protocol [tcp | tls | udp] - Specify a protocol used to communicate with the syslog server.
      • tcp - Specify Transmission Control Protocol (TCP).
      • tls - Specify Transport Layer Protocol (TLS).
      • udp - Specify User Datagram Protocol (UDP).

 

Example

Use the following command to add the VRF, purple, host IPv4 address, 192.168.96.147, with port number, 443, to the configuration:

switch(config)# logging vrf purple host 192.168.96.147 443

 

logging vrf local-interface

The logging vrf local-interface command in the Global Configuration Mode associates a local interface with a VRF where the event originated. This ensures that the internal logs related to a specific VRF tag properly and possibly handled differently with the switch local logging system than the global VRF.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging vrf vrf_name local-interface [Ethernet port_number | Loopback inf_number | Management port_number | Port Channel lag sub_inf | Tunnel inf_number | VLAN inf_number]

[no | default] logging vrf> vrf_name local-interface

 

Parameters

  • vrf vrf_name - Specify the name of the VRF for logging system messages.
  • local-interface - Specify the local interface to use for logging system messages.
    • Ethernet port_number - Specify the Ethernet interface and port number.
    • Loopback inf_number - Specify the Loopback interface number.
    • Management port_number - Specify the Management interface and port number.
    • Port-Channel lag sub_inf - Specify the Port Channel as Link Aggregation Group (LAG) or Port-Channel subinterface.
    • Tunnel inf_number - Specify the Tunnel interface number.
    • VLAN inf_number - Specify the VLAN interface number.

 

Example

Use the following commands to specify Ethernet1/1 as the local interface for VRF, purple:

switch(config)# logging vrf purple local-interface Ethernet1/1
switch(config)#

 

logging vrf source-interface

The logging vrf local-interface command in the Global Configuration Mode associates a source interface, usually a Loopback interface, with a VRF to provide a consistent and correctly isolated source IP address for system log messages.

The [no | default] versions of the command disable the feature and remove the configuration from the running-config.

 

Command Mode

Global Configuration

 

Command Syntax

logging vrf vrf_name source-interface [Ethernet port_number | Loopback inf_number | Management port_number | Port Channel lag sub_inf | Tunnel inf_number | VLAN inf_number]

[no | default] logging vrf> vrf_name local-interface

 

Parameters

  • vrf vrf_name - Specify the name of the VRF for logging system messages.
  • source-interface - Specify the source interface to use for logging system messages.
    • Ethernet port_number - Specify the Ethernet interface and port number.
    • Loopback inf_number - Specify the Loopback interface number.
    • Management port_number - Specify the Management interface and port number.
    • Port-Channel lag sub_inf - Specify the Port Channel as Link Aggregation Group (LAG) or Port-Channel subinterface.
    • Tunnel inf_number - Specify the Tunnel interface number.
    • VLAN inf_number - Specify the VLAN interface number.

 

Example

Use the following commands to specify Loopback0 as the source interface for VRF, purple:

switch(config)# logging vrf purple source-interface Loopback0
            switch(config)#

 

no event-monitor

The no event-monitor and default event-monitor commands remove the specified event-monitor configuration statements from running-config, returning the switch to the specified default state.
  • no event-monitor with no parameters, restores all default setting states:
    • event monitor is enabled.
    • buffer backup is disabled.

       

  • The no event-monitor backup disables the backup.

     

To disable the event monitor, enter the no event-monitor all command (event-monitor).

 

Command Mode

Global Configuration

 

Command Syntax

no event-monitor [PARAMETER]

default event-monitor [PARAMETER]

 

Parameters

PARAMETER the event monitor property that is returned to the default state.
  • no parameter all event monitor properties.
  • backup event monitor buffer backup is disabled.

     

Example

This command removes all event monitor configuration statements from running-config.
switch(config)# no event-monitor
switch(config)#

ntp authenticate

The ntp authenticate command enables the authentication of incoming NTP packets. When authentication is enabled, NTP packets will be used to synchronize time on the switch only if they include a trusted authentication key. Authentication keys are created on the switch using the ntp authentication-key command, and the ntp trusted-key command is used to specify which keys are trusted. NTP authentication is disabled by default.

The no ntp authenticate and default ntp authenticate commands disable NTP authentication on the switch by removing the corresponding ntp authenticate command from running-config.

 

Command Mode

Global Configuration

 

Command Syntax

ntp authenticate

no ntp authenticate

default ntp authenticate

 

Examples
  • This command enables NTP authentication on the switch.
    switch(config)# ntp authenticate
    switch(config)#

     

  • This command disables NTP authentication on the switch.
    switch(config)# no ntp authenticate
    switch(config)#

ntp authentication-key

The ntp authentication-key command creates an authentication key for use in authenticating incoming NTP packets. For the key to be used in authentication:

  • It must be configured as a trusted key using the ntp trusted-key command.
  • NTP authentication must be enabled on the switch using the ntp authenticate command.
  • The same key must be configured on the NTP server.

     

The no ntp authentication-key and default ntp authentication-key commands remove the specified authentication key by removing the corresponding ntp authentication-key command from running-config.

 

Command Mode

Global Configuration

 

Command Syntax

ntp authentication-keykey_id ENCRYPT_TYPE password_text

no ntp authentication-key key_id

default ntp authentication-key key_id

 

Parameters
  • key_id key ID number. Value ranges from 1 to 65534.
  • ENCRYPT_TYPE encryption method. Values include:
    • md5 key_text is MD5 encrypted.
    • sha1 key_text is SHA-1 encrypted.

       

  • password_text the authentication-key password.

     

Examples
  • This command creates an NTP authentication key with ID 234 and password timeSync using MD5 encryption.
    switch(config)# ntp authentication-key 234 md5 timeSync 

     

    Running-config stores the password as plain text.

     

  • This command removes NTP authentication key 234.
    switch(config)# no ntp authentication-key 234

     

ntp local-interface

The ntp local-interface command configures an interface as the local NTP source. The IP address of that interface will then be used as the source address in NTP packets sent by the switch. If the switch is acting as an NTP server and a server-specific source interface has been configured using the source option of the ntp server command, the server-specific source address will take precedence.

The no ntp local-interface and default ntp local-interface commands remove the ntp local-interface command from running-config.

 

Command Mode

Global Configuration

 

Command Syntax

ntp local-interface [VRF_INSTANCE] INT_PORT

no ntp local-interface

default ntp local-interface

 

Parameters
  • VRF_INSTANCE the VRF instance to be used for connection to the specified server. Options include:
    • no parameter connects using the default VRF.
    • vrf vrf_name connects using the specified user-defined VRF.

       

  • INT_PORT the interface port that specifies the NTP local interface. Settings include:
    • ethernet e_range Ethernet interface list.
    • loopback l_range loopback interface list.
    • management m_range management interface list.
    • port-channel c_range port channel interface list.
    • vlan v_range VLAN interface list.

       

Examples
  • This command configures ntp local-interface vlan 25 as the local NTP source. NTP packets exiting the switch use the IP address of VLAN interface 25 as their source address.
    switch(config)# ntp local-interface vlan 25
    switch(config)#

     

  • This command removes the ntp local-interface command from the configuration.
    switch(config)# no ntp local-interface
    switch(config)#

     

ntp serve all

The ntp serve all command configures the switch to act as an NTP server by accepting incoming NTP requests.

Using this command also causes the switch to re-synchronize with its upstream NTP server.

Individual interfaces can be configured separately to accept or deny NTP requests by using the ntp serve command, and these settings override the global setting.

 

Command Mode

Global Configuration

 

Command Syntax

ntp serve all

no ntp serve all

default ntp serve all

 

Examples
  • This command configures the switch to accept incoming NTP requests.
    switch(config)# ntp serve all
    switch(config)#

     

  • This command configures the switch to deny incoming NTP requests.
    switch(config)# no ntp serve all
    switch(config)#

ntp serve

The ntp serve command configures the command mode interface to accept incoming NTP requests regardless of the global setting.

The no ntp serve command configures the command mode interface to refuse incoming NTP requests regardless of the global setting. The default ntp serve command configures the command mode interface to follow the global setting.

Using this command also causes the switch to re-synchronize with its upstream NTP server.

 

Command Modes

Interface-Ethernet Configuration

Interface-Loopback Configuration

Interface-Management Configuration

Interface-Port-channel Configuration

Interface-VLAN Configuration

Interface-VXLAN Configuration

 

Command Syntax

ntp serve

no ntp serve

default ntp serve

 

Examples
  • These commands configure interface ethernet 5 to accept incoming NTP requests regardless of global settings.
    switch(config)# interface ethernet 5
    switch(config-if-Et5)# ntp serve
    switch(config-if-Et5)#

     

  • These commands configure interface ethernet 5 to deny incoming NTP requests regardless of global settings.
    switch(config)# interface ethernet 5
    switch(config-if-Et5)# no ntp serve
    switch(config-if-Et5)#

     

  • These commands configure interface ethernet 5 to use global settings in responding to incoming NTP requests.
    switch(config)# interface ethernet 5
    switch(config-if-Et5)#default ntp serve
    switch(config-if-Et5)#

ntp server

The ntp server command adds a Network Time Protocol (NTP) server to the running-config. If the command specifies an existing server in the running-config, it modifies the server settings. The switch synchronizes the system clock with an NTP server when running-config contains at least one valid NTP server.

The switch supports NTP versions 1 through 4. The default is version 4.

The prefer option specifies a preferred NTP server to use as the NTP server if not discarded by NTP.

The no ntp server and default ntp server commands remove the specified NTP server from running-config. To remove an NTP server configured in a user-defined VRF, include the VRF name in the no ntp server command.

 

Command Mode

Global Configuration

 

Command Syntax

ntp server [ vrfvrf_instance | host_name] refresh [version ntp_version] [source-address [ [ipv4_address | ipv6_address] burst [iburst [ key auth_key ][ maxpoll max_poll_interval][] [ minpoll min_poll_interval ] prefer source interface_name

no ntp server [vrf_instance] host_name

default ntp server [vrf_instance] host_name

 

All parameters except vrf and hostname can be placed in any order.

 

Parameters
  • vrf vrf_instance - Specify the VRF instance to use for the connection to the specified server.

     

  • host_name Specify the name or IP address of the NTP server. Options include:
    • ip_address - Specify an IPv4 or IPv6 address in dotted decimal notation.
    • host_name - Specify the hostname of the NTP server.

     

  • prefer - Indicates the priority of this server when the switch selects a synchronizing server.
    • no parameter - The server has no special priority.
    • prefer - This server has priority when the switch selects a synchronizing server.

     

  • refresh - Specifies sending periodic DNS queries for the NTP server. If the DNS response doesn't include the resolved IP address of the NTP server, then a request selects the next available IP address and restarts the service with an updated configuration.

     

  • version ntp_version - Specifies the NTP version. Settings include:
    • no parameter - Sets NTP version to 4 (default).
    • version number - Specify a version number from 1 to 4.

     

  • source-address ip_source - Specifies the source IPv4 address or IPv6 address for NTP updates for the specified NTP server. This option overrides global settings created by the ntp local-interface command.

     

  • burst - Indicates that when the switch reaches the NTP server, the switch sends packets to the server in bursts of eight instead of the usual one. Recommended only for local servers. Disabled by default.

     

  • iburst - Indicates that the switch sends packets to the server in bursts until reaching the server. Recommended for general use to speed synchronization. Disabled by default.

     

  • key auth_key - Specify the authentication key to use when authenticating NTP packets from the server.
    • no parameter - Specify no authentication key.
    • key 1 to 65534 - The switch uses the specified key to authenticate NTP packets from the server.

       

  • max_poll_interval - Specifies the maximum polling interval for the server as the base-2 logarithm of the interval in seconds. Settings include the following:
    • no parameter - Sets the maximum polling interval to 10. (1,024 seconds, the default).
    • maxpoll number - Specifies to use the number as the base-2 logarithm of the interval in seconds. Values range from 3 (8 seconds) to 17 (131,072 seconds, approximately 36 hours).

       

  • minpoll min_poll_interval - Specifies the minimum polling interval for the server as the base-2 logarithm of the interval in seconds. Settings include the following:
    • no parameter - Sets the minimum polling interval to 6 (64 seconds, the default).
    • number, where number is the base-2 logarithm of the interval in seconds. Values range from 3 (8 seconds) to 17 (131,072 seconds, approximately 36 hours).

       

Guidelines

To configure multiple parameters for a single server, include them all in a single ntp server command. Using the command again for the same server overwrites parameters previously configured in running-config.

All NTP servers must use the same VRF. If you do not specify a VRF, the server uses the default VRF. To use a user-defined VRF for connection to an NTP server, first use the no ntp server command to remove any NTP servers configured in the default VRF.

When specifying a source interface, choose an interface in the same VRF as the server. If the source interface does not exists on the same VRF, the running-config includes the source data but does not add it to the NTP packets.

An NTP server may be configured using an invalid or inactive VRF, but the status of the NTP server remains inactive until the VRF becomes active.

 

Examples
  • This command configures the switch to update the time with the NTP server at address 172.16.0.23 and designates it as a preferred NTP server.
    switch(config)# ntp server 172.16.0.23 prefer

     

  • This command configures the switch to update the time through an NTP server named local-nettime.
    switch(config)# ntp server local-nettime

     

  • This command configures the switch to update the time through a version 3 NTP server.
    switch(config)# ntp server 171.18.1.22 version 3

     

  • These commands reconfigure the switch to access the above NTP servers through VRF magenta.
    switch(config)# no ntp server 172.16.0.23
    switch(config)# no ntp server local-nettime
    switch(config)# no ntp server 171.18.1.22
    switch(config)# ntp server vrf magenta 172.16.0.23 prefer
    switch(config)# ntp server vrf magenta local-nettime
    switch(config)# ntp server vrf magenta 171.18.1.22 version 3
    switch(config)#

ntp trusted-key

The ntp trusted-key command specifies which authentication keys will be trusted for authentication of NTP packets. A packet with a trusted key will be used to update the local time if authenticated.

The no ntp trusted-key and default ntp trusted-key commands remove the specified authentication keys from the trusted key list by removing the corresponding ntp trusted-key command from running-config.

 

Command Mode

Global Configuration

 

Command Syntax

ntp trusted-key key_list

no ntp trusted-key

default ntp trusted-key

 

Parameter

key_list specified one or more keys. Formats include a number (1 to 65534), number range, or comma-delimited list of numbers and ranges.

 

Example

This command configures the switch to trust authentication keys 234 and 237 for authentication of NTP packets.
switch(config)# ntp trusted-key 234,237
switch(config)#

power enable module

The power enable module command powers up the specified module. The no power enable module command powers down the specified module.

 

Command Mode

Global Configuration

 

Command Syntax

power enable module {fabric|linecard|supervisor|switchcard} module_number

no power enable module {fabric|linecard|supervisor|switchcard} module_number

default power enable module {fabric|linecard|supervisor|switchcard} module_number

 

Parameters

fabric specifies a fabric card

linecard specifies a linecard

supervisor specifies a supervisor

switchcard specifies a switch card

module_number specifies the number of the module

 

Examples
  • This command powers down linecard 3.
    switch(config)# no power enable module linecard 3
    switch(config)#

     

  • These commands reload fabric module 2.
    switch(config)# no power enable module fabric 2
    switch(config)# power enable module fabric 2
    switch(config)#

prompt

The prompt command specifies the contents of the CLI prompt. Characters allowed in the prompt include A-Z, a-z, 0-9, and these punctuation marks:

! @ # $ % ˆ & * ( ) - = + f g [ ] ; : < > , . ? / ˜ n

 

The prompt supports these control sequences:
  • %s – space character
  • %t – tab character
  • %% – percent character
  • %D – time and date
  • %D{f_char} – time and date, format specified by the BSD strftime (f_char) time conversion function.
  • %H – host name
  • %h – host name up to the first ‘.’
  • %P – extended command mode
  • %p – command mode
  • %r 1 – redundancy status on modular systems.
  • %R 2 – extended redundancy status on modular systems – includes status and slot number.

     

Table 1. Command Mode Prompt Examples

Command Mode

Command Mode Prompt

Extended Command Mode Prompt

Exec

>

>

Privileged Exec

#

#

Global Configuration

(config)#

(config)#

Ethernet Interface Configuration

(config-if)#

(config-if-ET15)#

VLAN Interface Configuration

(config-if)#

(config-if-Vl24)#

Port Channel Interface Configuration

(config-if)#

(config-if-Po4)#

Management Interface Configuration

(config-if)#

(config-if-Ma1)

Access List Configuration

(config-acl)#

(config-acl-listname)#

OSPF Configuration

(config-router)#

(config-router-ospf)#

BGP Configuration

(config-router)#

(config-router-bgp)#

 

The no prompt and default prompt commands return the prompt to the default of %H%R%P.

 

Command Mode

Global Configuration

 

Command Syntax

prompt p_string

no prompt

default prompt

 

Parameters

p_string     prompt text (character string). Elements include letters, numbers, and control sequences.

 

Examples
  • This command creates a prompt that displays system 1 and the command mode.
    host-name.dut103(config)# prompt system%s1%P
    system 1(config)#

     

  • This command creates a prompt that displays the command mode.
    host-name.dut103(config)# prompt %p
    (config)#

     

  • These equivalent commands create the default prompt.
    % prompt %H%P
    host-name.dut103(config)#

     

    % no prompt
    host-name.dut103(config)#

show banner

The show banner command displays the specified banner.

 

Command Mode

Privileged EXEC

 

Command Syntax

show banner BANNER_TYPE [login | motd]

 

Parameters

BANNER_TYPE banner that the command displays. Options include:
  • login command displays login banner.
  • motd command displays message of the day banner.

 

Example

These commands configure and display the message of the day banner.
switch(config)# banner motd
Enter TEXT message. Type 'EOF' on its own line to end.
This is an motd banner for $(hostname)
EOF

switch(config)# show banner motd
This is an motd banner for $(hostname)
switch(config)#

show clock

The show clock command displays the current system clock time and configured time zone. The switch uses the system clock for system log messages and debugging traces.

 

Command Mode

EXEC

 

Command Syntax

show clock

 

Example

This command displays the current system clock time and configured time zone.
switch> show clock
Wed Nov  2 10:29:32 2011
timezone is America/Los_Angeles
switch>

show event-monitor arp

The show event-monitor arp command performs an SQL-style query on the event monitor database and displays ARP table events as specified by command parameters. The event monitor buffer and all backup logs are synchronized into a single SQLite file.

 

Command Mode

Privileged EXEC

 

Command Syntax

show event-monitor arp [GROUP] [MESSAGES] [INTERFACE] [IP] [MAC] [TIME] [VRF]

Optional parameters can be placed in any order.

 

Parameters
  • GROUP used with aggregate functions to group results. Analogous to SQL group by command.
    • no parameter results are not grouped.
    • group by interface results are grouped by interface.
    • group by ip results are grouped by IP address.
    • group by mac results are grouped by MAC address.
    • group by vrf results are grouped by VRF.

       

  • MESSAGES number of messages returned from query. Analogous to SQL limit command.
    • no parameter result-set size is not limited.
    • limit msg_quantity number of results that are displayed. Values range from 1 to 15,000.

       

  • INTERFACE restricts result-set to events that include specified interface (SQL Like command).
    • no parameter result-set not restricted by interface.
    • match-interface ethernet e_range Ethernet interface list.
    • match-interface loopback l_range loopback interface list.
    • match-interface management m_range management interface list.
    • match-interface port-channel c_range port channel interface list.
    • match-interface tunnel t_range tunnel interface list.
    • match-interface VXLAN vx_range VXLAN interface list.
    • match-interface port-channel c_range port channel interface list.

       

  • IP restricts result-set to events that include specified IP address (SQL Like command).
    • no parameter result-set not restricted to specific IP addresses.
    • match-ip ip_address_rex IP address, as represented by regular expression.

       

  • MAC restricts result-set to events that include specified MAC address (SQL Like command).
    • no parameter result-set not restricted to specific MAC addresses.
    • match-mac mac_address_rex MAC address, as represented by regular expression.

       

  • TIME restricts result-set to events generated during specified period.
    • no parameter result-set not restricted by time of event.
    • match-time last-minute includes events generated during last minute.
    • match-time last-day includes events generated during last day.
    • match-time last-hour includes events generated during last hour.
    • match-time last-week includes events generated during last week.

       

  • VRF restricts result-set to events that include a specific VRF.
    • no parameter result-set not restricted by time of event.
    • match-vrf vrf_name the VRF name.

       

Example

This command displays ARP table events listed in the event monitor database.
switch# show event-monitor arp
% Writing 220017 Arp, 234204 Route, 1732559 Mac events to the database
2012-11-06 12:36:10|10.33.6.159|Vlan1417|0000.00dc.cc0d|0|added|2186271
2012-11-06 12:38:20|10.33.7.150|Vlan1417|0000.00f7.e25f|0|added|2186292
2012-11-06 12:38:34|10.33.6.62|Vlan1417|0000:00:01:c2:ac|0|added|2186295
2012-11-06 12:39:13|10.33.7.162|Vlan1417|00:00:00:45:c2:79|0|added|2186299
2012-11-06 12:39:50|10.33.12.54|Vlan1417|||removed|2186303
2012-11-06 12:39:51|10.33.6.218|Vlan1417|00:00:00:e9:36:46|0|added|2186305
2012-11-06 12:40:00|10.33.6.140|Vlan1417|00:00:00:4a:36:c3|0|added|2186308
2012-11-06 12:40:02|10.33.6.239|Vlan1417|00:00:00:5b:a7:21|0|added|2186312
2012-11-06 12:41:16|10.33.7.11|Vlan1417|00:00:00:3f:94:59|0|added|2186320
2012-11-06 12:41:50|10.33.7.60|Vlan1417|00:00:00:1f:3c:8e|0|added|2186346
2012-11-06 12:43:34|10.33.7.81|Vlan1417|00:00:00:e3:0d:9c|0|added|2186762
2012-11-06 12:43:42|10.33.6.214|Vlan1417|00:00:00:7b:09:7d|0|added|2186765
2012-11-06 12:43:59|10.33.7.149|Vlan1417|00:00:00:8d:a6:d8|0|added|2186768
switch#

show event-monitor igmpsnooping

The show event-monitor igmpsnooping command performs an SQL-style query on the event-monitor database, using the statement specified in the command.

 

Command Mode

Privileged EXEC

 

Command Syntax

show event-monitor igmpsnooping [GROUP] [MESSAGES] [MAC] [INTERFACE] [VLAN] [TIME]

 

Parameters
  • GROUP used with aggregate functions to group results. Analogous to SQL group by command.
    • no parameter results are not grouped.
    • group-by interface results are grouped by interface.
    • group-by mac results are grouped by MAC address.
    • group-by vlan results are grouped by VLAN.

       

  • MESSAGES number of messages returned from query. Analogous to SQL limit command.
    • no parameter result-set size is not limited.
    • limit msg_quantity number of results that are displayed. Values range from 1 to 15,000.

       

  • MAC restricts result-set to events that include specified MAC address (SQL Like command).
    • no parameter result-set not restricted to specific MAC addresses.
    • match-mac mac_address_rex MAC address, as represented by regular expression.

       

  • INTERFACE restricts result-set to events that include specified interface (SQL Like command).
    • no parameter result-set not restricted by interface.
    • match-interface ethernet e_range Ethernet interface list.
    • match-interface loopback l_range loopback interface list.
    • match-interface management m_range management interface list.
    • match-interface port-channel c_range port channel interface list.
    • match-interface vlan v_range VLAN interface list.
    • match-interface tunnel t_range tunnel interface list.
    • match-interface VXLAN vx_range VXLAN interface list.

       

  • TIME restricts result-set to events with specified period.
    • no parameter result-set not restricted by time of event.
    • match-time last-minute includes events generated during last minute.
    • match-time last-day includes events generated during last day.
    • match-time last-hour includes events generated during last hour.
    • match-time last-week includes events generated during last week.

       

  • VLAN restricts result-set to events that include a specific VLAN (SQL Like command).
    • no parameter result-set not restricted by time of event.
    • match-vlan vlan VLAN interface number.

       

Example
switch# show event-monitor igmpsnooping
switch#

show event-monitor mac

The show event-monitor mac command performs an SQL-style query on the event monitor database and displays MAC address table events as specified by command parameters. The event monitor buffer and all backup logs are synchronized into a single SQLite file.

 

Command Mode

Privileged EXEC

 

Command Syntax

show event-monitor mac [GROUP] [MESSAGES] [INTERFACE] [MAC] [TIME]

Optional parameters can be placed in any order.

 

Parameters
  • GROUP used with aggregate functions to group results. Analogous to SQL group by command.
    • no parameter results are not grouped.
    • group-by interface results are grouped by interface.
    • group-by mac results are grouped by MAC address.

       

  • MESSAGES number of messages returned from query. Analogous to SQL limit command.
    • no parameter result-set size is not limited.
    • limit msg_quantity number of results that are displayed. Values range from 1 to 15,000.

       

  • INTERFACE restricts result-set to events that include specified interface (SQL Like command).
    • no parameter result-set not restricted by interface.
    • match-interface ethernet e_range Ethernet interface list.
    • match-interface loopback l_range loopback interface list.
    • match-interface management m_range management interface list.
    • match-interface port-channel c_range port channel interface list.
    • match-interface vlan v_range VLAN interface list.
    • match-interface tunnel t_range tunnel interface list.
    • match-interface VXLAN vx_range VXLAN interface list.

       

  • MAC restricts result-set to events that include specified MAC address (SQL Like command).
    • no parameter result-set not restricted to specific MAC addresses.
    • match-mac mac_address_rex MAC address, as represented by regular expression.

       

  • TIME restricts result-set to events with specified period.
    • no parameter result-set not restricted by time of event.
    • match-time last-minute includes events generated during last minute.
    • match-time last-day includes events generated during last day.
    • match-time last-hour includes events generated during last hour.
    • match-time last-week includes events generated during last week.

       

Examples
  • This command displays all events triggered by MAC address table events.
    switch# show event-monitor mac
    % Writing 0 Arp, 0 Route, 1 Mac events to the database
    2012-01-19 13:57:55|1|0808.0808.0808|Ethernet1|configuredStaticMac|added|0

     

  • This command displays events triggered by MAC address table changes.
    switch# show event-monitor mac match-mac 08:08:08:%
    2012-01-19 13:57:55|1|0808.0808.0808|Ethernet1|configuredStaticMac|added|0

show event-monitor mroute

The show event-monitor mroute command performs an SQL-style query on the event-monitor database, using the statement specified in the command.

 

Command Mode

Privileged EXEC

 

Command Syntax

show event-monitor mroute [GROUP] [MESSAGES] [IP] [INTERFACE] [SRC_IP] [TIME]

Optional parameters can be placed in any order.

 

Parameters
  • GROUP used with aggregate functions to group results. Analogous to SQL group by command.
    • no parameter results are not grouped.
    • group-by interface results are grouped by interface.
    • group-by ipv6 results are grouped by IPv6 address.
    • group-by mac results are grouped by MAC address.
    • group-by vrf results are grouped by VRF.

       

  • MESSAGES number of messages returned from query. Analogous to SQL limit command.
    • no parameter result-set size is not limited.
    • limit msg_quantity number of results that are displayed. Values range from 1 to 15,000.

       

  • IP restricts result-set to events that include specified IP address (SQL Like command).
    • no parameter result-set not restricted to specific IP addresses.
    • match-ipv6 ip_address_rex IP address, as represented by regular expression.

       

  • INTERFACE restricts result-set to events that include specified interface (SQL Like command).
    • no parameter result-set not restricted by interface.
    • match-interface ethernet e_range Ethernet interface list.
    • match-interface loopback l_range loopback interface list.
    • match-interface management m_range management interface list.
    • match-interface port-channel c_range port channel interface list.
    • match-interface vlan v_range VLAN interface list.
    • match-interface tunnel t_range tunnel interface list.
    • match-interface VXLAN vx_range VXLAN interface list.

       

  • SRC_IP restricts result-set to events that include specified Source IP address (SQL Like command).
    • no parameter result-set not restricted to specific IP addresses.
    • match-ip ip_address_rex IP address, as represented by regular expression.

       

  • TIME restricts result-set to events with specified period.
    • no parameter result-set not restricted by time of event.
    • match-time last-minute includes events generated during last minute.
    • match-time last-day includes events generated during last day.
    • match-time last-hour includes events generated during last hour.
    • match-time last-week includes events generated during last week.

       

Example

This command displays neighbor table events listed in the event monitor database.
switch# show event-monitor mroute
2011-07-28 12:33:28|default|16.17.18.19/32|225.0.0.1/32|||added|30
2011-07-28 12:33:28|default|16.17.18.19/32|225.0.0.1/32|Vlan2|iif|join|31
2011-07-28 12:33:28|default|16.17.18.19/32|225.0.0.1/32|Vlan3|oif|join|32
2011-07-28 12:33:28|default|16.17.18.19/32|225.0.0.1/32|Vlan4|oif|join|33
2011-07-28 12:33:28|default|10.11.12.13/32|225.0.0.2/32|||added|34
2011-07-28 12:33:28|default|10.11.12.13/32|225.0.0.2/32|Vlan3|iif|join|35
2011-07-28 12:33:28|default|10.11.12.13/32|225.0.0.2/32|Vlan2|oif|join|36
2011-07-28 12:33:28|default|16.17.18.19/32|225.0.0.1/32|Vlan4||leave|37
2011-07-28 12:33:28|default|16.17.18.19/32|225.0.0.1/32|||deleted|38
2011-07-28 12:33:28|default|10.11.12.13/32|225.0.0.2/32|||deleted|39

show event-monitor neighbor

The show event-monitor neighbor command performs an SQL-style query on the event monitor database and displays neighbor table events as specified by command parameters. The event monitor buffer and all backup logs are synchronized into a single SQLite file.

 

Command Mode

Privileged EXEC

 

Command Syntax

show event-monitor neighbor [GROUP][MESSAGES][INTERFACE][IP6][MAC][TIME][VRF]

Optional parameters can be placed in any order.

 

Parameters
  • GROUP used with aggregate functions to group results. Analogous to SQL group by command.
    • no parameter results are not grouped.
    • group-by interface results are grouped by interface.
    • group-by ip6 results are grouped by IPv6 address.
    • group-by mac results are grouped by MAC address.
    • group-by vrf results are grouped by VRF.

       

  • MESSAGES number of messages returned from query. Analogous to SQL limit command.
    • no parameter result-set size is not limited.
    • limit msg_quantity number of results that are displayed. Values range from 1 to 15,000.

       

  • INTERFACE restricts result-set to events that include specified interface (SQL Like command).
    • no parameter result-set not restricted by interface.
    • match-interface ethernet e_range Ethernet interface list.
    • match-interface loopback l_range loopback interface list.
    • match-interface management m_range management interface list.
    • match-interface port-channel c_range port channel interface list.
    • match-interface vlan v_range VLAN interface list.
    • match-interface tunnel t_range tunnel interface list.
    • match-interface VXLAN vx_range VXLAN interface list.

       

  • IP6 restricts result-set to events that include specified IP address (SQL Like command).
    • no parameter result-set not restricted to specific IP addresses.
    • match-ipv6 ip6_address_rex IPv6 address, as represented by regular expression.

       

  • MAC restricts result-set to events that include specified MAC address (SQL Like command).
    • no parameter result-set not restricted to specific MAC addresses.
    • match-mac mac_address_rex MAC address, as represented by regular expression.

       

  • TIME restricts result-set to events with specified period.
    • no parameter result-set not restricted by time of event.
    • match-time last-minute includes events generated during last minute.
    • match-time last-day includes events generated during last day.
    • match-time last-hour includes events generated during last hour.
    • match-time last-week includes events generated during last week.

       

  • VRF restricts result-set to events that include a specific VRF (SQL Like command).
    • no parameter result-set not restricted by time of event.
    • match-vrf vrf_name VRF name, as represented by a regular expression.

       

Example

This command displays neighbor table events listed in the event monitor database.
switch# show event-monitor neighbor
2019-09-30 14:37:32.894147|def0::1|Vlan1|default|0005.0005.0005|1|added|1
2019-09-30 14:37:32.894395|def0::2|Vlan1|default|0005.0005.0005|1|added|2
2019-09-30 14:37:32.894607|def0::3|Vlan1|default|0005.0005.0005|1|added|3
2019-09-30 14:37:32.894815|def0::4|Vlan1|default|0005.0005.0005|1|added|4
2019-09-30 14:37:32.895071|def0::5|Vlan1|default|0005.0005.0005|1|added|5
2019-09-30 14:37:32.895303|def0::6|Vlan1|default|0005.0005.0005|1|added|6
2019-09-30 14:37:32.895527|def0::7|Vlan1|default|0005.0005.0005|1|added|7
2019-09-30 14:37:32.895732|def0::8|Vlan1|default|0005.0005.0005|1|added|8
2019-09-30 14:37:32.895968|def0::9|Vlan1|default|0005.0005.0005|1|added|9
2019-09-30 14:37:32.896194|def0::a|Vlan1|default|0005.0005.0005|1|added|10

show event-monitor nexthop-group backup-activation

The show event-monitor nexthop-group backup-activation command displays Nexthop Group backup activation events produced by forwarding agents. Nexthop groups supports configuring the backup paths through EOS RPC APIs and CLI. Whenever the route or prefix begins pointing to configured backup paths, the event monitor database logs a backup activation event with the nexthop group name, timestamp, and other attributes.

The [no | default] show event-monitor nexthop-group backup-activation commands disable event monitoring and remove the configuration from the running-config.

 

Command Mode

EXEC

 

Command Syntax

show event-monitor nexthop-group backup-activation

 

Parameters

  • nexthop-group - Display Nexthop Group Events.
  • backup-activation - Display the Nexthop Group backu activation events table.

 

Example

Use the following command to display Nexthop Group backup-activation events:

switch# show event-monitor nexthop-group backup-activation
2025-01-06 00:17:09.266517|NHG-1|111|2025-01-06 00:17:09.245674|backup|allProgrammed
2025-01-06 00:18:09.266517|NHG-2|121|2025-01-06 00:18:09.245674|backup|allProgrammed
2025-01-06 00:19:09.266517|NHG-3|131|2025-01-06 00:19:09.245674|backup|allProgrammed
The output displays the following information:
  • Timestamp - Displays the timestamp when recording the event.
  • Nexthop Group Name - Displays the Nexthop Group Name.
  • Nexthop Group Version ID - Displays the Nexthop Group Version ID.
  • Activation Timestamp - Displays the time backup paths programmed into hardware and begain carrying traffic.
  • ViaType - Displays if the traffic went through backup routes.
  • Hardware Programmed State - Displays the state as Drop, partiallyProgrammed, or allProgrammed.

show event-monitor route6

The show event-monitor route6 command performs an SQL-style query on the event monitor database and displays routing6 table events as specified by command parameters. The event monitor buffer and all backup logs are synchronized into a single SQLite file.

 

Command Mode

Privileged EXEC

 

Command Syntax

show event-monitor route6 [GROUP][MESSAGES][IP6][TIME]

Optional parameters can be placed in any order.

 

Parameters
  • GROUP used with aggregate functions to group results. Analogous to SQL group by command.
    • no parameter results are not grouped.
    • group by interface results are grouped by interface.
    • group by ip6 results are grouped by IPv6 address.
    • group by mac results are grouped by MAC address.
    • group by vrf results are grouped by VRF.

       

  • MESSAGES number of messages returned from query. Analogous to SQL limit command.
    • no parameter result-set size is not limited.
    • limit msg_quantity number of results that are displayed. Values range from 1 to 15,000.

       

  • IP6 restricts result-set to events that include specified IP address (SQL Like command).
    • no parameter result-set not restricted to specific IP addresses.
    • match-ipv6 ip6_address_rex IPv6 address, as represented by regular expression.

       

  • TIME restricts result-set to events with specified period.
    • no parameter result-set not restricted by time of event.
    • match-time last-minute includes events generated during last minute.
    • match-time last-day includes events generated during last day.
    • match-time last-hour includes events generated during last hour.
    • match-time last-week includes events generated during last week.

       

Example

This command displays neighbor table events listed in the event monitor database.
switch# show event-monitor route6
2019-09-30 14:59:30.660447|def1::1:0/128|default|receive|0|1|updated|41
2019-09-30 14:59:30.660720|def1::2:0/128|default|attached|0|1|updated|42
2019-09-30 14:59:30.660983|def1::3:0/128|default|staticConfig|0|1|updated|43
2019-09-30 14:59:30.661226|def1::4:0/128|default|kernel|0|1|updated|44
2019-09-30 14:59:30.661469|def1::5:0/128|default|rip|0|1|updated|45
2019-09-30 14:59:30.661706|def1::6:0/128|default|connected|0|1|updated|46
2019-09-30 14:59:30.661968|def1::7:0/128|default|redirect|0|1|updated|47
2019-09-30 14:59:30.662207|def1::8:0/128|default|bgpAggregate|0|1|updated|48
2019-09-30 14:59:30.662451|def1::9:0/128|default|ospfAggregate|0|1|updated|49
2019-09-30 14:59:30.662694|def1::a:0/128|default|ospf|0|1|updated|50
2019-09-30 14:59:30.662935|def1::b:0/128|default|bgp|0|1|updated|51
2019-09-30 14:59:30.663174|def1::c:0/128|default|unknown|0|1|updated|52
switch#

show event-monitor route

The show event-monitor route command performs an SQL-style query on the event monitor database and displays routing table events as specified by command parameters. The event monitor buffer and all backup logs are synchronized into a single SQLite file.

 

Command Mode

Privileged EXEC

 

Command Syntax

show event-monitor route [GROUP][MESSAGES][IP][TIME]

Optional parameters can be placed in any order.

Parameters
  • GROUP used with aggregate functions to group results. Analogous to SQL group by command.
    • no parameter results are not grouped.
    • group-by ip results are grouped by IPv4 address.

       

  • MESSAGES number of messages returned from query. Analogous to SQL limit command.
    • no parameter result-set size is not limited.
    • limit msg_quantity number of results that are displayed. Values range from 1 to 15,000.

       

  • IP restricts result-set to events that include specified IP address (SQL Like command).
    • no parameter result-set not restricted to specific IP addresses.
    • match-ip ip_address_rex IP address, as represented by regular expression.

       

  • TIME restricts result-set to events with specified period.
    • no parameter result-set not restricted by time of event.
    • match-time last-minute includes events generated during last minute.
    • match-time last-day includes events generated during last day.
    • match-time last-hour includes events generated during last hour.
    • match-time last-week includes events generated during last week.

       

Example

This command displays 10 routing table events listed in the event monitor database.
switch# show event-monitor route limit 10
2019-09-30 14:01:21.659428|16.16.16.255/32|default|receiveBcast|0|0|updated|20
2019-09-30 14:01:21.659464|192.168.201.12/30|default|connected|1|0|updated|21
2019-09-30 14:01:21.659497|192.168.1.255/32|default|receiveBcast|0|0|updated|22
2019-09-30 14:01:21.659503|192.168.201.8/32|default|receiveBcast|0|0|updated|23
2019-09-30 14:01:21.659512|16.16.16.0/32|default|receiveBcast|0|0|updated|24
2019-09-30 
14:01:21.659517|192.168.201.12/32|default|receiveBcast|0|0|updated|25
2019-09-30 
14:01:21.659524|192.168.201.15/32|default|receiveBcast|0|0|updated|26
2019-09-30 14:01:21.659541|192.168.201.8/30|default|connected|1|0|updated|27
2019-09-30 14:01:21.659564|16.16.16.0/24|default|connected|1|0|updated|28
2019-09-30 14:01:21.659578|192.168.201.9/32|default|receive|0|0|updated|29
switch#

show event-monitor sqlite

The show event-monitor sqlite command performs an SQL-style query on the event monitor database, using the statement specified in the command.

 

Command Mode

Privileged EXEC

 

Command Syntax

show event-monitor sqlite statement

 

Parameter

statement SQLite statement.

 

Example

This command displays all entries from the route table.
switch# show event-monitor sqlite select * from route;
2019-09-30 14:01:21.659428|16.16.16.255/32|default|receiveBcast|0|0|updated|20
2019-09-30 14:01:21.659464|192.168.201.12/30|default|connected|1|0|updated|21
2019-09-30 14:01:21.659497|192.168.1.255/32|default|receiveBcast|0|0|updated|22
2019-09-30 14:01:21.659503|192.168.201.8/32|default|receiveBcast|0|0|updated|23
2019-09-30 14:01:21.659512|16.16.16.0/32|default|receiveBcast|0|0|updated|24
2019-09-30 
14:01:21.659517|192.168.201.12/32|default|receiveBcast|0|0|updated|25
2019-09-30 
14:01:21.659524|192.168.201.15/32|default|receiveBcast|0|0|updated|26
2019-09-30 14:01:21.659541|192.168.201.8/30|default|connected|1|0|updated|27
2019-09-30 14:01:21.659564|16.16.16.0/24|default|connected|1|0|updated|28
2019-09-30 14:01:21.659578|192.168.201.9/32|default|receive|0|0|updated|29
switch#

show event-monitor stpunstable

The show event-monitor stpunstable command performs an SQL-style query on the event-monitor database, using the statement specified in the command.

 

Command Mode

Privileged EXEC

 

Command Syntax

show event-monitor stpunstable [MESSAGES][TIME]

Optional parameters can be placed in any order.

 

Parameters
  • MESSAGES number of messages returned from query. Analogous to SQL limit command.
    • no parameter result-set size is not limited.
    • limit msg_quantity number of results that are displayed. Values range from 1 to 15,000.

       

  • TIME restricts result-set to events with specified period.
    • no parameter result-set not restricted by time of event.
    • match-time last-minute includes events generated during last minute.
    • match-time last-day includes events generated during last day.
    • match-time last-hour includes events generated during last hour.
    • match-time last-week includes events generated during last week.

       

Example
switch# show event-monitor stpunstable limit 5
2019-02-07 07:22:10.286164|Cist|Ethernet5|forward-delay-while|1
2019-02-07 07:22:10.286651|Cist|Ethernet6|forward-delay-while|2
2019-02-07 07:22:10.286844|Cist|Ethernet8|forward-delay-while|3
2019-02-07 07:22:10.287030|Cist|Ethernet14|forward-delay-while|4
2019-02-07 07:22:10.287215|Cist|Ethernet21|forward-delay-while|5
switch#

show hostname

The show hostname command displays the hostname and the Fully Qualified Domain Name (FQDN) of the switch.

 

Command Mode

EXEC

 

Command Syntax

show hostname

 

Example

This command displays the hostname and FQDN of the switch.
switch> show hostname
Hostname: switch_1
FQDN:     switch_1.aristanetworks.com

switch>

show hosts

The show hosts command displays the default domain name, name lookup service style, a list of name server hosts, and the static hostname-IP address maps.

 

Command Mode

EXEC

 

Command Syntax

show hosts

 

Example

This command displays the switch's IP domain name:
switch> show hosts
Default domain is: aristanetworks.com
Name/address lookup uses domain service
Name servers are: 172.22.22.40, 172.22.22.10

Static Mappings:

Hostname                       IP     Addresses

TEST_LAB                      IPV4    10.24.18.6
PRODUCTION_LAB                IPV4    10.24.18.7
SUPPORT_LAB                   IPV6    2001:0DB8:73:ff:ff:26:fd:90
switch>

show ip domain-name

The show ip domain-name command displays the switchs IP domain name that is configured with the ip domain name command.

 

Command Mode

EXEC

 

Command Syntax

show ip domain-name

 

Example

This command displays the switch's IP domain name:
switch> show ip domain-name
aristanetworks.com
switch>

show ip name-server

The show ip name-server command displays the ip addresses of name-servers in running-config. The name servers are configured by the ip name-server command.

 

Command Mode

EXEC

 

Command Syntax

show ip name-server

 

Example

This command displays the IP address of name servers configured on the switch and the priority assigned to it.
switch> show ip name-server
IP Address   VRF     Priority
------------ ------- --------
172.22.22.10 default        0
172.22.22.40 default        0
172.21.16.35 kindablue      1
switch>

show local-clock time-properties

The show local-clock time-properties command displays the Precision Time Protocol (PTP) clock properties.

 

Command Mode

Privileged EXEC

 

Command Syntax

show local-clock time-properties

 

Example

This command shows the PTP clock properties.
switch# show local-clock time-properties
Current UTC offset valid: False
Current UTC offset: 0
Leap 59: False
Leap 61: False
Time Traceable: False
Frequency Traceable: False
PTP Timescale: False
Time Source: 0x0
switch#

show logging

The show logging command displays information about the current system logging configuration.

 

Command Mode

EXEC

 

Command Syntax

show logging

 

Parameters

  • alerts - Display events that require immediate action.
  • all - Display all lines in the logging buffer.
  • counters - Display counter statistics of each logging host.
  • critical - Display events with critical conditions.
  • debugging - Display debugging messages.
  • emergencies - Display emergency events.
  • errors - Display error conditions.
  • follow - Keep following the buffer as it grows.
  • informational - Display informational messages.
  • last - Display messages in the last number of time-units,
  • mce - Display the contents of the Machine Check Exception/Error (MCE) buffer.
  • notifications - Display events with normal but significant conditions.
  • persistent - Display persistent logging messages stored on a flash drive.
  • system - Display the contents of the system log buffer.
  • threshold - Display only log messages at the threshold level or above.
  • time-range - Filter messages by the begin and end time.
  • warnings - Display log messages with warning conditions.
  • 1_9999 - Display the last number of messages in the logging buffer.

 

Examples

Use the following command to display log counter statistics:

switch# show logging counters
IP Address         Protocol Bytes Sent Processed Failed Suspended Suspended Duration Resumed      Last Refreshed
------------------ -------- ---------- --------- ------ --------- ------------------ ------- -------------------
192.168.96.147:514 udp               0        12     12        12           00:06:00     119 2025-11-06 18:12:32

Use the following command to display information about the system logging configuration:

switch# show logging
Syslog logging: enabled
Buffer logging: level debugging
Console logging: level errors
Persistent logging: disabled
Monitor logging: level errors
Synchronous logging: disabled
Trap logging: level informational
Logging local-interface 'Ethernet1/1' (unavailable), no IP address assigned to interface in VRF default (config error)
Logging to '192.168.96.147' port 514 in VRF default via udp
Sequence numbers: disabled
Syslog facility: local4
Hostname format: Hostname only
Repeat logging interval: disabled
Repeat messages: disabled
Root login logging: disabled
            
    External configuration:
    active: 
    inactive:
            
Facility                   Severity            Effective Severity
--------------------       -------------       ------------------
aaa                        debugging           debugging    
accounting                 debugging           debugging    
acl                        debugging           debugging    
agent                      debugging           debugging    
ale                        debugging           debugging    
arp                        debugging           debugging    
bfd                        debugging           debugging    
bgp                        debugging           debugging    
bmp                        debugging           debugging    
capacity                   debugging           debugging    
capi                       debugging           debugging    
card                       debugging           debugging    
classification             debugging           debugging    
clear                      debugging           debugging    
cvx                        debugging           debugging    
dataplane                  debugging           debugging    
dhcp                       debugging           debugging    
dmf                        debugging           debugging    
dot1x                      debugging           debugging    
dot1xhttp                  debugging           debugging    
dscp                       debugging           debugging

show ntp associations

The show ntp associations command displays the status of connections to NTP servers.

 

Command Mode

EXEC

 

Command Syntax

show ntp associations

 

Display Values
  • refid (reference ID): the reference ID of the configured NTP server’s time source. The reference ID is either the IPv4 address of the source or (if the source has an IPv6 address) the first four octets of the MD5 hash of the IPv6 address.
  • st (stratum): number of steps between the switch and the reference clock.
  • t (transmission type): u unicast; b broadcast; l local.
  • when: interval since reception of last packet (seconds unless unit is provided).
  • poll: interval between NTP poll packets. Maximum (1024) reached as server and client syncs.
  • reach: octal number that displays status of last eight NTP messages (377 - all messages received).
  • delay: round-trip delay of packets to the NTP server.
  • offset: difference between local clock and the server’s clock.
  • jitter: nominal offset estimation error.

     

Example

This command displays the status of the switch’s NTP associations.
switch> show ntp associations 
     remote          refid      st t when  poll reach   delay   offset  jitter 
==============================================================================
+l.ntp.arista.co 125.157.10.11   2 u  539  1024  377  121.748   -0.345   0.893
-3.ntp.arista.co 127.31.152.34   2 u  868  1024  377  101.671    2.434   1.529
+2.ntp.arista.co 176.131.12.185  2 u  676  1024  377  116.505     0.03   0.768
*4.ntp.arista.co 120.181.192.192 2 u  696  1024  377   48.431   -0.416    0.15
switch#

show ntp status

The show ntp status command displays the status of NTP on the switch. If the switch clock is not synchronized to an NTP server, the status reads “unsynchronised” and shows the server polling interval. If the clock is synchronized to an NTP server, the status shows the IP address and stratum of the server, the precision of the synchronization, and the polling interval.

 

Note: In EOS releases prior to 4.23.2, this command identified system peers with IPv6 addresses by their reference IDs (the first four octets of the MD5 hash of the IPv6 address). In later releases, this command always shows the IP address of the system peer (whether IPv4 or IPv6).

 

Command Mode

EXEC

 

Command Syntax

show ntp status

 

Example

This command displays the switch’s NTP status.
switch> show ntp status
synchronised to NTP server (192.168.78.62) at stratum 3
   time correct to within 66 ms
   polling server every 1024 s
switch>
1 When logged into a fixed system or a supervisor on a modular system, this option has no effect.
2 When logged into a fixed system, this option has no effect.