L Commands

Table Of Contents

L Commands

lldp holdtime

lldp receive

lldp reinit

lldp timer

lldp tlv-select

lldp transmit

locator-led

logging console

logging event

logging ip access-list cache

logging level

logging logfile

logging message interface type ethernet description

logging module

logging monitor

logging server

logging source-interface

logging timestamp


L Commands


This chapter describes the Cisco NX-OS system management commands that begin with the letter L.

lldp holdtime

To configure the amount of time that a receiving device should hold the information sent by your device before discarding it, use the lldp holdtime command. To remove the hold time configuration, use the no form of this command.

lldp holdtime seconds

Syntax Description

seconds

Hold time in seconds. The range is from 10 to 255 seconds.


Defaults

120 seconds

Command Modes

Global configuration (config)

Supported User Roles

network-admin
network-operator
vdc-admin
vdc-operator

Command History

Release
Modification

5.0(1)

This command was introduced.


Usage Guidelines

Make sure that you are in the correct virtual device context (VDC). To switch VDCs, use the switchto vdc command.

This command does not require a license.

Examples

This example shows how to configure the Link Layer Discovery Protocol (LLDP) hold time:

switch(config)# lldp holdtime 180
switch(config)#
This example shows how to remove the LLDP hold time configuration:

switch(config)# no lldp holdtime 180
switch(config)#

Related Commands

Command
Description

lldp reinit

Specifies the delay time in seconds for LLDP to initialize on any interface.

lldp timer

Specifies the transmission frequency of LLDP updates in seconds.

show lldp timers

Displays the LLDP holdtime, delay time, and update frequency configuration.


lldp receive

To enable the reception of Link Layer Discovery Protocol (LLDP) packets on an interface, use the lldp receive command. To disable the reception of LLDP packets, use the no form of this command.

lldp receive

no lldp receive

Syntax Description

This command has no arguments or keywords.

Defaults

None

Command Modes

Interface configuration

Supported User Roles

network-admin
network-operator
vdc-admin
vdc-operator

Command History

Release
Modification

5.0(1)

This command was introduced.


Usage Guidelines

Make sure that you are in the correct virtual device context (VDC). To switch VDCs, use the switchto vdc command.

Make sure that you have globally enabled LLDP on the device.

This command does not require a license.

Examples

This example shows how to enable the reception of LLDP packets on an interface:

switch(config)# interface ethernet 6/3
switch(config-if)# lldp receive
switch(config-if)# exit
switch(config)#

This example shows how to disable the reception of LLDP packets on an interface:

switch(config)# interface ethernet 6/3
switch(config-if)# no lldp receive
switch(config-if)# exit
switch(config)#

Related Commands

Command
Description

lldp transmit

Enables the transmission of LLDP packets on an interface.

show lldp interface ethernet

Displays the LLDP configuration on an interface.


lldp reinit

To configure the delay time for the Link Layer Discovery Protocol (LLDP) to initialize on any interface, use the lldp reinit command. To remove the LLDP initialization configuration, use the no form of this command.

lldp reinit seconds

Syntax Description

seconds

Initialize time in seconds. The range is from 1 to 10.


Defaults

2 seconds

Command Modes

Global configuration (config)

Supported User Roles

network-admin
network-operator
vdc-admin
vdc-operator

Command History

Release
Modification

5.0(1)

This command was introduced.


Usage Guidelines

Make sure that you are in the correct virtual device context (VDC). To switch VDCs, use the switchto vdc command.

This command does not require a license.

Examples

This example shows how to configure the delay time for LLDP initialization:

switch(config)# lldp reinit 6
switch(config)#

This example shows how to remove the LLDP initialization configuration:

switch(config)# no lldp reinit 6
switch(config)#

Related Commands

Command
Description

lldp holdtime

Specifies the amount of time in seconds that a receiving device should hold the information sent by your device before discarding it.

lldp timer

Specifies the transmission frequency of LLDP updates in seconds.

show lldp timers

Displays the LLDP holdtime, delay time, and update frequency configuration.


lldp timer

To configure the transmission frequency of Link Layer Discovery Protocol (LLDP) updates, use the lldp timer command. To remove the transmission frequency configuration for LLDP updates, use the no form of this command.

lldp timer seconds

Syntax Description

seconds

Transmission frequency in seconds. The range is from 5 to 254.


Defaults

30 seconds

Command Modes

Global configuration (config)

