The air molecules tell each other to look out, you are about to bet hit in the butt, when an airplane is flying throught he air. These little guys send the message forward about 1100 feet a second, and the molecules move as required to let the airplane go by.
As the airplane gets faster, the little guys have less time to react and get out of the way. Finally when the airplane gets above 1100 feet a second, the molecules get stacked up because no one told them in time to move over. The get compressed and the pressure rises sharply as the molecules groan in pain. The are suddenly going very fast and when the airplane goes by, they have to slow down again, creating a second pressure change in a hurry. The first change causes a wave that we hear as a boom, and that wave is in the shape of a funnel being drug along by the airplane. The faster the airplane is, the sharper the shape of the funnel. As the funnel drags along the ground we hear the pressure rise as it passes us. The second pressure wave from the transitiion back to subsonic also radiates as a funnel shape and follows the first and when it passes, we hear it again.
When those little guys are stacking up, the heat they contain stacks also and that is what causes the temperature rise on the surfaces.
I watched the shuttle go by south of here in Texas a number of years ago. It was 13 minutes before the sonic boom passed where I was, which at 1100 feet a second meant it was 168 miles away when it went by.
They are going pretty fast when they first enter the atmosphere, around Mach 22 I think. That is about 22 times faster than a 22 bullet.
Also, if they enter too steeply, they bounce off the atmosphere and the second rentry could be deadly as it would be steeper yet.