Near Ras Lanuf, I had seen teen-agers with kerchiefs around their necks helping doctors rush wounded men into the overwhelmed emergency ward, but it didn’t occur to me that they might be actual Boy Scouts. Osama explained that Qaddafi had once banned the Scouts as an insidious Western influence but later allowed them to reëmerge. After the uprising, most police disappeared from the streets, and tens of thousands of migrant workers fled the country. Scouts stepped in to fill public-service jobs, helping at the hospitals, sorting out aid supplies, even directing traffic. It was Muhannad’s Scout membership that drew him into the uprising. “Remember the Scout oath?” Osama asked. “Duty to God and to your country, and to help others.”

As Qaddafi’s Army advanced, a number of Libyans told me that, if Benghazi fell, they would retreat to the Green Mountains, east of the city, to fight a guerrilla war. Like many of the rebel claims, these avowals sounded hollow. But the Green Mountains have long held an imaginative appeal to Libyans. An exquisitely verdant region in a country where grass and trees are rare, it borders the spectacular ruins of ancient Cyrene, a Greco-Roman temple city. The mountains also provided the backdrop to modern Libya’s bloody quest for nationhood—where the country’s greatest hero, Omar Mukhtar, led a protracted guerrilla war against the Italians, who in 1911 invaded Libya, resolving to seize it from the Ottomans and make it Italy’s “Fourth Shore.” Mukhtar and his band hid out in the canyons and caves of the Green Mountains for nearly twenty years before the Italians finally caught him, in 1931. By then, Mussolini’s troops had despoiled the countryside and imprisoned most of the people of eastern Libya; as many as a quarter of them died from disease and starvation. Public hangings and firing squads were common.

Some volunteers were given a rudimentary education in how to clean, load, and ﬁre a Kalashnikov; many were not. One said, “The boys at the front, some of them have never seen a gun before.”

Many Libyans were held in two large concentration camps: one in Suluq, a dusty town near Benghazi, and the other in the sands of Al Uqaylah. My friend Zaid, a thirty-two-year-old safety engineer turned revolutionary driver, lived in Suluq, and as we drove through Al Uqaylah one day he nodded toward the bleak white dunes and mentioned that his great-grandfather, his great-grandmother, and their six children had been interned there. Four of the eight died. “One of the ones that survived was my grandfather,” Zaid said. “But he died young, at around fifty, of kidney failure. They had to drink water from rain pools that formed on the desert. The water was full of minerals, and it gave them kidney stones.”

After a quick trial, Omar Mukhtar was hanged in Seluc, in front of twenty thousand of his imprisoned countrymen, whom the Italians forced to watch. It was the crowning moment of what would today be called a successful counterinsurgency campaign. It took Libya twenty years after Mukhtar’s death to become an independent nation. In the meantime, the Italians made it theirs, hammering the colonial possession of “Libya” out of the three regions of the old Ottoman wilayat: Cyrenaica, in the east, with Benghazi as its capital; Tripolitania, in the west, extending to the Tunisian border, with Tripoli as its capital; and Fezzan, the vast empty space to the south. The Italians colonized the territory with their soldiers and shopkeepers and poor farmers; they built roads and a railway, and erected statues, plazas, and cathedrals.

Italy’s dominance ended with the Second World War, which turned Libya into a proxy battleground, with the British and the Americans fighting the Italians and the Germans. These armies pursued each other along the same coastal road as today’s rebels and Qaddafi’s forces. After Italy’s defeat, in 1943, the British set up military administrations to govern Tripolitania and Cyrenaica, while the French ruled Fezzan. Tripoli and Benghazi remained as de-facto capitals of their separate regions.

In 1951, two years after Libya’s independence was approved by the newly formed United Nations, the country was reborn as a kingdom. Idris Sanusi I was a reluctant leader, an aging scion of an Islamist sect, the Sanusiyya, which had emerged during the nineteenth century, under Ottoman rule. Preaching a return to an austere, Islamic way of life, the Sanusiyyas were analogous to the Wahhabi sect of the Arabian peninsula. During his reign, Idris lived primarily in the east, and proclaimed the city of Bayda, east of Benghazi, the Libyan capital.

