To convert oxygen to ozone, the following reaction happens:
3O2 + energy --> 2O3
Since O2 (Oxygen) is more stable than Ozone (O3), therefore energy is required to perform such reaction and to break an oxygen molecule down to seperate oxygen atoms (O1). Then the O1 will bond with the other oxygen atoms (O2) to form Ozone (O3). This normally happens when thunder "tears" the sky "apart", the super high energy from the thunder electrical discharge will trigger this kind of reaction.