< Home

enable log

Function

The enable log command enables the logging function.

The undo enable log command disables the logging function.

By default, the logging function is disabled.

Format

enable log [ config | error | state | snmp-trap ]

undo enable log [ config | error | state | snmp-trap ]

Parameters

Parameter Description Value
config Enables the configuration log. -
state Enables the state log. -
error Enables the error log. -
snmp-trap Enables the SNMP trap log. -

Views

OSPF view

Default Level

2: Configuration level

Usage Guidelines

Usage Scenario

Running the enable log command can enable the logging function. You can view running status of devices based on logs, facilitating device maintenance.

If the undo enable log command is executed, the logging function will be disabled. Then, running status of devices will be not displayed. This is inconvenient for network maintenance.

Precautions

Configuring different parameters in the enable log command can display different log information. If no parameter is not specified, the command output displays all log information.

Example

# Enable the OSPF logging function.

<HUAWEI> system-view
[HUAWEI] ospf 1
[HUAWEI-ospf-1] enable log 
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >