C Commands
This chapter describes the Cisco NX-OS Open Shortest Path First (OSPF) commands that begin with C.
clear ip ospf neighbor
To clear neighbor statistics and reset adjacencies for Open Shortest Path First (OSPF), use the clear ip ospf neighbor command.
clear ip ospf [instance-tag] neighbor {* | neighbor-id | interface-type number | loopback number | port-channel number} [vrf vrf-name]
Syntax Description
Command Default
None
Command Modes
Command HistoryAny command mode
|
|
---|---|
5.0(3)N1(1) |
This command was introduced. |
Usage Guidelines
Use the clear ip ospf neighbor command to clear neighbor information from the show ip ospf neighbor command. Use the instance-tag argument to clear the neighbor details from one OSPF instance. If you do not use the instance-tag argument, Cisco NX-OS clears the neighbor details from all OSPF instances. Use the show ip ospf neighbor command to find the neighbor ID.
This command requires the LAN Base Services license.
Examples
This example shows how to clear all OSPF neighbor details for neighbor 192.0.2.1 for instance tag 201:
switch# clear ip ospf 201 neighbor 192.0.2.1
This example shows how to clear all OSPF neighbor details for all OSPF instances:
switch# clear ip ospf neighbor *
This example shows how to clear all OSPF neighbor details for all neighbors on Ethernet interface 1/2 for OSPF instance 202:
switch# clear ip ospf 202 neighbor ethernet 1/2
Related Commands
|
|
---|---|
show ip ospf neighbor |
Displays details for OSPF neighbors including the neighbor ID. |
clear ip ospf policy statistics
To clear policy statistics for Open Shortest Path First (OSPF), use the clear ip ospf policy statistics command.
clear ip ospf [instance-tag] policy statistics {area area-id filter-list {in | out} | redistribute {bgp autonomous-system | direct | eigrp id | ospf id | rip id | static}} [vrf vrf-name]
Syntax Description
Command Default
None
Command Modes
Command HistoryAny command mode
|
|
---|---|
5.0(3)N1(1) |
This command was introduced. |
Usage Guidelines
Use the clear ip ospf statistics command to learn the policy statistics shown in the show ip ospf policy statistics command. Use the instance-tag argument to clear the policy statistics from one OSPF instance. If you do not specify the instance tag, Cisco NX-OS clears the policy statistics from all OSPF instances. Use the show ip ospf policy statistics command to to view the statistics that you are clearing.
This command requires the LAN Base Services license.
Examples
This example shows how to clear all OSPF policy statistics for area 99 inbound filtered routes for OSPF 201:
switch# clear ip ospf 201 policy statistics area 99 filter-list in
This example shows how to clear all OSPF policy statistics for all BGP redistributed routes for OSPF 202:
switch# clear ip ospf 202 policy statistics redistribute bgp
Related Commands
|
|
---|---|
show ip ospf policy statistics |
Displays details for OSPF policies. |
clear ip ospf redistribution
To clear redistribution information for Open Shortest Path First (OSPF) , use the clear ip ospf redistribution command.
clear ip ospf redistribution [vrf {vrf-name | all | default | management}]
Syntax Description
Command Default
None
Command Modes
Command HistoryAny command mode
|
|
---|---|
5.0(3)N1(1) |
This command was introduced. |
Usage Guidelines
This command requires the LAN Base Services license.
Examples
This example shows how to clear redistribution information:
switch# clear ip ospf redistribution
Related Commands
|
|
---|---|
feature ospf |
Enables the OSPF feature. |
clear ip ospf statistics
To clear Open Shortest Path First (OSPF) event statistics, use the clear ip ospf statistics command.
clear ip ospf [instance-tag] statistics [vrf vrf-name]
Syntax Description
Command Default
None
Command Modes
Command HistoryAny command mode
|
|
---|---|
5.0(3)N1(1) |
This command was introduced. |
Usage Guidelines
Use the clear ip ospf statistics command to clear the event statistics from one or more OSPF instances. If you do not specify the instance-tag argument, Cisco NX-OS clears statistics from all OSPF instances. Use the show ip ospf statistics command to to view the statistics that you are clearing.
This command requires the LAN Base Services license.
Examples
This example shows how to clear all OSPF event statistics:
switch# clear ip ospf statistics
Related Commands
|
|
---|---|
show ip ospf statistics |
Displays event statistics for OSPF. |
clear ip ospf traffic
To clear Open Shortest Path First (OSPF) traffic statistics, use the clear ip ospf traffic command.
clear ip ospf [instance-tag] traffic [interface] [vrf vrf-name]
Syntax Description
Command Default
None
Command Modes
Command HistoryAny command mode
|
|
---|---|
5.0(3)N1(1) |
This command was introduced. |
Usage Guidelines
Use the clear ip ospf traffic command to clear the traffic statistics from one or more OSPF instances. If you do not specify the instance-tag argument, Cisco NX-OS clears traffic statistics from all OSPF instances. Use the show ip ospf traffic statistics command to view the statistics that you are clearing.
This command requires the LAN Base Services license.
Examples
This example shows how to clear OSPF traffic statistics for OSPF 100:
switch# clear ip ospf 100 traffic
Related Commands
|
|
---|---|
show ip ospf traffic statistics |
Displays OSPF traffic statistics. |
clear ip traffic
To clear IP traffic information, use the clear ip traffic command.
clear ip traffic
Syntax Description
This command has no arguments or keywords.
Command Default
None
Command Modes
Command HistoryAny command mode
|
|
5.0(3)N1(1) |
This command was introduced. |
Examples
This example shows how to clear the IP traffic information:
switch(config)# clear ip traffic
Related Commands
|
|
---|---|
show ip traffic |
Displays IP traffic information. |