BAGHDAD - Police commander Lt. Col. Shamil al-Jabouri knew al Qaeda wanted him dead. He was renowned in the tense northern city of Mosul for his relentless pursuit of the terror group, and insurgents had tried at least five times to kill him for it.

On the sixth attempt, al Qaeda left little to chance.

As al-Jabouri slept yesterday morning on a couch in his office, three men wearing police uniforms over vests laden with explosives slipped through an opening in the blast walls surrounding the compound where his building stood, police said.

Police manning one of at least four observation towers surrounding the compound shot one of the attackers in a yard and his vest exploded. Under the cover of that blast, police said, the other two suicide bombers charged about 100 yards and made it into al-Jabouri's single-story building.

They detonated their vests simultaneously - one at the door of al-Jabouri's office - killing the commander instantly and injuring a policeman sleeping in a trailer nearby. The two blasts brought the whole building down, burying the slain commander under the rubble, police said.

The attack on the commander responsible for hunting al Qaeda in Mosul - a former militant stronghold - was a reminder of the significant gaps in Iraqi security, the challenges the new government will face in trying to close them and the lengths insurgents will go to take out people they perceive as threats.

Just 10 days ago, al-Jabouri led a raid that ended in the death of the top al Qaeda figure in Mosul, his colleagues said. And two months ago he had been instrumental in stopping a gang that had been targeting jewelry stores in the city - robberies that are frequently ways for terror groups to refill their coffers.

"We've lost a sword of Mosul who chased al Qaeda terrorists out of the city," said Abdul-Raheem al-Shemeri, a top security official on the Mosul Provincial Council.

An al Qaeda affiliate, the Islamic State of Iraq, took responsibility in a statement posted on the Internet. It said al-Jabouri had been targeted several times before, but had not been deterred from fighting al Qaeda.

"This day was the decisive one," the group said.

According to the militants' statement, the attackers were dressed in police uniforms, which likely helped them get close to the compound - an abandoned soccer stadium - without raising suspicion.

U.S. Maj. Erik Peterson worked with al-Jabouri as Iraqi police were taking over security from the Iraqi army for the western half of the city, an operation that began last summer.

"He was a legend in the police force," Peterson said. "Every time you would go to visit him, he already had someone new he was looking for or had just arrested."

Peterson said that by killing officials like al-Jabouri, al Qaeda is trying to institute fear in the local population.

Militants had tried to kill al-Jabouri at least five times before, police officials said.