The linearized ideal magnetohydrodynamic (MHD) equations are cast into a set of global differential equations from which the field line resonance equations of the shear Alfven waves and slow magnetosonic waves are obtained naturally for finite beta plasmas in general magnetic field geometries with flux surfaces. The coupling between the shear Alfven waves and the magnetosonic waves is through the combined effects of geodesic magnetic field curvature and plasma pressure. For axisymmetric magnetospheric equilibria there is no coupling between the shear Alfven waves and the slow magnetosonic waves because the geodesic magnetic field curvature vanishes. We derive the asymptotic singular solutions of the MHD equations near the field line resonant surface. We perform numerical solutions of the field line resonance equations for a dipole magnetic field with constant plasma pressure and density along the magnetic field line. Similar to previous studies, the shear Alfven wave field line resonant frequency is roughly given by omega almost-equal=to cL-4 rho-1/2, where the coefficient c is roughly constant with respect to the L shell distance and rho is the plasma mass density. The slow magnetosonic wave resonant frequency is roughly proportional to P/rhoL2, where P is the plasma pressure, and is much smaller than the shear Alfven wave resonant frequency even for equatorial plasma beta as high as unity.