A week of unprecedented urban fighting in the wild tribal belt of North Waziristan has left scores dead and forced thousands to flee their homes, raising the stakes in Pakistan's war on Islamic militancy along the Afghan border.

A jumbled alliance of foreign militants, local tribesmen and Islamic students eager for jihad have stepped up resistance in a region where the army already claims to have wiped out Al Qaeda as a viable fighting force.

The unrest, brewing for months, is a setback to the U.S.-led war on terror. Further hampering that effort are deteriorating relations between Pakistan and Afghanistan over Afghan claims that Taliban leader Mullah Omar is hiding in Pakistan and suicide bombers are training here.

U.S. Central Command Chief Gen. John Abizaid visited both countries this week, hoping to patch up the differences and put the alliance against terror back on track. A few days earlier, President Bush made his first trip to the region since the Sept. 11 attacks.

Western diplomats say growing lawlessness in Pakistan's tribal regions could provide more cover for militants launching cross-border attacks into Afghanistan, where increasing violence has fueled fears of a Taliban resurgence four years after the U.S.-led coalition ousted the hardline militia from power.

The situation is a major headache for Pakistan's President Gen. Pervez Musharraf, who has staked much on his campaign to rid the country's semiautonomous tribal regions of foreign militants. His efforts have left him facing sharp criticism at home from those who brand him an American puppet.

Musharraf has deployed 80,000 troops and mounted a series of military operations over three years into Pashtun tribal domains that have resisted outside control for centuries. He says the army has smashed Al Qaeda's bases there and its command structure, but leaders like Usama bin Laden and his deputy, Ayman al-Zawahri, remain on the run.

The Pakistani military leader raised the stakes shortly before Bush's visit, launching an air and ground strike March 1 on a suspected Al Qaeda camp in Saidgi village in North Waziristan. The government claimed the attack killed 45 people, including a Chechen militant leader.

Militants retaliated by seizing government buildings and attacking security forces in the nearby town of Miran Shah. The government said they were led by a radical local cleric, Maulvi Abdul Khaliq, who called for a jihad, or holy war, against Pakistan's army.

The army bombarded militant positions with artillery and helicopter gunships, forcing many of Miran Shah's 50,000 people to flee.

The army says more than 100 militants and eight security forces have died in the fighting since Saturday. In the latest violence, a militant rocket attack Thursday at a nearby town killed two paramilitary soldiers and wounded another.

It is a dangerous escalation in Musharraf's anti-terror campaign, with fighting spilling out of tribal villages and into the region's remote and dusty urban centers for the first time.

Talat Masood, a former Pakistani general and political analyst, said the state has little control in North Waziristan and that it is unclear how the cycle of violence will end. "If Pakistan continues to intensify military operations, it could create more problems than it solves," he said.

Masood said pro-Taliban tribesmen have filled a power vacuum that emerged in the region amid declining law and order, following the assassinations of dozens of pro-government tribal elders by militants. Security officials say that in the past three years, more than 80 elders have been slain in North and South Waziristan.

A Western diplomat noted that although people have been slaughtering each other for centuries in the region, what is unusual is that the tribal structures and leadership have been devalued.

In recent months, radical Muslims have dispensed their own justice against bandits in the region, where drug running and other smuggling and crime are rife. In December, 23 people were reported killed in days of clashes between hundreds of Islamic students in Miran Shah and criminals after students refused to pay money to them at a roadblock.

Students at madrassas, or Islamic schools, are believed to be among the militants now fighting Pakistan's army. Residents say most come from North Waziristan, but hundreds others are from South Waziristan and some from other parts of Pakistan, including Punjab and Sindh provinces.

They often wear shoulder-length hair and beards, marking them as jihadis, or holy warriors. They carry AK-47 rifles, grenades and rocket launchers, and are as young 16 years old, a local intelligence official said on condition of anonymity because he was not authorized to speak to media.

The official said there are also Central Asian and Arab militants who dress like Pakistanis and speak the local Pashtu language.

A second diplomat compared the situation in Waziristan to Afghanistan in the mid-1990s, where the Taliban militia were welcomed by many as saviors from rampant crime and insecurity after years of civil war.

But he doubted Al Qaeda could capitalize on the situation.

"If they set up an identifiable base, it would be targeted pretty quickly. They have to keep running, and they are running."