Tunisian army soldiers guard the street near the attacked Imperial Marhaba hotel in Sousse, Tunisia, June 27, 2015.

Tunisian army soldiers guard the street near the attacked Imperial Marhaba hotel in Sousse, Tunisia, June 27, 2015. Darko Vojinovic/AP

Can Tunisia Stop Terrorism With a Wall?

History suggests that building a wall on the Libyan border might not be all that effective.

Governments have tried a vast array of tools to fight terrorism: Mass arrests. Intrusive intelligence-gathering. Buying them off. Aggressive checkpoints. Economic development. Massive force.

How about just building a fence to keep terrorists out though? That’s Tunisia’s plan. The North African nation has been hit by a string of terror attacks. In March 19 people were killed at a museum in the capital, TunisAlmost 40 were killed in June at a beach resort. Tunisian officials have told reporters that Islamist terrorists are being trained in Libya and then coming to Tunisia to conduct attacks, so Tunisia’s prime minister has announced the construction of a 100-mile-long wall along the country’s eastern border.

Will it work? Humans have been building defensive walls practically since the beginning of civilization, so there’s a decent amount of evidence to draw on. And it doesn’t look promising.

First, defensive walls often fail. One of the oldest walled cities known is Jericho, where, as his eponymous book in the Bible relates, Joshua conquered by using trumpets to demolish the fortifications. Whether or not the biblical account is strictly accurate—brass instruments aren’t usually useful as a demolition tool—the story sets a template. The ancient walls of Jerusalem? Little help stopping a succession of conquerors. Constantinople’s magnificent ring of fortifications? Not much defense against invading Ottomans. The world’s most famous defensive line, the Great Wall of China, slowed but failed to prevent the fall of the Ming Dynasty.

The most effective walls tend to share three characteristics. They’re in heavily peopled urban areas, they’re expensive, and they’re short. And as Andrew Schoenholtz, a visiting professor at Georgetown University, told NPR in 2007, they’re often more effective at keeping people in than keeping them out. Take the gold standard of walls: the Berlin Wall. While the full wall was almost 100 miles, the inner-city barrier was only about 26 miles. The wall’s success depended on heavy militarization and the willingness of guards to shoot and kill hundreds of people trying to escape. Even then it was hardly perfect, and while estimates vary, perhaps tens of thousands of people escaped East Germany by various means.

(See also: Why Terrorists Want To See the End of Tunisia)

Some of the most effective security walls right now are in Israel. The better-known one is the barrier around the West Bank. Its morality and legality are hotly debated, but its construction has coincided with a steep drop in terror attacks in Israel. Even more effective has been a fence along Israel’s border with Egypt.That 144-mile-long, 16-foot-tall structure cost $416 million to build. The Israeli government said it has produced an incredible drop-off of more than 99 percent of people crossing the border in the first half of 2013 compared to the same period in 2012, from 9,570 to 34. (Yes, you read that right.) Israel is now adding another fence along its border with Jordan.

In comparison, the U.S. border with Mexico is roughly 2,000 miles long. How effective are the fences along it? It depends on your standard. The construction of some 640 miles of fencing there since 2006 has cost billions of dollars, and in areas where it’s very high, it seems to stop crossings. But illegal crossings had already been on a long slide downward over the last few decades. The tens of billions spent on security—building fences, adding more Border Patrol agents—have made a difference, though immigration hawks still insist the border needs to be closer to impermeable. But achieving zero penetration may simply be impossible with a border that long—short of positioning a heavy force of armed guards stretching the entire length, which would be prohibitively expensive.

One final cautionary historical example for Tunisia is the Maginot Line, the infamous line of defenses that France built between the World Wars on its border with Germany. In 1940, German forces simply cut around it and headed north through Belgium. Tunisia can wall off its border with Libya, and that wall may or may not stop terrorists from crossing that border. But it doesn’t close off alternate routes into the country. Algeria shares a huge border with Libya that’s tough to effectively patrol, although Algeria says its forces are on high alert. Algeria’s border with Tunisia, meanwhile, is also very long, and has been a site of jihadist activity and clashes between fighters and the Tunisian military.

It’s easy to see why beleaguered nations reach for the millennia-old solution of a building a defensive perimeter, but their track record isn’t great. A good barrier may serve a purpose, but it won’t do everything—all in all, it’s just another brick in the wall.