Hyper-redundant manipulators (HRMs) exhibit promising adaptability and superior dexterity in cavity detection tasks, owing to their snake-like segmented backbones. Due to the safety concern in contactless operating tasks, reliable motion planning in a confined environment for HRMs is very challenging. However, existing expanding-based obstacle avoidance methods are not feasible in narrow environments, as they will excessively occupy free spaces required for maneuvering. In this work, a local collision-free motion planning strategy based on dynamic safety envelope (DSE) is proposed for HRMs. First, the local motion of HRMs is analyzed in detail, and DSE is proposed for the first time to describe the boundary of the collision-free area. Then, to maximize the efficient utilization of narrow spaces, a reference trajectory for HRM is roughly planned without expanding obstacles. Further, a tip-guided trajectory tracking method based on configuration prediction is proposed by considering the discrete characteristics of rigid links to avoid obstacles. During the tracking process, DSEs are applied to evaluate collision risk and optimize the configuration. Finally, to validate the effectiveness of our proposed method, simulations are conducted, followed by experiments by using a 18-degrees of freedom mobile HRM prototype system.