Libyan Coast Guard officers patrol the sea off the city of Zuwarah, one of the main departure points in Libya for migrants trying to reach southern Europe. (Lorenzo Tugnoli/The Washington Post).

We sped through the Mediterranean in the Libyan coast guard’s tiny gray skiff, rocked by the small swells that marked the end of summer.

It was another morning patrol in the longtime smuggling capital of North Africa. The six officers on board stared at the horizon looking for something that resembled a migrant boat. Behind them, the coastline was littered with the remains of vessels that had capsized, and the clothes of people who had drowned.

At the wheel, the commander of the unit, Lt. Col. Assam Tor, was the only one who spoke.

"Even the migrants have bigger boats," he said, shaking his head as a wave crested over the brim, his men looking on blankly, lacking the equipment and the will to do much at all.

This year, I traveled to Gambia, Niger and Libya to document the historic flow of migrants from Sub-Saharan Africa to Europe. While the world’s attention has been mostly on Syrian refugees, about 100,000 men and women from across Africa have fled their homes as well, taking a much deadlier route through the Mediterranean.

European attempts to stop them have all failed. Not only are the migrants and refugees desperate and determined, but they are slipping through a corridor of failed or failing states. Law enforcement agencies are either indifferent to, or complicit in, the smuggling trade. Leaders do little to entice their citizens to stay. At the highest levels, the mass exodus is seen as Europe’s problem rather than Africa’s.

In Gambia, I watched as village after village was emptied of young men departing for Europe, unconvinced by an authoritarian government’s feeble campaign to boost agriculture jobs. In Agadez, Niger, the economy was so bad that the smuggling industry had become the only significant source of income. The police and military took large sums of money to let the migrants pass after first searching their pockets for anything worth stealing.

The United States and Europe tried to keep people from migrating in sometimes hilariously misguided ways, like an anti-migration themed concert in Gambia. But the countries on the migrant route didn’t care to stem the tide of people looking for something better. And why should they?

In Libya, the overthrow of Moammar Gadaffi had created a massive business opportunity for both freelance smugglers and the government officials that enabled them. The regime’s once brutally effective anti-migration apparatus had collapsed. Now, the coast was patrolled by tiny skiffs, like the one I was on, when it was patrolled at all.

Tor remembers when his unit had six 90-foot boats and smuggling was almost non-existent. Back then, Gadaffi had come to a lucrative agreement with Italy that he would stop migration in exchange for millions of dollars in often diverted aid. It worked, but many questioned the logic of bankrolling a military dictator to patrol his borders.

By 2012, those Coast Guard boats were gone, destroyed by NATO airstrikes during the war between pro- and anti-Gaddafi factions. Libyan officials here said they had asked the Europeans for replacements, but without any luck.

“We met with the Italian ambassador and we told him, ‘We are on the front lines, but we have nothing to keep the migrants from leaving,’” recalled Basem Dahan, a member of Zuwara’s municipal council. “If you want us to stop migration, we need your help.”

The Italians offered no assistance, Dahan said. Because Libya is so fragmented and dangerous, with two rival central governments and scores of militias, delivering aid is virtually impossible.

[A Libyan militia confronts the world's migrant crisis]

The morning I spent with him at sea, Tor looked tired and defeated. Libya was neither the origin nor the destination of the migrants he pursued. But he found himself the de facto leader of an anti-migration mission. It had become easier in recent weeks, due to a crackdown on smugglers in Zuwarah. But he wasn't sure that would last.

And the mission didn’t entirely sit well with him. Not just because he felt outmatched by the smugglers. But because he had lived through enough violence to understand why people would risk everything to leave their homes. The impulse to migrate made more sense to him than the plan to repel migrants.

As the morning patrol wound down, a short and fruitless run, he told his own story of escape.

In 2011, Tor abandoned his post with the military to support the anti-Gaddafi rebels, during the Arab Spring uprisings. But the regime's forces re-took Zuwarah, pounding the city with tank and artillery fire. Tor knew he would be targeted.

He had to get his wife and three daughters to Tunisia, about 40 miles away. He paid a smuggler about $500 a person.

"I know what it's like to flee a war in your country. I understand why these guys are leaving," he said. "As a Coast Guard officer, I know my job. But as a person, I want to let them go to Europe."

As Tor motored his boat back to the harbor, I got a better look at the skeletons of smuggling boats that lined the shore, pieces of painted wood that looked like they had been crushed by an anvil. Some of the passengers had washed ashore and some had disappeared.

After traveling halfway across Africa, they had perished just north of the continent’s furthest reaches, somewhere in international waters.