Optically levitated nonspherical particles in vacuum are excellent candidates for torque sensing, rotational quantum mechanics, high-frequency gravitational wave detection, and multiple other applications. Many potential applications, such as detecting the Casimir torque near a birefringent surface, require simultaneous cooling of both the center-of-mass motion and the torsional vibration (or rotation) of a nonspherical nanoparticle. Here we report the first 5D cooling of a levitated nanoparticle. We cool the 3 center-of-mass motion modes and 2 torsional vibration modes of a levitated nanodumbbell in a linearly-polarized laser simultaneously. The only uncooled rigid-body degree of freedom is the rotation of the nanodumbbell around its long axis. This free rotation mode does not couple to the optical tweezers directly. Surprisingly, we observe that it strongly affects the torsional vibrations of the nanodumbbell. This work deepens our understanding of the nonlinear dynamics and rotation coupling of a levitated nanoparticle and paves the way towards full quantum control of its motion.