At the time of independence, Libya was one of the poorest nations on earth; its main exports were scrap metal from the war and esparto grass. Then oil was discovered, and in 1961 the country exported its first shipment of crude. In the next few years, the rudiments of a modern state began to emerge. Benghazi boasted a new university and hospitals, various foreign consulates—including one for the United States—an airport, a ferry port, and a sprawling sports complex.

In 1969, a coup was launched from Benghazi’s Army barracks, led by a twenty-seven-year-old captain, Muammar Qaddafi. Within a few years, Qaddafi, who began as a nationalist protégé of Gamal Abdel Nasser, had reinvented himself as a kind of Bedouin seer. Loosely combining elements of socialism and Islam, along with his own erratic ideas, he abolished private enterprise, expropriated foreign-owned property, and renamed the country the Great Socialist People’s Libyan Arab Jamahiriyah—the State of the Masses, in which he was not the President but the Brother Leader.

Other than Qaddafi, who replaced most of Libya’s modern history with his own cult of personality, there are precious few national heroes in Libya. Only Mukhtar has been permitted to remain, and he continues to provide a touchstone, in much the same way that the nineteenth-century poet and journalist José Martí has served revolutionary Cuba. There are Omar Mukhtar streets—Benghazi has one—and there is an Omar Mukhtar University, in Bayda; his face is on one of the banknotes. The graphic artists of the anti-Qaddafi revolution have appropriated Mukhtar as well, superimposing his gray-bearded image over the revived Libyan flag, on posters and decals and billboards.

Mukhtar’s son, Muhammed Omar, is still alive—he is ninety years old—and in late February I visited his house in Benghazi. A tall, handsome man, he was dressed in long black-and-white robes. When I asked him what it meant to be the son of Omar Mukhtar in the time of the new Libyan revolution, he said simply, “I am with the revolution.” Qaddafi had started out well, he said, but in recent years he had gone down the “wrong path.” Libya, he said, needed a change. “It’s over for Qaddafi. The only solution is for him to leave the country.”

In the early days of the uprising, I heard this wish expressed frequently by Libyans. “Qaddafi go” was a common refrain in Benghazi’s street demonstrations, and was ubiquitous as graffiti. Even if Libyans do manage to get rid of the dictator who has ruled them for forty-two years, the question of what Libya is and who its citizens are as a people will be a hugely difficult one to answer. It struck me in Benghazi that it wasn’t enough for Qaddafi to step down; if Libyans were to reimagine themselves as a nation and as a people, he needed to leave the land that he had made synonymous with himself.

In the course of four days in mid-March, Qaddafi’s troops made their way from the west toward the rebel stronghold of Benghazi, moving along the coastal highway through a string of towns: Ras Lanuf, Brega, and Ajdabiya. The rebels’ goal was clear—close down the road and hold off Qaddafi’s men—but the progress of combat was unpredictable. The front line moved constantly, placed not in strategic locations but wherever a handful of rebels decided to gather and fight. At Ras Lanuf, I found an unusually large group—hundreds of vehicles and several thousand rebels. Qaddafi’s forces did not generally attack before lunch, and so a couple of hundred fighters were holding an early-afternoon prayer session next to a roadside ammunition dump, led by a man in a seventies-style brown patent-leather jacket and slacks. In the middle of the service, we began to hear the thump of artillery. The leader continued the prayers, and though some men yelled at him to hurry up, most of them stayed kneeling before him. He told the fighters, “If you do not want to be martyred, leave your weapon behind and go, and no one will say anything to you.” By the time the men had finished praying, the shells were exploding much closer. The men streamed onto the road and went to their gun positions, shouting “Allahu akbar,” “God is great.” There was a tumult as fighters surged toward Qaddafi’s artillery and began firing back with rockets and guns. Then the shells came slamming around us and everyone rushed to escape.

At a pit stop in our retreat, a van pulled up next to my car. A smiling, portly fellow in his thirties climbed out and approached. He held up two crude-looking tin cans with fuses. They were filled with TNT. “They are fish bombs,” he said. He was a former fisherman and had used such explosive devices to catch his prey. But the bombs, which had to be used within throwing range, had little effect on Qaddafi’s tanks.

