Formation tracking (FT) control aims at handling cooperative tasks in multi-agent systems (MASs) to achieve desired performance. In these tasks, the leader’s input is generally non-zero and unknown to all followers, i.e., its trajectory can be arbitrary and non-repetitive. In this paper, the additive property of linear systems is exploited to develop a unified framework for FT tasks of MASs, consisting of adaptive observer-based control (AOC) and iterative learning control (ILC). This framework employs an AOC controller to guarantee a fixed-shape formation between the leader and followers during the whole process, which reserves the initial condition for ILC. Also, it employs ILC to improve the FT performance of certain repetitive tasks (followers rotating around the leader) over the trials. This gives rise to a fully distributed algorithm working for a directed communication graph containing a spanning tree without requiring any eigenvalue information from the Laplacian matrix of the graph, which enables its application to MASs with a large number of agents. Comparisons are provided via a numerical simulation to show that the proposed combined AOC-ILC algorithm has less FT error than pure AOC (without ILC), which validates the feasibility and efficacy of this algorithm.