The dynamic stress concentration on quadratic and U-shaped cavities in half space, which are similar to the cross-section of the tunnels, is solved in this paper impacted by SH-wave. The analytical solution for the cavity in elastic half space is gained by the complex function method. In the complex plane, the scattering wave which satisfies the zero-stress condition at the horizontal surface can be constructed, the problem can be inverted into a set of algebraic equations to solve coefficients of the constructed scattering wave by least square method. For the earthquake-resistance researches, the numerical examples of the dynamic stress concentration around the quadratic and U-shaped cavities impacted by SH-wave are given. The influences of the dynamic stress concentration by the incident wave number and angle, the depth and shape of the cavity are discussed. It is showed that the interaction among the wave, the surface and the shallow buried tunnels should be cared in half space. In this situation, the dynamic stress concentration around the tunnel is greater obvious than the whole space.