The U-2 spy plane, the high-flying aircraft that was often at the heart of Cold War suspense, is enjoying an encore.

Four years ago, the Pentagon was ready to start retiring it. But Congress blocked that move, saying the plane was still useful. And so it is. Because of updates and changes in the use of its powerful sensors, it has become the most sought-after spy craft in a very different war in Afghanistan. As it shifts from hunting for nuclear missiles to detecting roadside bombs, it is outshining even the unmanned drones in gathering a rich array of intelligence used to fight the Taliban.

All this is a remarkable change from the U-2's early days as a player in U.S.-Soviet espionage. Designed to find Soviet missiles, it became famous in 1960 when Francis Gary Powers was shot down in one while flying across the Soviet Union and again in 1962 when another U-2 took the photographs that set off the Cuban missile crisis.

Newer versions of the plane have gathered intelligence in every war since then and still monitor countries like North Korea.

Now the U-2 and its pilots, once isolated in their spacesuits at 70,000 feet, are in direct radio contact with the troops in Afghanistan. And instead of following a rote path, they are now shifted frequently in midflight to scout roads for convoys and aid soldiers in firefights.

In some ways, the U-2, which flew its first mission in 1956, is like an updated version of an Etch A Sketch in an era of high-tech computer games.

"It's like after all the years it's flown, the U-2 is in its prime again," said Lt. Col. Jason Brown, who commands an intelligence squadron that plans the missions and analyzes much of the data. "It can do things that nothing else can do."

One of those things, improbably enough, is that even from 13 miles up its sensors can detect small disturbances in the dirt, providing a new way to find makeshift mines that kill many soldiers.

In the weeks leading up to the recent offensive in Marjah, military officials said, several of the 32 remaining U-2s found nearly 150 possible mines in roads, enabling the Marines to blow them up before approaching the town.

Marine officers say they relied on photographs from the U-2's old film cameras, which take panoramic images at such a high resolution that they can see insurgent positions, while the U-2's newer digital cameras beamed back frequent updates on 25 spots where the Marines thought they could be vulnerable.

In addition, the U-2's altitude, once a defense against antiaircraft missiles, enables it to scoop up signals from insurgent phone conversations that mountains would otherwise block. As a result, Brown said, the U-2 is often able to collect information that suggests where to send the Predator and Reaper drones, which take video and also fire missiles.

But the black jet with narrow wings is difficult to fly, and missions are grueling and dangerous. The U-2s used in Afghanistan and Iraq commute each day from a base near the Persian Gulf, and the trips can last nine to 12 hours.