The Iraqi premier sacked three Baghdad security chiefs following a devastating bombing in the capital, his office said on Friday, hours after another attack to the north left 40 dead.
Prime Minister Haider al-Abadi's office also confirmed that he had accepted the interior minister's resignation, which was submitted following the Sunday bombing in Baghdad that killed 292 people.
The Islamic State jihadist group said it carried out the latest attack -- on a Shiite shrine in the town of Balad that began Thursday evening -- as well as the Baghdad blast in Baghdad.
In what was one of the deadliest attacks ever to hit Iraq, a suicide bomber blew up a minibus packed with explosives in a Baghdad shopping district teeming with people ahead of the Eid al-Fitr holiday, sparking widespread anger against the government.
Abadi issued "an order to relieve the Baghdad Operations commander of his position," as well as remove the officials responsible for intelligence and security in the capital, his office said.
The head of the Baghdad Operations Command was Lieutenant General Abdulamir al-Shimmari.
An official in Abadi's office said the others removed were the head of interior ministry intelligence for Baghdad and the official responsible for the capital in the national security adviser's office.
- IS attacks Shiite shrine -
Abadi also accepted Interior Minister Mohammed Ghabban's resignation on Tuesday, the same day it was submitted, his office said.
The announcement confirmed what an official from the premier's office had told AFP on condition of anonymity earlier in the week.
In Thursday evening's attack, militants targeted the Sayyid Mohammed shrine in Balad, 70 kilometres (45 miles) north of Baghdad, Joint Operations Command spokesman Yahya Rasool told AFP.
It killed 40 people and wounded 74, health ministry spokesman Ahmed al-Rudaini said.
The shrine was attacked with mortar fire, then by suicide bombers wearing security force uniforms, Rasool said.
Signup to our newsletter and follow us on Facebook and Twitter!
Security forces fired on the bombers, who were not able to enter the shrine, and two of them blew themselves up, while a third was shot dead, he said.
The attack sparked a fire that caused heavy damage to the market near the shrine, an AFP journalist reported.
IS issued a statement claiming the attack, saying that five jihadists took part, killing guards at the shrine, then clashing with Iraqi forces for hours before detonating explosives they were carrying.
The IS statement did not mention mortar fire.
"It is clear the cowardly attack on the shrine aims to spark sectarian tensions and drag Iraq back to the dark days of sectarian conflict," Jan Kubis, the UN's top Iraq envoy, said in a statement.
- Trapped and burned alive -
On Thursday, Health Minister Adila Hamoud said the bodies of 115 killed in the Baghdad bombing on Sunday had now been handed over to families, while the identities of 177 others had yet to be determined.
Two days earlier, when the full scale of the death toll had yet to emerge, the minister had told AFP that the process of identifying all of the dead was expected to take between 15 and 45 days.
People have been furious over delays in determining the fate of their loved ones, and with the number of unidentified bodies now bigger, it may take even longer.
The attack has overshadowed what would normally be a joyful holiday for Iraqi Muslims.
Police Major General Talib Khalil Rahi said on Thursday that the suicide bomber detonated a minibus loaded with plastic explosives and ammonium nitrate, the first time authorities provided details about the bomb used in the attack.
The initial blast killed a limited number of people, but flames spread and trapped people inside shopping centres that lacked emergency exits, Rahi told a news conference.
In recent months, IS has lost significant parts of the territory north and west of Baghdad which it seized in 2014.
The Sunni extremist group has responded to the battlefield setbacks by hitting back against civilians, particularly Shiites, and experts have warned there may be more bombings as the jihadists continue to lose ground.