Supported User Roles

network-admin
network-operator
vdc-admin
vdc-operator

Command History

Release
Modification

5.0(1)

This command was introduced.


Usage Guidelines

Make sure that you are in the correct virtual device context (VDC). To switch VDCs, use the switchto vdc command.

This command does not require a license.

Examples

This example shows how to configure the transmission frequency for LLDP updates:

switch(config)# lldp timer 45
switch(config)#

This example shows how to remove the transmission frequency configuration for LLDP updates:

switch(config)# no lldp timer 45
switch(config)#

Related Commands

Command
Description

lldp reint

Specifies the delay time in seconds for LLDP to initialize on any interface.

lldp holdtime

Specifies the amount of time in seconds that a receiving device should hold the information sent by your device before discarding it.

show lldp timers

Displays the LLDP holdtime, delay time, and update frequency configuration.


lldp tlv-select

To configure the type, length, and value (TLV) descriptions to send and receive in Link Layer Discovery Protocol (LLDP) packets, use the lldp tlv-select command. To remove the TLV configuration, use the no form of this command.

lldp tlv-select [dcbxp | management-address | port-description | port-vlan | system-capabilities | system-description | system-name]

no lldp tlv-select [dcbxp | management-address | port-description | port-vlan | system-capabilities | system-description | system-name]

Syntax Description

dcbxp

(Optional) Specifies the DCBXP TLV.

management-address

(Optional) Specifies the Management Address TLV.

port-description

(Optional) Specifies the Port Description TLV.

port-vlan

(Optional) Specifies the Port VLAN ID TLV.

system-capabilities

(Optional) Specifies the System Capabilities TLV.

system-description

(Optional) Specifies the System Description TLV.

system-name

(Optional) Specifies the System Name TLV.


Defaults

By default, all available TLVs are enabled.

Command Modes

Global configuration (config)

Supported User Roles

network-admin
network-operator
vdc-admin
vdc-operator

Command History

Release
Modification

5.0(1)

This command was introduced.


Usage Guidelines

Make sure that you are in the correct virtual device context (VDC). To switch VDCs, use the switchto vdc command.

This command does not require a license.

Examples

This example shows how to enable the system capabilities TLV:

switch(config)# lldp tlv-select system-capabilities
switch(config)#

This example shows how to disable the system capabilities TLV:

switch(config)# no lldp tlv-select system-capabilities
switch(config)#

Related Commands

Command
Description

show lldp tlv-select

Displays the LLDP TLV configuration.

show lldp dcbx interface ethernet

Displays the local DCBX control status.


lldp transmit

To enable the transmission of Link Layer Discovery Protocol (LLDP) packets on an interface, use the lldp transmit command. To disable the transmission of LLDP packets, use the no form of this command.

lldp transmit

no lldp transmit

Syntax Description

This command has no arguments or keywords.

Defaults

Enabled

Command Modes

Interface configuration

Supported User Roles

network-admin
vdc-admin

Command History

Release
Modification

5.0(1)

This command was introduced.


Usage Guidelines

Make sure that you are in the correct virtual device context (VDC). To switch VDCs, use the switchto vdc command.

Make sure that you have globally enabled the LLDP on the device.

This command does not require a license.

Examples

This example shows how to enable the transmission of LLDP packets on an interface:

switch(config)# interface ethernet 7/1
switch(config-if)# lldp transmit
switch(config-if)# exit
switch(config)#

This example shows how to disable the transmission of LLDP packets on an interface:

switch(config)# interface ethernet 7/1
switch(config-if)# no lldp transmit
switch(config-if)# exit
switch(config)#

Related Commands

Command
Description

lldp receive

Enables the reception of LLDP packets on an interface.

show lldp interface ethernet

Displays the LLDP configuration on an interface.


locator-led

To blink an LED on the system, use the locator-led command. To restore the default LED state, use the no form of this command.

locator-led {chassis | fan f-number | module slot | powersupply ps-number | xbar x-number}

no locator-led{chassis | fan f-number | module slot | powersupply ps-number | xbar x-number}

Syntax Description

chassis

Blinks the chaiss LED.

fan f-number

Blinks the LED that represents the configured fan number. The range depends on the platform. Use ? to see the range.

module slot

Blinks the module LED. The range depends on the platform. Use ? to see the range.

powersupply ps-number

Blinks the power supply LED. The range depends on the platform. Use ? to see the range.

xbar x-number

