A distributed control scheme based on historical information is designed to solve the problem of stable control of multi-agent systems under denial of service (DoS) attacks in this article. It achieves the control objective of bipartite output containment control, that is, the output states of the followers smoothly enter the target area. The control scheme updates the states of followers through historical information in the control protocol when agents are subjected to DoS attacks. A distributed state observer with a storage module is designed to efficiently estimate the state of followers and store the observed information as history information. The historical information of control protocol calls is not necessarily the real state information in the existence of DoS attacks. Consequently, a closed-loop feedback state compensator is designed. Then, the state compensator is converted from the time domain to the frequency domain for stability analysis using the Nyquist criterion. It is obtained that an upper bound on the amount of historical information can achieve the bipartite output trajectories containment of the controlled system. The output trajectories of the followers converge into two dynamic convex hulls, one of which is surrounded by multiple leaders, and the other is a convex hull with opposite signs of the leaders. Finally, a numerical simulation is used to verify the proposed control scheme, and the operability of the scheme is further demonstrated in a physical experiment.