There are several different, but equivalent definitions of geodesics in a Riemannian manifold, based on two characteristic properties: geodesics as shortest curves and geodesics as straightest curves. They are generalized to sub-Riemannian manifolds, but become non-equivalent. We give an overview of different approaches to the definition, study and generalization of sub-Riemannian geodesics and discuss interrelations between different definitions. For Chaplygin transversally homogeneous sub-Riemannian manifold Q, we prove that straightest geodesics (defined as geodesics of the Schouten partial connection) coincide with shortest geodesics (defined as the projection to Q of integral curves (with trivial initial covector) of the sub-Riemannian Hamiltonian system). This gives a Hamiltonization of Chaplygin systems in non-holonomic mechanics.We consider a class of homogeneous sub-Riemannian manifolds, where straightest geodesics coincide with shortest geodesics, and give a description of all sub-Riemannian symmetric spaces in terms of affine symmetric spaces.