The second atmosphere was formed by outgassing. This means that volcanic eruptions that released CO2, N2O, and H2O aided in forming this atmosphere. The gases, that come from the melting of the Earth's crust, were released into the air after the volcanic activity.