Blinks the xbar module LED. The range depends on the platform. Use ? to see the range.


Defaults

None

Command Modes

Any command mode

Supported User Roles

network-admin
network-operator
vdc-admin
vdc-operator

Command History

Release
Modification

4.1(2)

This command was introduced.


Usage Guidelines

Use the locator-led command to flash the LED on a component in the system. You can use this blinking LED to identify the component to an administrator in the data center.

This command does not require a license.

Examples

This example shows how to blink the LED for module 4:

switch# locator-led module 4

Related Commands

Command
Description

show locator-led status

Displays the status of locator LEDs on the system.


logging console

To enable logging messages to the console session, use the logging console command. To disable logging messages to the console session, use the no form of this command.

logging console [severity-level]

no logging console

Syntax Description

severity-level

(Optional) Number of the desired severity level at which messages should be logged. Messages at or numerically lower than the specified level are logged. Severity levels are as follows:

0—emergency: System unusable

1—alert: Immediate action needed

2—critical: Critical condition—default level

3—error: Error condition

4—warning: Warning condition

5—notification: Normal but significant condition

6—informational: Informational message only

7—debugging: Appears during debugging only


Defaults

None

Command Modes

Global configuration

Supported User Roles

network-admin
vdc-admin

Command History

Release
Modification

4.0(1)

This command was introduced.


Usage Guidelines

This command does not require a license.

Examples

This example shows how to enable logging messages with a severity level of 4 (warning) or higher to the console session:

switch# configure terminal 
switch(config)# logging console 4 
switch(config)#

Related Commands

Command
Description

show logging console

Displays the console logging configuration.


logging event

To log interface events, use the logging event command.

logging event {link-status | trunk-status} {enable | default}

no logging event {link-status | trunk-status} {enable | default}

Syntax Description

link-status

Logs all UP/DOWN and CHANGE messages.

trunk-status

Logs all TRUNK status messages.

default

Specifies that the default logging configuration is used by interfaces not explicitly configured.

enable

Specifies to enable logging to override the port level configuration.


Defaults

None

Command Modes

Global configuration

Supported User Roles

network-admin
vdc-admin

Command History

Release
Modification

4.0(1)

This command was introduced.


Usage Guidelines

This command does not require a license.

Examples

This example shows how to log interface events:

switch# configure terminal 
switch(config)# logging event link-status default 
switch(config)#

Related Commands

Command
Description

show logging

Displays the logging status.


logging ip access-list cache

To configure the Optimized ACL Logging (OAL) parameters, use the logging ip access-list cache command. To reset to the default settings, use the no form of this command.

logging ip access-list cache {{entries num_entries} | {interval seconds} | {threshold num_packets}}

no logging ip access-list cache {{entries num_entries} | {interval seconds} | {threshold num_packets}}

Syntax Description

entries num_entries

Specifies the maximum number of log entries that are cached in the software. The range is from 0 to 1048576. The default value is 8000 entries.

interval seconds

Specifies the maximum time interval before an entry is sent to a syslog. The range is from 5 to 86400. The default value is 300 seconds.

threshold num_packets

Specifies the number of packet matches (hits) before an entry is sent to a syslog. The range is from 0 to 1000000. The default value is 0 packets—rate limiting is off; the system log is not triggered by the number of packet matches.


Defaults

None

Command Modes

Global configuration

Supported User Roles

network-admin
vdc-admin

Command History

Release
Modification

4.0(1)

This command was introduced.


Usage Guidelines

This command does not require a license.

Examples

This example shows how to to specify the maximum number of log entries that are cached in the software:

switch# configure terminal 
switch(config)# logging ip access-list cache entries 200 
switch(config)#

This example shows how to specify the maximum time interval before an entry is sent to the system log:

switch# configure terminal 
switch(config)# logging ip access-list cache interval 350 
switch(config)#

This example shows how to specify the number of packet matches before an entry is sent to the system log:

switch# configure terminal 
switch(config)# logging ip access-list cache threshold 125 
switch(config)#

Related Commands

Command
Description

show logging ip access-list

Displays the status of IP access list logging.


logging level

To enable logging messages from the defined facility that have the specified severity level or higher, use the logging level command. To disable logging messages from the defined facility, use the no form of this command.

logging level facility severity-level

no logging level facility severity-level

Syntax Description

facility

Appropriate facility. The facilities are listed in the "System Message Logging Facilities" section on page 659.

