How to delete logs on S series switches

27

For S series switches (except the S1700), logs are stored first in the log buffer. When the number of logs reaches the threshold, they will be stored in the syslogfile or logfile folder of the storage card on the device. Both the log buffer and storage card can be cleared.
1. Delete logs from the log buffer.
- Run the reset logbuffer command in the user view to clear the log buffer.
- Run the reset trapbuffer command in the user view to clear the trap buffer.
2. Clear log files.
- Run the delete command in the user view to delete logs in log files of the storage card. If you want to delete certain information from the logfile folder in the flash card, run the following commands:
- delete flash:/logfile/xxx //Delete a certain log file. xxx is the name of the log file stored in the flash card.
- delete /unreserved flash:/logfile/xxx //Permanently delete a certain log file and it will not be found in the recycle bin, either.
- reset recycle-bin //Clear the recycle bin.

Other related questions:
How to delete an observing port on S series switches
For S series switches (except S1700 switches), perform the following configurations to delete an observing port: 1. Delete the binding between the observing port and mirrored port. - Port mirroring [HUAWEI] interface gigabitethernet x/x/x [HUAWEI-GigabitEthernetx/x/x] undo port-mirroring to observe-port x inbound/outbound/both [HUAWEI-GigabitEthernetx/x/x] quit - MQC-based traffic mirroring a. Delete the traffic policy applied to the system, a VLAN, or an interface. In the following example, a traffic policy applied to an interface is deleted. [HUAWEI] interface gigabitethernet x/x/x [HUAWEI-GigabitEthernetx/x/x] undo traffic-policy inbound/outbound [HUAWEI-GigabitEthernetx/x/x] quit b. Delete the traffic policy in the system view. [HUAWEI] undo traffic policy xxx c. Delete the traffic behavior containing the traffic mirroring action in the system view. [HUAWEI] undo traffic behavior xxx - ACL-based traffic mirroring Delete ACL-based traffic mirroring configured in the system or interface view. In the following example, ACL-based traffic mirroring is deleted in the system view. [HUAWEI] interface gigabitethernet x/x/x [HUAWEI-GigabitEthernetx/x/x] undo traffic-mirror inbound acl xxx [HUAWEI-GigabitEthernetx/x/x] quit - VLAN mirroring [HUAWEI] vlan xxx [HUAWEI-vlanxxx] undo mirroring inbound [HUAWEI-vlanxxx] quit - MAC address mirroring [HUAWEI] vlan xxx [HUAWEI-vlanxxx] undo mac-mirroring xxx inbound [HUAWEI-vlanxxx] quit 2. Delete the observing port configuration in the system view. [HUAWEI] undo observe-port x

Delete DNS parameters on S series switch
If an S series switch (except an S1700 switch) delivers the DNS server IP address to clients through DHCP, the DNS server IP address can be deleted using commands. For example, if the DNS server IP address 10.1.1.1/24 has been configured on a switch, you can delete it as follows: - If the original configuration is based on a global address pool: [Huawei] ip pool pool1 [Huawei-ip-pool-pool1] undo dns-list 10.1.1.1 //Delete the DNS server IP address. - If the original configuration is based on an interface address pool: [Huawei] interface vlanif 10 //Enter the view of the DHCP server interface connected to clients. [Huawei-Vlanif10] undo dhcp server dns-list 10.1.1.1 //Delete the DNS server IP address. - If the original configuration is based on a DHCP Option template: [Huawei] dhcp option template temp1 [Huawei-dhcp-option-template-temp1] undo dns-list 10.1.1.1 //Delete the DNS server IP address. Additionally, clients need to release their original IP addresses and apply for new IP addresses from the DHCP server.

Whether SNMP configurations for an S series switch can be cleared
For S series switches (except S1700), the following two methods can clear SNMP configurations: 1. Run the undo command corresponding to an SNMP feature command to clear SNMP configurations. 2. Run the undo snmp-agent command to clear all SNMP configurations. The configurations will be recovered if the snmp-agent command is executed again.

Delete entries in binding tables for IPSG (user-bind binding tables) on S series switches
Delete entries in a binding table for IPSG (user-bind binding table) on an S series switch (except the S1700) as follows: Binding entries include static entries and dynamic entries. Dynamic entries are automatically generated when DHCP snooping is enabled. To delete dynamic entries, disable DHCP snooping. Static entries are configured manually. To delete static entries, perform the following operations: 1. Run the display dhcp static user-bind all command to view all static binding entries on the switch. [HUAWEI] display dhcp static user-bind all 2. Delete binding entries as required. a. Delete the static binding entry of IP address 192.168.1.1. [HUAWEI] undo user-bind static ip-address 192.168.1.1 mac-address 0001-0001-0001 b. Delete the static binding entry of MAC address 0002-0002-0002. [HUAWEI]undo user-bind static mac-address 0002-0002-0002 c. Delete all static binding entries of GE0/0/1. [HUAWEI] undo user-bind static interface gigabitethernet 0/0/1 d. Delete all static binding entries in VLAN 10. [HUAWEI] undo user-bind static vlan 10 e. Delete all entries in the static binding table. [HUAWEI]undo user-bind static

If you have more questions, you can seek help from following ways:
To iKnow To Live Chat
Scroll to top