Five U.S. soldiers were killed in two separate attacks in Iraq, the military announced on Friday.

An explosion near a military vehicle in Diyala Province on Friday killed three Task Force Lightning soldiers, the military said. In another incident, two U.S. soldiers were killed and nine wounded while conducting operations in southern Baghdad on Thursday.

In Baqouba, a city just north of Baghdad, about 50 suspected insurgents attacked a U.S. base Friday, sparking a battle with U.S. soldiers and helicopters that left at least six militants dead, the Iraqi army said.

The fighting took place in Baqouba, a Sunni insurgent stronghold that has seen a recent spike in violence largely blamed on militants who fled a three-month-old security crackdown in Baghdad.

Meanwhile, the massive search for three missing U.S. soldiers believed to have been kidnapped by Al Qaeda-linked insurgents entered its seventh day.

Col. Michael Kershaw, the commander of the 2nd Brigade Combat Team, 10th Mountain Division, who was overseeing the mission, said the teams were talking to locals, hoping to find information that would lead them to the soldiers.

"Everyone is motivated and knows the importance of finding the soldiers," he said in a statement from Quarghuli, a village 12 miles south of Baghdad where a May 12 ambush killed four U.S. soldiers and an Iraqi, and left three American troops missing.

The fighting in Baqouba began about 7 a.m. Friday, the day of rest in Muslim Iraq, when insurgents opened fire on a U.S.-Iraqi base in the center of the city, about 35 miles northeast of Baghdad.

About a half-hour later, U.S. reinforcements arrived, killing at least six insurgents, the Iraqi army officer said. He spoke on condition of anonymity because he is not authorized to speak to the media.

Residents said the fighting sent smoke billowing up from neighborhoods in the area.

One resident, who spoke on condition of anonymity for fear of reprisals from militants, said he heard heavy machine gun fire and then men shouting "Allahu akbar," or "God is great" in Arabic. Others said they saw U.S. armored vehicles driving through the street, while aircraft flew overhead.

The fighting ended about noon, but several hours later, suspected insurgents fired a mortar round at a nearby police headquarters, the army officer said. No casualties were reported.

The U.S. military had no immediate comment on the fighting.

The base was set up two months ago in a three-story city office building that was abandoned because of the violence in the area, the Iraqi officer said.

Complete coverage is available in FOXNews.com's Iraq Center.

About 4,000 U.S. soldiers and 2,000 Iraqis have been involved in the search for the three missing American troops, who were captured in an attack last weekend that left four Americans and one Iraqi dead.

The soldiers had been at an observation post for several hours when an insurgent force crept through the foliage, cut concertina wire and attacked from all sides with automatic weapons, said Maj. Webster Wright, a U.S. military spokesman.

Attackers apparently planned to capture soldiers because there were signs that a getaway car was used, he said.

On Thursday, U.S. officials expressed cautious optimism that the missing soldiers were still alive even as troops drained canals and questioned children in the search. FBI agents and Australian forensic experts also took part.

About 900 people had been questioned so far and 36 were detained, Webster said. U.S. forces also dropped 250,000 leaflets over the area.

Lt. Col. Randy Martin, another U.S. military spokesman, said searches had produced a number of leads that "point to the fact that these men are still alive."

"There are also reports to the contrary. But we have an obligation to follow on every intelligence tip," Martin said. "There is cautious optimism that in fact these soldiers can be found alive. That's what we pray for, that's what we hope for."

The U.S. military also said it detained six suspected insurgents Friday during raids in northeast Iraq. It accused them of being members of a cell that imports powerful weapons from neighboring Iran, and brings Iraqis to Iran for training as insurgents.

On May 28, talks between U.S. and Iranian officials are to begin in Baghdad to discuss the security situation in Iraq. Washington has often accused Iran of arming insurgents and militias.

Elsewhere Friday:

— A 24-hour curfew remained in place in Mosul, 225 miles northwest of Baghdad, for a third day. It was imposed after insurgents used five suicide vehicle bombs, mortars and small arms fire to destroy two bridges and attack a police station and a jail where suspected insurgents were being held. The attacks killed 15 insurgents, 10 Iraqi policemen, one Iraqi soldier and one civilian. About 47 people were wounded, the U.S. military said.

— A suicide car bomber hit a police patrol in the Sunni-dominated town of Jurf al-Sakhar, 40 miles south of Baghdad, killing three officers and wounding two, police said.

— In the oil-rich city of Kirkuk, 180 miles north of the Iraqi capital, drive-by shooters killed an Iraqi army officer as he was heading to work, police said.