STUTTGART, Germany (Reuters) - U.S. Defense Secretary Ash Carter said on Wednesday that Washington and its allies had agreed to do more in their campaign to defeat Islamic State but that more risks lay ahead.

Iraqi security forces stand with an Islamic State flag which they pulled down in the town of Hit in Anbar province, April 2, 2016. REUTERS/Stringer

Carter made the comment following talks in Germany with defense ministers and representatives from 11 other nations participating in the alliance.

He said the United States greatly regretted the death of a Navy SEAL in an attack by the jihadist group in northern Iraq on Tuesday. He named the man as Petty Officer First Class Charles Keating.

“These risks will continue ... but allowing ISIL safe haven would carry greater risk for us all,” he added, using an acronym for Islamic State.

“We also agreed that all of our friends and allies across the counter-ISIL coalition can and must do more as well, both to confront ISIL in Iraq and Syria and its metastases elsewhere.”

The talks included ministers from France, Britain and Germany and were planned well in advance of Tuesday’s attack, in which Islamic State fighters blasted through Kurdish defenses and overran a town.

The elite serviceman was the third American to be killed in direct combat since the U.S.-led coalition launched a campaign in 2014 to “degrade and destroy” Islamic State, and is a measure of its deepening involvement in the conflict.

Slideshow ( 7 images )

Offering new details about Keating’s mission, Carter said the SEAL’s job was to operate with Iraqi Kurdish peshmerga forces to train and assist them north of the city of Mosul.

“That part of the peshmerga front came under attack ... and they found themselves in a firefight,” Carter said.

In mid-April, the United States announced plans to send an additional 200 troops to Iraq and put them closer to the front lines of battle to advise Iraqi forces.

In late April, President Barack Obama announced he would send an additional 250 special operations forces to Syria, greatly expanding the U.S. presence on the ground there to help draw in more Syrian fighters to combat Islamic State.

‘GOING TO TAKE A LONG TIME’

Norwegian Defence Minister Ine Eriksen Soereide told Reuters that the ministers discussed ways to escalate the military fight against Islamic State and deal with concurrent humanitarian crises but that it was clear more hard work remained.

“There is no doubt Islamic State is under pressure ... but one has to be realistic,” she said in a telephone interview. “This is difficult, this is complex. It’s going to take a long time.”

Soereide said Norway’s decision this week to send 60 troops, including special forces soldiers, to support Syrian fighters, was made possible partly by the more structured plan for coordinating the fight against Islamic State that had emerged in recent months.

The Islamist militants have been broadly retreating since December, when the Iraqi army recaptured Ramadi, the largest city in the western region. Last month, the Iraqi army retook the nearby region of Hit, pushing the militants farther north along the Euphrates valley.

But U.S. officials acknowledge the military gains are not enough.

Iraq is beset by political infighting, corruption, a growing fiscal crisis and the Shi’ite Muslim-led government’s fitful efforts to seek reconciliation with aggrieved minority Sunnis, the bedrock of Islamic State support.