“So you’ve lost Ras Lanuf,” I said.

“No,” he said. “We are just retreating, not giving up our positions. Tomorrow, inshallah, we will return and reoccupy them.” At that moment, a friend of his loosed a pointless bullet from his AK-47. We all jumped, and the fisherman told him to stop. I asked if they were afraid, and he shook his head. “Just worried,” he said, smiling gamely. “If we were afraid, we wouldn’t come here.”

In war, of course, it is possible to be brave and afraid at once, and in Libya that was the norm. Earlier that day, a young man had been vaporized by an exploding rocket. Many of the rebels immediately panicked and fled, but some stayed, and, eventually, a number of others summoned their courage and trailed back. For many of these men and boys, conditioned by living under Qaddafi’s dictatorship, the mere act of appearing openly in public to shout their defiance represented an exorcism of fear. Standing their ground and fighting their ruler’s troops, though, was something else entirely.

The next morning, I headed out from Brega to see how far Qaddafi’s men had advanced. A rebel sentry with a blackened face told me to go only as far as Al Uqaylah, twenty-five miles to the west: “It’s not safe past there.” I found the front line about a mile beyond Al Uqaylah, a huddle of roadside snack shacks and trash heaps. In the middle of nowhere was a large, green-painted metal archway over the two-lane road, with barely a dozen battlewagons assembled there, camouflaged with smeared mud or spray-painted with slogans in the red, green, and black of the revolutionary flag. Since the fighting had erupted, the rebels had created front lines at these symbolic gateways. It was as if they needed a visual signpost to underscore their decision to face their enemy, and possibly to die, in that exact spot. No one had dug trenches or piled up sandbags to protect against the inevitable onslaught. A few dozen rebels stood watching, like firemen waiting for an alarm bell to go off, without any discernible plan about what they might do when it did.

Outside the gatehouse, a fighter began shouting, red-faced and spitting; he claimed to have heard that Qaddafi’s forces were cutting off children’s feet and then making them go on TV to say that the rebels had done it. It was an implausible charge, but, when everything that is routine about a society is violently altered, anything can seem possible. Libyans who until a few weeks earlier had coexisted peacefully, if resentfully, with their ruler now believed him capable of any evil.

More fighters showed up, and some onlookers, too, until there were perhaps forty vehicles pulled up in front of the gate—the entirety of the force defending Al Uqaylah. Then a screaming din came, as a jet fighter dived in out of the opaque sky and dropped a bomb about a hundred feet away, near the gate and a guard post next to it. There was a huge explosion, and rocks and dirt landed everywhere, but no one had been hurt. Everyone began getting in their cars and, amid panicked shouting, raced away. It seemed likely that there was no rebel front line anymore, and no real deterrent to Qaddafi’s forces.

The imminent collapse of the rebels in Libya had set off an international argument about whether the West should intercede. In Iraq and Bosnia and Herzegovina, Western nations had imposed a no-fly zone to protect civilians from air attacks, and debates were taking place in the United States, France, and the United Kingdom, as well as in the U.N., over whether to do the same in Libya. The day after Al Uqaylah fell, Secretary of State Hillary Clinton arrived in Paris to meet with Nicolas Sarkozy, who was among the most vocal proponents of an intervention. Clinton, too, had argued in favor of a no-fly zone, despite protests from the Department of Defense. But in France she stopped short of endorsing military action, and a consensus seemed far off.

As the debate continued, Qaddafi’s forces moved along the coastal road toward Brega. The checkpoint outside town was a paltry thing, with just a few anti-aircraft guns, a lot of trash, and a small throng of worried-looking young rebels. On March 13th, Qaddafi’s men blew through it, with jet fighters dropping bombs and then laying down fire to clear the path. Within hours, the city had fallen, and the rebel force had been pushed back to Ajdabiya, the next town on the road to Benghazi. The week before, the rebels had had a theatrical swagger; dressed up like warriors and carrying ransacked arms, they gathered to shout and sing and fire their weapons into the air. Now they were sullen. Some were clearly irritated by the sight of Westerners, and yelled at reporters and photographers to “go away.” No fighter likes to be observed when he is losing.

