In 1963 Cooper piloted the longest and last Mercury spaceflight, Mercury-Atlas 9. During that 34-hour mission he became the first American to spend an entire day in space, the first to sleep in space, and the last American launched on an entirely solo orbital mission. Despite a series of severe equipment failures, he managed to successfully complete the mission under manual control, guiding his spacecraft, which he named Faith 7, to a splashdown just 4 miles (6. 4 km) ahead of the recovery ship. Cooper became the first astronaut to make a second orbital flight when he flew as Command Pilot of Gemini 5 in 1965. Along with Pilot Pete Conrad, he set a new space endurance record by traveling 3,312,993 miles (5,331,745 km) in 190 hours and 56 minutes—just short of eight days—showing that astronauts could survive in space for the length of time necessary to go from the Earth to the Moon and back.