The hard and brittle shale formation is prone to collapse and instability, and the penetration of drilling fluid along the bedding reduces the mechanical properties of rock near the borehole wall, resulting in serious downhole accidents. Therefore, in this paper, the geomechanical parameters of the reservoir in the Longmaxi formation of Jiaoshiba were determined by field hydraulic fracturing and laboratory experiments. Then, the stress distribution model of borehole wall under the condition of underbalanced seepage flow is established based on the experimental results obtained by mechanical experiments on underground cores. The instability zone of borehole wall under the condition of underbalance is calculated and analyzed. The results show that the two-way horizontal ground stress of the Longmaxi formation is higher than 2.2 MPa/100 m, and the original ground stress is high. Moreover, the mechanical parameters of the stratified shale stratum matrix and weak surface are significantly different. The cohesion (4.7 MPa) and the angle of internal friction (26.9°) of bedding plane are significantly lower than that of the matrix (7.77 MPa) and the angle of internal friction (46.7°). Hard and brittle shale is easy to be destroyed along the stratification. Under the condition of underbalanced seepage, the mechanical properties of borehole shale can be stable. It is found that when the borehole axis is vertically stratified, the collapse pressure is the lowest, while in other drilling directions, the drilling fluid density needs to be increased by 0.5 g/cm3 to maintain the borehole stability. With the increase of the inclination angle of bedding plane, the wall failure area increases. The results of this study can provide guidance and suggestions for drilling in Jiaoshiba block and other permeable hard and brittle shale formations.