Kurdish security forces take part in an intensive security deployment after clashes with Islamic State militants in Jalawla Thomson Reuters

JALAWLA, Iraq (Reuters) - The blood of two militants killed during Islamic State's rout in the Iraqi town of Jalawla has yet to be washed away, but a turf war is already brewing between Kurdish and Shi'ite forces that jointly drove the insurgents out.

The recapture of disputed territory and towns such as Jalawla is reopening rivalries over the boundary between areas of Kurdish control and those administered by the Shi'ite-led Baghdad government.

Local Sunni Arabs displaced in the fighting have little choice but to align themselves with one side or the other.

Not long after Islamic State began its offensive across Iraq this summer, Kurdish commanders in the eastern province of Diyala invited the head of the largest Sunni Arab tribe in Jalawla to discuss jointly resisting the insurgents.

"We sat with them here in this very building," said Brigadier General Barzan Ali Shawas, describing the meeting with Sheikh Faisal al-Karwi in a Kurdish peshmerga barracks on the banks of the Diyala river, lined with date palms.

"We said: What do you want? True, you are Arabs and we are Kurds, but the unity of Iraq is in our interest." The sheikh had replied he would consider the Kurds' offer to set up a unit for local Sunnis under peshmerga command, but he never came back with an answer.

Since that June day, Jalawla changed hands several times, until the peshmerga and Shi'ite militia drove the militants out on Nov. 23. According to Shawas, they agreed before the offensive that the Shi'ite militia would withdraw as soon as it was over and hand full control to the Kurds, but that has yet to happen.

Jalawla, which lies about 150 km (90 miles) northeast of Baghdad, is overwhelmingly Arab and was under the central government's jurisdiction until Islamic State overran it. However, the Kurds say it was theirs until the 1970s, when Saddam Hussein brought in Sheikh Faisal's Karwiya tribe to "Arabise" the area.

Now it is deserted except for stray animals, Shi'ite militiamen and peshmerga, marking their territory with flags and graffiti. The atmosphere is tense.

"Jalawla is Kurdistani," is spray-painted on the front of a bakery. Fridges dragged into the road as barricades are beginning to rust.

Shi'ite fighters drive a pick-up truck with a picture of Iran's Supreme Leader Ayatollah Ali Khamenei on the bonnet. One gets out and approaches the Kurds, finger on the trigger of his rifle, to ask if they have permission to be there from the head of the Shi'ite Khorasani Brigades militia.

"If they retain a fanatic stance about the areas they have taken, there's no way we will allow them," said Jawad al-Hosnawi, the Khorasani Brigades' field commander.

Iraqi Kurds have controlled an autonomous region since the early 1990s and their fighters moved into other disputed areas this year to combat Islamic State.

But Hosnawi rejects any further Kurdish ambitions. "Our problem is if they want to separate from Iraq or form an ethnic state - no way," he said.

RESIDENTS FEAR MILITIAS

Cats pick through uncollected rubbish in Jalawla and a cow strolls down the street, oblivious to the danger of thousands of mines planted by the militants. A burst of gunfire and the occasional thud of an explosion can be heard.

Shawas promised civilians would be allowed to return, except those who sided with Islamic State, once a bomb disposal team finishes its work, and water and electricity are restored.

Hosnawi said the Kurds were bulldozing Sunni homes to discourage them from coming back.

Many Jalawla residents are camping a few kilometers away on a football pitch, its perimeter fence draped with laundry. They celebrated the news that Islamic State had been forced from Jalawla and the adjacent town of Saadiya.

Most said they had fled not the militants, but air strikes targeting them. Now they fear the Shi'ite forces, who have killed Sunnis and destroyed their homes in other towns they recaptured from Islamic States.

"We want to go back but the militias will slaughter us," said a 40-year-old farmer from Saadiya who was too afraid to give his name. "We ask the peshmerga to annex Jalawla and Saadiya to the (Kurdistan) region so we can live in peace."

To slow enemy advances, Islamic State blew up bridges across the milky waters of the Diyala river, into which some militants flung themselves to escape when the game was up.

The blood of two insurgents who did not get away stains the entrance to a shop that used to sell roofing. Its shutters are down now and daubed with Shi'ite slogans.

Sheikh Faisal confirmed rejecting the Kurds’ proposal, and says his tribe had fought the peshmerga to prevent them taking over a base abandoned by the Iraqi army.

"They won't let Arabs return, mostly the Karwiya. They want to take Jalawla. It's an Arab area," he said by telephone from the nearby town of Baquba.

He denies collaborating with Islamic State, as the Kurds allege, and says the militants blew up his house in Jalawla because he refused to join them.

Unlike the displaced residents, Sheikh Faisal's nephew Zumhar Jamal al-Karwi said Jalawla should remain under the Baghdad government, not the Kurds.

"We won't accept Jalawla remaining in Kurdish clutches. If they cling to it by force, it will be retaken by force," Zumhar said. "We are prepared to fight against the Kurds alongside the militias unless the peshmerga leave Jalawla."

(editing by David Stamp)