< Home

reset ospf

Function

The reset ospf counters command resets the OSPF counter.

The reset ospf process command restarts the OSPF process.

The reset ospf redistribution command clears routes imported by OSPF.

Format

reset ospf [ process-id ] counters [ neighbor [ interface-type interface-number ] [ router-id ] ]

reset ospf [ process-id ] process [ flush-waiting-timer time | graceful-restart ]

reset ospf [ process-id ] redistribution

reset ospf [ process-id ] counters maxage-lsa

Parameters

Parameter Description Value
process-id Indicates the OSPF process ID.

If the parameter is not specified, all OSPF processes are restarted.

The value is an integer ranging from 1 to 65535.
neighbor The statistics of neighbors for the interface. -
interface-type interface-number Specifies the type and the number of the interface. -
router-id The Router ID of the neighbor. In dotted decimal notation.
flush-waiting-timer time Specified the time when the LSA is generated. The parameter takes effect only when it is set. The value is an integer that ranges from 1 to 40, in seconds.
graceful-restart Indicates that graceful restart is enabled. -

Views

User view

Default Level

3: Management level

Usage Guidelines

Usage Scenario

The reset ospf command can be used to clear OSPF information to reset the board.

If OSPF connections are reset, OSPF neighbor relationships will be interrupted and the original information cannot be restored. Exercise caution before running the reset ospf command.

Configuration Impact

After the reset ospf process command is used to restart OSPF, the following situations may occur:

  • If the router ID is changed, a new router ID will take affect after the command is run.

  • Re-elect DR and BDR.

  • OSPF configuration will not be lost before OSPF restarts.

Precautions

Configuring the flush-waiting-timer parameter when OSPF starts, you can clear invalid LSAs within the set time before LSAs time out.

Whether all invalid LSAs on other routers can be deleted is related to the set time.

When the FW restarts an OSPF process, the neighboring router always reserves invalid LSAs. This occupies the memory of the system. These LSAs are deleted only when they expire, that is, when the LS age field in the LSA reaches 3600 seconds. After the reset ospf is used to restart an OSPF process and only when the router ID is changed, the FW generates an LSA in the set time and sets the LS age field to 3600 seconds. After receiving the LSA, other routers delete the LSA immediately from their LSDBs. If a device does not send all the LSAs within the set time, other neighboring routers still store some invalid LSAs.

Example

# Reset the OSPF counters.

<sysname> reset ospf counters  

# Restart the OSPF process.

<sysname> reset ospf process 

# Configure the OSPF to import routes again.

<sysname> reset ospf redistribution
Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
< Previous topic Next topic >