Eugene Cernan, the last astronaut to walk on the moon - an experience that he said made him "belong to the universe," died on Monday at the age of 82, the U.S. space agency said.

Cernan, who was also the second man to walk in space, died surrounded by his family, the National Aeronautics and Space Administration said in a statement without providing details.

A separate statement from his family and released by NASA said his death came after "ongoing health issues."

Cernan and fellow Apollo 17 astronaut Harrison Schmitt became members of the most exclusive club in the universe on Dec. 11, 1972, when they stepped from their lunar landing module onto the moon's surface. Only 10 other people - all American astronauts - had done so before and none since.

"Oh, my golly," Cernan told mission control in Houston as he touched the moon. "Unbelievable."

For three days, the moon was home for Cernan and Schmitt. They rambled more than 19 miles (30 km) in their lunar roving vehicle and gathered more than 220 pounds (100 kg) of rocks during their 22 hours of exploration of craters and hills.

"I knew that I had changed in the past three days and that I no longer belonged solely to the Earth," Cernan wrote in a memoir titled "The Last Man on the Moon." "Forever more, I would belong to the universe."

Cernan was 38 years old when he blasted off for the moon on Dec. 7, 1972, as commander of Apollo 17. With Ronald Evans orbiting above in the command module, Cernan and Harrison Schmitt, a geologist, rode the lunar lander to the moon's surface four days later.

They explored for about seven hours each day and Cernan wrote that moonwalking was painful for him because he had injured a tendon in his leg two months earlier playing softball.

On the day before returning to the command module, Cernan drove the rover to a point away from the lunar module so that a camera on the vehicle could film their departure. He then paid tribute to his young daughter, Tracy.

"I took a moment to kneel and with a single finger, scratched Tracy's initials, TDC, in the lunar dust, knowing those three letters would remain there undisturbed for more years than anyone could imagine," Cernan wrote in his memoir.

The size 10-1/2 boot prints that Cernan made on his walk back to the module afterward marked the last steps man has taken on the moon. Cernan said he spoke spontaneously as he returned to the lunar module.

"As we leave the moon and Taurus-Littrow (a deep lunar valley where they had landed), we leave as we came, and God willing, as we shall return, with peace and hope for all mankind," he told mission control.

"As I take these last steps from the surface for some time to come, I'd just like to record that America's challenge of today has forged man's destiny of tomorrow. Godspeed to the crew of Apollo 17."

WANTED TO STAY

In a 2007 interview for NASA's oral history program, Cernan recalled his final moments before climbing back in the lander.

"Those steps up that ladder, they were tough to make," he said. "I didn't want to go up. I wanted to stay a while."

Apollo 17 was Cernan's last flight as an astronaut after 566 hours and 15 minutes in space.

Cernan was born March 14, 1934, and grew up near Chicago. He was in the military officers training program at Purdue University, where he first met Neil Armstrong, who would become the first moonwalker.

Cernan became a Navy test pilot and joined the astronaut corps in October 1963. His first space flight came three years later due to a tragedy. Cernan and Thomas Stafford had been designated to be the backups for Gemini 9 and had to take over the three-day mission when the original crew members were killed in a plane crash.

Cernan became the third person - following a Russian cosmonaut and U.S. astronaut Ed White - to make a spacewalk on the Gemini mission and set what was then a record by being outside the spacecraft for two hours and nine minutes.

In 1969, Cernan was the pilot of the Apollo 10 lunar module that came within 9.6 miles (15.6 km) of the moon's surface after separating from the command module. The descent toward the surface served as a dress rehearsal for Apollo 11, which two months later delivered the first men to the moon, Armstrong and Buzz Aldrin.

Cernan retired from NASA and the Navy in 1976. As a civilian he helped start Air One airline, worked as an energy and aerospace consultant, served as chairman of an engineering company and was a space commentator for ABC News.

In 2011, after NASA ended the space shuttle program, Cernan joined Armstrong in testifying before a congressional committee to urge the government not to give up on space exploration. Cernan was particularly critical of the decision by President Barack Obama's administration not to pursue the Constellation program, which aimed to send astronauts to the moon and Mars.

"I don't think he fully understands what traditional America is all about because he didn't literally grow up here," Cernan said of Obama in a 2012 interview with Fox News.

Cernan met his first wife, Barbara, who had been a flight attendant for Continental Airlines, on a plane. They divorced in 1981 after 20 years and one child and in 1987 he married Jan Nanna with whom he had two daughters.

Cernan is survived by his wife, Jan Nanna Cernan, his daughter and son-in-law, Tracy Cernan Woolie and Marion Woolie, step-daughters Kelly Nanna Taff and husband, Michael, and Danielle Nanna Ellis and nine grandchildren.