To apply the same severity level to all facilities, use the all facility.

severity-level

Number of the desired severity level at which messages should be logged. Messages at or numerically lower than the specified level are logged. Severity levels are as follows:

0—emergency: System unusable

1—alert: Immediate action needed

2—critical: Critical condition—default level

3—error: Error condition

4—warning: Warning condition

5—notification: Normal but significant condition

6—informational: Informational message only

7—debugging: Appears during debugging only


Defaults

None

Command Modes

Global configuration

Supported User Roles

network-admin
vdc-admin

Command History

Release
Modification

4.0(1)

This command was introduced.


Usage Guidelines

This command does not require a license.

Examples

This example shows how to enable logging messages from the AAA facility that have a severity level of 2 or higher:

switch# configure terminal 
switch(config)# logging level aaa 2 
switch(config)#

Related Commands

Command
Description

show logging level

Displays the facility logging level configuration.


logging logfile

To configure the name of the log file used to store system messages and the minimum severity level to log, use the logging logfile command. To disable logging to the log file, use the no form of this command.

logging logfile logfile-name severity-level [size bytes]

no logging logfile logfile-name severity-level [size bytes]

Syntax Description

logfile-name

Name of the log file to be used to store system messages.

severity-level

Number of the desired severity level at which messages should be logged. Messages at or numerically lower than the specified level are logged. Severity levels are as follows:

0—emergency: System unusable

1—alert: Immediate action needed

2—critical: Critical condition—default level

3—error: Error condition

4—warning: Warning condition

5—notification: Normal but significant condition

6—informational: Informational message only

7—debugging: Appears during debugging only

size bytes

(Optional) Specifies a maximum file size. The default file size is 10485760 bytes and can be configured from 4096 to 10485760 bytes.


Defaults

None

Command Modes

Global configuration

Supported User Roles

network-admin
vdc-admin

Command History

Release
Modification

4.0(1)

This command was introduced.


Usage Guidelines

This command does not require a license.

Examples

This example shows how to configure a log file called logfile to store system messages and set its severity level to 4:

switch# configure terminal 
switch(config)# logging logfile logfile 4 
switch(config)#

Related Commands

Command
Description

show logging logfile

Displays the log file.


logging message interface type ethernet description

To add the description for physical Ethernet interfaces and subinterfaces in the system message log, use the logging message interface type ethernet description command. To disable the printing of the interface description for physical Ethernet interfaces in the system message log, use the no form of this command.

logging message interface type ethernet description

no logging message interface type ethernet description

Syntax Description

This command does not have any arguments or password.

Defaults

None

Command Modes

Global configuration mode

Supported User Roles

network-admin
vdc-admin

Command History

Release
Modification

5.2(1)

This command was introduced.


Usage Guidelines

Make sure that you are in the correct VDC. To change the VDC, use the switchto vdc command.

This command does not require a license.

Examples

This example shows how to add the description for physical Ethernet interfaces and subinterfaces in the system message log:

switch# configure terminal
switch(config)# logging message interface type ethernet description

This example shows how to disable the printing of the interface description for physical Ethernet interfaces in the system message log:

switch# configure terminal
switch(config)# no logging message interface type ethernet description

Related Commands

Command
Description

logging monitor

Enables the device to log messages to the monitor based on a specified severity level or higher.

show logging monitor

Displays the monitor logging configuration.


logging module

To enable module log messages, use the logging module command. To disable module log messages, use the no form of this command.

logging module [severity-level]

no logging module

Syntax Description

severity-level

(Optional) Number of the desired severity level at which messages should be logged. Messages at or numerically lower than the specified level are logged. Severity levels are as follows:

0—emergency: System unusable

1—alert: Immediate action needed

2—critical: Critical condition

3—error: Error condition

4—warning: Warning condition

5—notification: Normal but significant condition—default level

6—informational: Informational message only

7—debugging: Appears during debugging only


Defaults

None

Command Modes

Global configuration

Supported User Roles

network-admin
vdc-admin

Command History

Release
Modification

4.0(1)

This command was introduced.


Usage Guidelines

This command does not require a license.

Examples

This example shows how to enable module log messages:

switch# configure terminal 
switch(config)# logging module 
switch(config)#

Related Commands

Command
Description

show logging module

Displays the module logging status.


logging monitor

To log messages to the monitor (terminal line), use the logging monitor command to enable the device.

To disable monitor log messages, use the no form of this command.

