In most cases it is replaced with water, either by design (when we pump it in) or by natural permeation from surrounding rocks (rain seeping through will replace it eventually). Sometimes, the surrounding earth structure is good enough to support voids in the structure.
In many places the earth has subsided after oil extraction. Some studies suggest that much of Louisanna is doing so. Also here is an interesting video: www.youtube.com/watch?v=Pys1tZWrKxA