CHAMAN/QUETTA, Pakistan (Reuters) - Thousands of Pashtun tribal people who for decades ignored the invisible line that bisects their dusty villages and demarcates the Afghanistan-Pakistan frontier are bracing for a Berlin Wall-style divide of their neighborhoods.

Pakistani soldiers keep guard as citizens returning from Afghanistan at the border-crossing town of Chaman, Pakistan, October 5, 2017. Picture taken October 5, 2017. REUTERS/Drazen Jorgic

Pakistan, worried by Islamist attacks, is building a fence to prevent militants criss-crossing the porous 2,500 km (1,500 mile) frontier along the disputed colonial-era Durand line drawn up by the British in 1893.

The fence, which Kabul opposes, will run down the middle of so-called “divided villages” where few people have passports and Pashtun tribal loyalty often trumps allegiance to the state.

Seven such villages are dotted around Chaman district, home to the bustling border-crossing town of Chaman in Pakistan’s southwestern province of Baluchistan. Other divided villages are believed to exist further north in the restive Federally Administered Tribal Areas (FATA).

Pakistani officials in Baluchistan are now working on shifting Pakistani citizens in the divided villages to their side of the fence and say security worries override concerns that it will break up communities.

“(A border wall) was there in Germany, it is in Mexico. It is all over the world – why not in Afghanistan and Pakistan?” said Col. Muhammad Usman, commander of Pakistan’s Frontier Corps paramilitary force in Chaman.

“These tribals have to understand that this is Pakistan and that place is Afghanistan.”

Yet scepticism about the fence abounds. Pakistan’s previous attempts to build one failed about a decade ago and many doubt whether its possible to secure such a lengthy border.

Slideshow ( 4 images )

THE TRUMP EFFECT

The appeal of erecting physical border barriers waned after the Berlin Wall was torn down in 1989. But in recent years, several populist leaders have advocated building walls to curtail movement of foreigners, most notably U.S. President Donald Trump, who wants a wall along the entire border with Mexico.

Hungary’s right-wing Prime Minister Viktor Orban recently fenced the border with Serbia to prevent Syrian refugees and other Muslim migrants from entering the eastern European country that acts as a gateway to the European Union.

Pakistan, in anticipation of the fence, plans to build more than 100 new border posts and Islamabad is recruiting in excess of 30,000 soldiers to man them, according to a senior military source.

“Trump is doing as per requirements of America; we are doing as per requirements of Pakistan,” added Usman.

Tense relations between Afghanistan and Pakistan boiled over in two divided villages in May during Pakistan’s census survey. More than 10 people were killed when Afghan border troops, objecting to the census, clashed with the Frontier Corps in Killi Jahangir and Killi Luqman villages near Chaman.

Kabul and Islamabad accuse each other of sheltering militants and providing safe havens for Islamist groups who carry out cross-border attacks.

Many residents in Killi Jahangir and Killi Luqman welcome the fence in the hope it will prevent bloodshed. But others are concerned it will hurt business and separate them from friends and family.

“There will no infiltration of terrorists or suspects from Afghan areas... but my own small business, which I was doing with Afghan people, will be affected,” said Abdul Jabbar, a Pakistani owner of a small enterprise in Killi Jahangir.

Pakistani officials have long struggled to impose security in the Pashtun tribal heartland. The area stretches for hundreds of kilometers, including rugged mountainous terrain, and has been a hotbed of arms and heroin smuggling for decades. U.S drone strikes have also targeted militants from al Qaeda and other groups in the region.

For the likes of taxi driver Abdul Razzaq, 30, having peace of mind offsets the loss of business due to the fence.

“Now I can sleep in my home without any fear,” he said.