logging monitor [severity-level]

no logging monitor

Syntax Description

severity-level

(Optional) Number of the desired severity level at which messages should be logged. Messages at or numerically lower than the specified level are logged. Severity levels are as follows:

0—emergency: System unusable

1—alert: Immediate action needed

2—critical: Critical condition—default level

3—error: Error condition

4—warning: Warning condition

5—notification: Normal but significant condition

6—informational: Informational message only

7—debugging: Appears during debugging only


Defaults

None

Command Modes

Global configuration

Supported User Roles

network-admin
vdc-admin

Command History

Release
Modification

4.0(1)

This command was introduced.


Usage Guidelines

This configuration applies to Telnet and SSH sessions.

This command does not require a license.

Examples

This example shows how to enable monitor log messages:

switch# configure terminal 
switch(config)# logging monitor 
switch(config)#

Related Commands

Command
Description

show logging monitor

Displays the status of monitor logging.


logging server

To configure a remote syslog server at the specified hostname or IPv4/IPv6 address, use the logging server command. To disable the remote syslog server, use the no form of this command.

logging server host [severity-level [use-vrf VRF_name [facility {auth | authpriv | cron | daemon | ftp | kernel | local0 | local1 | local2 | local3 | local4 | local5 | local6 | local7 | lpr | mail | news | syslog | user | uucp}]]]

no logging server host

Syntax Description

host

Hostname or IPv4/IPv6 address of the remote syslog server.

severity-level

(Optional) Number of the desired severity level at which messages should be logged. Messages at or numerically lower than the specified level are logged. Severity levels are as follows:

0—emergency: System unusable

1—alert: Immediate action needed

2—critical: Critical condition—default level

3—error: Error condition

4—warning: Warning condition

5—notification: Normal but significant condition

6—informational: Informational message only

7—debugging: Appears during debugging only

use-vrf VRF_name

(Optional) Specifies the VPN routing and forwarding (VRF) instance. In Cisco NX-OS Release 4.2 or later releases, the default VRF is default.

facility facility

(Optional) Specifies the outgoing facility. The facilities are listed in the "System Message Logging Facilities" section on page 659. The default outgoing facility is local7.


Defaults

None

Command Modes

Global configuration

Supported User Roles

network-admin
vdc-admin

Command History

Release
Modification

4.0(1)

This command was introduced.


Usage Guidelines

This command does not require a license.

Examples

This example shows how to configure a remote syslog server at a specified IPv4 address using the default outgoing facility:

switch# configure terminal 
switch(config)# logging server 172.28.254.253 
switch(config)#

This example shows how to configure a remote syslog server at a specified hostname with severity level 5 or higher:

switch# configure terminal 
switch(config)# logging server syslogA 5 
switch(config)#

Related Commands

Command
Description

show logging server

Displays the configured syslog servers.


logging source-interface

To enable a source interface for the remote syslog server, use the logging source-interface command.

To disable the source interface, use the no form of this command.

logging source-interface loopback virtual_interface

no logging source-interface loopback virtual_interface

Syntax Description

loopback virtual_interface

Enables the loopback interface.The range is from 0 to 1023.


Defaults

None

Command Modes

Global configuration

Supported User Roles

network-admin
vdc-admin

Command History

Release
Modification

4.0(1)

This command was introduced.


Usage Guidelines

This command does not require a license.

Examples

This example shows how to enable a source interface for the syslog server:

switch# configure terminal 
switch(config)# logging source-interface loopback 5 
switch(config)#

logging timestamp

To set the logging time stamp units, use the logging timestamp command. To reset the logging timestamp units to the default, use the no form of this command.

logging timestamp {microseconds | milliseconds | seconds}

no logging timestamp {microseconds | milliseconds | seconds}

Syntax Description

microseconds

Specifies the time stamp unit in microseconds. The default units are seconds.

milliseconds

Specifies the time stamp unit in milliseconds.

seconds

Specifies the time stamp unit in seconds.


Defaults

None

Command Modes

Global configuration

Supported User Roles

network-admin
vdc-admin

Command History

Release
Modification

4.0(1)

This command was introduced.


Usage Guidelines

This command does not require a license.

Examples

This example shows how to set the logging time stamp units to microseconds:

switch# configure terminal 
switch(config)# logging timestamp microseconds 
switch(config)#

Related Commands

Command
Description

show logging timestamp

Displays the logging time stamp configuration.