Combinatorial t-designs have wide applications in coding theory, cryptography, communications and statistics. It is well known that the supports of all codewords with a fixed weight in a code may give a t-design. In this paper, we first determine the weight distribution of a class of linear codes derived from the dual of extended cyclic code with two non-zeros. We then obtain infinite families of 2-designs and explicitly compute their parameters from the supports of all the codewords with a fixed weight in the codes. By simple counting argument, we obtain exponentially many 2-designs.Combinatorial t-designs have very important applications in coding theory, cryptography, communications and statistics. There has been an interplay between codes and t-designs for both directions. On one hand, a linear code over any finite field can be derived from the incidence matrix of a t-design and much progress has been made and documented in [1,6,19,20]. On the other hand, linear and nonlinear codes might both hold t-designs. Till now, 4-designs and 5-designs with fixed parameters were only derived from binary and ternary Golay codes. The largest t for which the infinite families of t-designs could be obtained from linear codes is t = 3. In 2017, Ding and Li [8] obtained infinite families of 2-designs from p-ary Hamming codes, ternary projective cyclic codes, binary codes with two zeros and their duals as well as the infinite families of 3-designs from the extended codes of these codes and RM codes. Afterwards, infinite families of 2-designs and 3-designs were constructed from a class of binary linear codes with five weights [9]. For other constructions of t-designs, for example, we refer to [2,5,17,18].The rest of this paper is organized as follows. In Section 2, we introduce some notation, together with some preliminary results on affine-invariant codes and 2designs, which will be used in subsequent sections. In Section 3, we present the weight distributions of a class of linear codes derived from the dual of the extended cyclic codes with two non-zeros. By proving that the derived codes are affine-invariant, we then obtain infinite families of 2-designs and explicitly determine their parameters. The proof of the main results are given in Section 4. Section 5 concludes the paper.