This application discloses a defect
processing method, a defect
processing device, an electronic device, and a
server, belonging to the field of electronic device technology. The method on the first electronic device side includes: when a first operational anomaly event occurs, the first electronic device sends first defect data to a
cloud server; the first defect data includes defect data of the first operational anomaly event collected by the first electronic device through pre-embedded points; the first electronic device receives a first Berkeley Data Packet Filter (BPF) program and a first path sent by the
cloud server; the first path includes the critical path of the first operational anomaly event; the first electronic device mounts the first BPF program to the first path; when the first electronic device runs on the first path, it triggers the execution of the first BPF program, and collects second defect data of the first operational anomaly event through the first BPF program.