The invention discloses a method for detecting a DOS/DDOS (denial of service/distributed denial of service) attack. The method comprises the following steps of: firstly extracting needed flow characteristic parameters from network stream data, determining abnormal time points and constructing a historical time window by analyzing the flow characteristic parameters, and then finding out first N destination IPs (internet protocols) with maximum flows for the abnormal time points, determining an abnormal destination IP by analyzing sub streams including all the selected destination IPs in the horizontal time window, and finally, confirming the attack and recognizing an abnormal stream. The method is different from a conventional packet-by-packet analyzing method, adapts to the characteristic of the huge flow of a backbone network, can meet the requirement on real-time performance in the abnormality detection of the Backbone Network, can detect the DoS/DDoS attack more precisely in the backbone network, and can recognize an attack stream in the backbone network, so that a network manager can set a router in time, filters the flow sent by an attacker, and prevents the flow from harming a destination host.