Sunni rebels have briefly held parts of Baquba, the provincial capital of Diyala province 60km north of Baghdad, before being repelled by government forces in a battle that left dozens dead.
Three police officers said on Tuesday that the police station in Baquba, which has a small jail, came under attack overnight by the Sunni fighters of Islamic State of Iraq and the Levant, who tried to free the Sunni prisoners, the AP news agency reported.
The officers said Shia gunmen killed the prisoners at close range. A morgue official in Baquba said many of the dead had bullet wounds to the head and chest. All four officials requested anonymity fearing for their safety.
Al Jazeera's Imran Khan, reporting from Baghdad, said at least 63 prisoners were reported killed by the Shia gunmen, according to local sources, but the government released a statement blaming ISIL for the killings in Baquba.
"So clearly there is an information war going on here as well as that battle for Baquba," Khan said.
Meanwhile, Nouri al-Maliki, Iraq's prime minister, fired the country's four top security officers for the fall of another city, Mosul, a government statement said later on Tuesday.
Battle near Kirkuk
Sunni rebels also attacked a northern Iraqi village of Basheer, 15km south of Kirkuk city, inhabited by Shia ethnic Turkmens, police said on Tuesday.
The fighters, using mortar and machineguns, were beaten back from Basheer after an hour of clashes with local gunmen and police forces assisted by forces from a nearby Iraqi Kurdish semi-autonomous region, police said.
A senior Kurdish police brigadier was wounded and six of his bodyguards were killed in the clashes, police said.
Meanwhile, the gunmen loyal to the rebel Free Syrian Army and al-Qaeda-linked Nusra Front took control of al-Qaim, the Iraqi side of a border crossing with Syria, on Tuesday after Iraqi security forces withdrew, police and army officers told the AFP news agency.