The soldier was killed and another was wounded when troops stationed at a nearby outpost came under heavy small-arms fire from the Honest Mohammed Mosque late Thursday in Tarmiyah as they targeted about six insurgents who were believed sheltered inside, according to the military.
The U.S. forces then cordoned off the area and, unable to find the mosque's preacher, sent the Sunni mosque's groundskeeper into the building to persuade those inside to come out after they refused calls on loudspeakers, the military said.
"About 20 left the mosque and stated there was no one left in the mosque. This was not true," said Lt. Col. Michael Donnelly, a military spokesman for northern Iraq. He said those 20 had been detained.
Troops spotted gunmen on the roof so a missile was fired at the building, Donnelly said.
A police officer and a witness, who spoke on condition of anonymity because they feared retribution, said U.S. troops stationed near the mosque came under fire before sunset prayers and the raid occurred as worshippers left the building after the services. The missile left a hole in the minaret, they said. The military said the roof of the mosque sustained only minor damage.
Mindful of the sensitivities surrounding places of worship, U.S. forces generally avoid directly raiding mosques in Iraq, instead providing a cordon while allied Iraqi security forces search the buildings. But the military claims Shiite and Sunni militants take advantage of the reluctance to use mosques as hideouts or as storage for weapons caches.
U.S. forces recently have launched a series of offensives aimed at chasing Sunni and Shiite extremists who have fled crackdowns in Baghdad and surrounding areas.
Tarmiyah, a predominantly Sunni town 30 miles north of Baghdad, was the site of a coordinated attack involving a suicide car bombing and gunfire against a U.S. combat post in mid-February. Two soldiers were killed and 17 wounded in that ambush.
South of the capital, a member of the militant arm of Iraq's largest Shiite party was elected governor of Qadasiyah province after his predecessor was killed along with the provincial police chief in an ambush a week ago Saturday.
The new governor, Sheik Hamid al-Khudhari, is the secretary-general of the Badr Brigade, the militant arm of the Supreme Islamic Iraqi Council, a group led by powerful Shiite politician Abdul-Aziz al-Hakim.
The group has been competing with fighters loyal to radical Shiite cleric Muqtada al-Sadr's Mahdi Army militia for dominance in oil-rich southern Iraq as British-led forces who have overseen the region prepare to draw down.
Al-Khudhari was elected by a narrow majority, with 22 of the 40 members of the provincial council voting for him, council member Ghanim Abid Dahash said.
The factional fighting is an example of the complex challenges facing Iraq, from both Shiite militias and Sunni extremists, who often target not just Americans but also their own sects in internal battles.
One of Iraq's most feared insurgent groups, meanwhile, posted a video Friday showing the execution of a Defense Ministry official accused of working with U.S. forces. The video, which could not be independently verified, appeared on an Islamist Web site known for extremist material.
In the tape, Alaa Abboud Fartous Diab said he was a former army officer and employee of the ministry. Unseen kidnappers displayed his identification cards, including a badge giving him access to Baghdad's heavily fortified Green Zone, the site of the Iraqi government and the U.S. Embassy.
In the video, Diab is killed with two pistol shots to the back of the head.
The Ansar al-Sunna group, a sometime ally and rival of Al-Qaida in Iraq, operates mainly in the north of the country and has claimed responsibility for a string of attacks against U.S. troops, foreign civilians and Iraqis it labels "collaborators."
Iraq's divided politicians continued meetings a day after the announcement of a new alliance of Shiite and Kurdish parties that seeks to save the crumbling U.S.-backed government. The reshaped power bloc included no Sunnis and immediately raised questions about its legitimacy as a unifying force.
Prime Minister Nouri al-Maliki hailed the political agreement as a first step toward unblocking the paralysis that has gripped his Shiite-dominated government since it first took power in May 2006. The key disappointment was the absence of Iraq's Sunni Vice President Tariq al-Hashemi and his moderate Iraqi Islamic Party.
The new Shiite-Kurdish coalition will retain a majority in parliament - 181 of the 275 seats - and apparently have a clear path to pass legislation demanded by the Bush administration, including a law on sharing Iraq's oil wealth among Iraqi groups and returning some Saddam Hussein-era officials purged under earlier White House policies.
Teams in northern Iraq, meanwhile, tallied the grim figures from the deadliest wave of suicide attacks of the war and - in a rare moment of joy since Tuesday's devastation - pulled four children alive from the rubble on Thursday.
Interior Ministry spokesman Brig. Gen. Abdul-Karim Khalaf said Thursday that at least 400 were dead - apparently all members of the ancient Yazidi sect that mixes elements of Islam, Christianity and other faiths. Some authorities outside the central government have said at least 500 people died.