Iraqi Kurdish security forces patrol a street in the city of Kirkuk.
Photograph: Ako Rasheed/Reuters

Islamic State fighters fought government forces in the city of Kirkuk for a second day on Saturday, defying repeated government claims to have secured the city, and drawing troops and focus from the frontline of the fight for Mosul.

A fire set by Isis at a sulphur plant near Mosul also sent toxic fumes across the battlefield as US forces distributed 24,000 gas masks to allies, reflecting worries Isis could use chemical warfare.

A broad coalition of tens of thousands of troops has gathered to retake the last major urban centre Isis holds in Iraq. For a week they have been advancing from Mosul’s south and east, in the opening moves of the biggest battle the country has seen since the 2003 invasion.

They are facing a much smaller enemy, with about 6,000 Isis fighters thought to be holed up in Mosul. But the attack in Kirkuk, more than 60 miles from the frontline, has proved a grim reminder of the group’s capacity to spread death and destruction far beyond territory they control, even when under pressure elsewhere.

“We were told yesterday that the situation in Kirkuk is serious and so we left the frontline in Khazer [east of Mosul] and went back to Kirkuk,” said a Kurdish peshmerga who asked not to be named. “Around 500 peshmerga came back from Khazer and no one came to replace us before we left.”

That attack comes after several days of strong resistance in newly liberated areas, and together they are fuelling fears of a longer and more vicious campaign than some had hoped after the rapid early advance.

“My views about Mosul have changed after what I saw in Kirkuk,” said Karwan Hama Tata, a Kurdish fighter wounded in the fighting on Friday.

“These militants [in Kirkuk] were not familiar with the layout of the city and only held two hotels and a few other buildings, and it still took us two days to finish them off. They are familiar with Mosul, they have dug tunnels and made preparations for over two years. Many will die in the city.”

Soldiers pushing towards Mosul have moved into Christian villages to the east of the city. They raised the Iraqi flag over the government compound in Hamdaniya the day after celebrating the liberation of nearby Bartella by ringing the church bells, which had been silent for more than two years.

About 50 villages have been taken so far, according to the Iraqi army’s media office, but Isis have pushed back hard, attacking convoys with suicide bombers in cars and trucks, and apparently using extensive tunnel networks to ambush fighters from areas they thought had been cleared.

Isis kills dozens and seizes hostages in counter-attack on Kirkuk

Read more

Thousands of homemade bombs scattered through roads and buildings have already added to a death toll that includes two journalists. And as troops edge towards Mosul they must prepare for urban warfare with experienced and well-entrenched fighters who have spent two years gearing up for this battle.

The intensity of fighting in Kirkuk, which dragged on for more than two days, gives some indication of how bloody the Mosul showdown could be. Security sources say the bodies of more than 50 Isis fighters have been recovered, but the death toll among Iraqi and Kurdish security forces and civilians is near 100. No official figures have yet been released.

The attack began in the early hours of Friday morning, after Isis vehicles dropped about 100 militants armed with heavy and light weapons around several city neighbourhoods, where they took up positions in high buildings and strategic areas, sources said.

“There is negligence from all the security forces inside Kirkuk. How is it that over 100 militants take up positions across the city and no one saw this coming?” said a senior source involved in the operation against Isis militants.

The head of security at the provincial council, Azad Jabari, said he believed some of the fighters had slipped into the city disguised as refugees at one of several camps for people fleeing fighting – a concern raised months before the Mosul offensive began.

“We will increase screening further at those points where [refugees] arrive from Daesh-held areas,” Jabari said, using the Arabic acronym for Isis. Security forces have already detained some men of fighting age among refugees, but with hundreds of thousands of civilians expected to flee the fighting in coming weeks, there are doubts that any more than the most basic checks on new arrivals will be feasible.