It had dawned on the rebels that they were incapable of fighting Qaddafi by themselves; in less than a week, many had gone from disavowing any “foreign intervention” to begging for it. Despairing fighters came up to me and asked, “Where’s France? Where’s Obama?” In the United States and Europe, the debate hinged partly on the question of whether the rebellion would be coöpted by radical Islam. Qaddafi had long nurtured a mixture of anti-imperialist nationalism and Islamist xenophobia, and there was a certain amount of lingering anti-Americanism in the air, but without the visceral hatred that I have encountered in Pakistan and Afghanistan. One common myth held that Qaddafi himself was an Israeli agent, part of a conspiracy backed by the West. Graffiti around the Benghazi courthouse read “Qaddafi = Yahud.” I was told repeatedly that an Israeli woman had claimed on television that she was a cousin of Qaddafi; the footage had been rebroadcast on one of the Arabic satellite news channels, and “everyone” had seen it.

A brigade of former jihadi fighters—tough-looking, full-bearded older men—had come to the front from the eastern city of Derna. Their leader, Abdel Hakim al-Hasidi, had fought alongside Osama bin Laden’s Al Qaeda volunteers in Afghanistan, and some of his fighters were jihadi veterans of the war in Iraq. Another top commander, Abu Sufian bin Qumu, is a former Guantánamo detainee who also fought in Afghanistan.

When I raised the prospect of extremism with the secular, educated leaders of the Benghazi revolutionary council, they initially dismissed it as a vestige of Libya’s long isolation. But, when pressed, they acknowledged fears that, if the West didn’t come to their aid soon, radical Islamists could exploit the fragile situation. During one of the mass prayer sessions that were conducted every Friday outside the courthouse, I sat in an upstairs room with a Benghazi council member named Mustafa Gheriani, an amiable Libyan-American businessman in his fifties; his brother and his sister-in-law were also members of the council. We looked out of a window at the thousands of men and women gathered there, praying. Gheriani mused, “Will it be a democracy here, or will it be like what happened in Iran after the Green Movement rose up? The West didn’t open its arms and embrace them, and it’s been squelched. When there is education and prosperity, religion takes a secondary role, but when people are suppressed God comes to the forefront. And that’s dangerous.”

With Qaddafi’s soldiers closing on Ajdabiya, the town’s hospital was the place to go for news. When I arrived, on March 13th, I spotted Osama, standing next to the emergency entrance in a group of young fighters who wore grave expressions. Looking me in the eyes, he said, “Muhannad is dead.” Deep, soundless sobs wracked his body.

The previous day, Muhannad had showed up in Brega and spent the afternoon at the clinic. At around five o’clock, he and a pair of comrades headed off in the direction of Al Uqaylah. When Osama cautioned him, Muhannad reassured him that he’d be all right. Osama stayed the night in Brega but had to flee early that morning, when the bombing began. Muhannad did not come back.

A few hours before I arrived, fighters returning from the front had brought word that Muhannad had been shot. They told Osama that he had been in one of two vehicles that went toward Al Uqaylah, looking for the enemy. At twilight, some of the fighters decided that the venture was too risky, but Muhannad and two companions pushed on. In Bishr, near Al Uqaylah, they ran into an advance column of Qaddafi soldiers, who raced their battlewagons toward them, shooting as they came. One of Muhannad’s companions, a young man named Riad, had survived by running off into the desert; he had not returned to Ajdabiya, but he had told his story to the other fighters. Muhannad’s partner was gunned down nearby, he said, and then the Qaddafi soldiers shot Muhannad as he ran away. He saw the men hurling Muhannad’s body into their pickup, and he heard his friend scream.

At the hospital, several young men stood within earshot, looking shocked and grief-stricken. For the time being, Osama said, he would stay there, waiting for the body, which he hoped would be retrieved—even though Bishr was now in Qaddafi territory. If Muhannad’s body came in, he would take it to his brother’s house in Benghazi and mourn for three days, in the Libyan tradition. Then he would return to the front. “I am not going to let Muhannad’s death be in vain,” he said. “I’m not going back to America until this is over. I don’t care about anything anymore.”