Ground forces backed by helicopter gunships launched a three-pronged pre-dawn attack on the militant stronghold of Tikrit on Saturday, marking a major test for the Iraqi military as it attempts to gain the upper hand against insurgents.

But the offensive appeared to be faltering as night fell. Residents and a local tribal leader said militants from an al-Qaeda breakaway group had repelled the troops’ advance, rigging roads into the city with explosives. In contrast to those claims, state television said security forces had cleared the town center of militants.

The recapture of Tikrit, about 90 miles north of Baghdad and the home town of ousted president Saddam Hussein, would give a boost to Prime Minister Nouri al-Maliki as he struggles to hold on to power in the face of a nearly three-week offensive by extremist fighters from the Islamic State of Iraq and Syria (ISIS). But a high-profile failure would deliver a deep blow to already disheartened forces.

Iraqi military officers have taken pains to stress that the initiative is now in their hands, following an extensive land grab by an insurgency that has boasted of mass executions in Tikrit. Police took journalists, accompanied by armed escorts, to the perimeters of western Baghdad on Saturday to show that the capital is fully under their control.

“The animals are eating the corpses of ISIS,” Brig. Resan al-Brahimi, a federal police commander, told the assembled journalists. “The balance has shifted.”

Elite counterterrorism forces were also air-dropped into the nearby town of Siniyah and the oil refinery at Baiji in the days before the Tikrit offensive, according to Ammar Toma, a member of parliament’s defense and security committee. The newfound confidence has led to speculation that recently arrived U.S. advisers had helped plan the operations.

“There has certainly been a positive development in the conduct of the security forces, particularly the elite forces,” Toma said. “This has all happened after the arrival of U.S. consultants. Now it’s a case of wait and see.”

But the success of the new offensives is yet to be proved, and it is unclear whether Iraqi army forces — which have made up for mass desertions with rapid training of new recruits — will be able to hold retaken ground in areas where anti-government sentiment runs high.

At Baiji, counterterrorism forces appeared to have weathered the desertion of hundreds of Iraqi soldiers Monday night and regained control of the refinery, according to a senior North Oil Co. official, although militants still control the surrounding area, rendering the facility unusable. Security officials, meanwhile, said that the Mansuriya gas field, which militants attacked Friday, had been secured by special forces.

The Tikrit operation, which began when counterterrorism forces in four helicopters were air-dropped Thursday onto a university campus on the city’s northern outskirts, appeared to run into difficulties from the outset. One helicopter was shot down and another suffered mechanical failure, residents said.

Since then, however, special forces have set up at the nearby al-Sahra air base, the former Speicher U.S. military base, according to a tribal leader from Tikrit who spoke on the condition of anonymity for security reasons. He claimed that the crew of one of the helicopters — a Lebanese national and “two or three” Iraqis — had been taken hostage by ISIS.

With their special forces in place to the northwest, Iraqi troops launched an offensive from three directions — the main Baghdad highway to the south, a road from Samarra to the southeast and the Irbil road to the northwest — early Saturday, according to a version of events laid out by the tribal leader and three other local residents contacted by phone.

How the Islamic State is carving out a new country

The troops were backed by helicopter gunships, but the roads were heavily booby-trapped and security forces were prevented from entering the city, residents said. The government forces then began bombarding the city by air in the afternoon, trying to break a siege against its men at the university and al-Sahra, they said.

According to the tribal leader, the city remains under the control of ISIS, along with Baathists and members of the Naqshbandi Army, Ansar al-Sunna and Ansar al-Islam, insurgent groups that formerly battled U.S. troops. ISIS members are a minority but the main fighting force, he said.

In contrast, military spokesman Lt. Gen. Qassim Atta said that ISIS was retreating and that an ISIS commander was among 29 insurgents killed in the assault.

Most residents have fled Tikrit, which has suffered three days of bombardment. Several who remained claimed government forces have used barrel bombs — explosives-packed drums that are notorious for causing high numbers of civilian casualties due to their inaccuracy.

It is not the first time Iraqi forces have been accused of dropping the makeshift munitions, a well-known tactic of Syrian President Bashar al-Assad as he battles rebels across the border. New York-based Human Rights Watch last month accused the Iraqi government of using barrel bombs in Fallujah, in the western province of Anbar, where insurgents have continued to make gains.

On the media tour Saturday, Brahimi, the police commander, stopped near the border of Abu Ghraib, the city’s western gateway from Anbar. “The enemies say they are on the outskirts of Baghdad,” he declared. “Where are they?”

But Jabbar Abed, a 31-year-old carpenter who lives in Abu Ghraib, said the answer was: “Not far.”

“It’s a very bad situation,” he said. “Every one is scared they will take control. Every day there are clashes.”

Ben Van Heuvelen in Irbil and Abigail Hauslohner in Beirut contributed to this report.