Petrichor is the scent of the earth that happens because of rain fall onto the soil and causes bacteria and spores to grow in the soil when it rains and after it rains the smell gets more noticeable.
The rain also displaces plant oil that plants naturally produce and it displaces the bacteria and spores as well creating that smell after it rains.