The most senior US military officer says Iraq's defence forces will need outside help to regain territory lost to Sunni militants.

General Martin Dempsey, chairman of the US Joint Chiefs of Staff, said US advisers now conducting an assessment of Iraqi forces were reporting the military was "capable of defending Baghdad" but it "would be challenged to go on the offense, mostly logistically challenged".

"If you're asking me will the Iraqis at some point be able to go back on the offensive, to recapture the part of Iraq that they've lost, I think that's a really broad campaign quality question," General Dempsey told reporters at the Pentagon.

"Probably not by themselves."

US forces have six assessment teams on the ground in Iraq aiming to evaluate Iraq's capabilities and determine how US forces can best help the government repel extremists that have seized large parts of the country.

Iraq is grappling with an onslaught of Sunni Muslim militants from the Islamic State in Iraq and Syria (ISIS), which has now changed its named to Islamic State.

The militants have seized large areas of northern and western Iraq and are threatening to march on the capital Baghdad.

Explained: What is the Islamic State?

Their advance has been so successful, in part, because forces under Shiite prime minister Nouri al-Maliki failed to assert their positions last month.

The United States, which focused much of its effort following its 2003 invasion of Iraq building up Iraq's security forces, is now seeking to help the Iraqi military repel those militants.

At the same time the Obama administration does not want to get bogged down in another war in Iraq, especially with political bickering continuing in Baghdad as officials try to form a new government following an April election.

Both General Dempsey and US defence secretary Chuck Hagel urged Iraqi leaders to form a unity government.

"Unless the Iraqi government gets the message out that it really does intend to allow participation by all groups, everything we're talking about makes no difference," General Dempsey said.

Mr Hagel said US forces had established a second US-Iraq Joint Operations Center in Iraq. The new centre, in Erbil, the capital of the semi-autonomous northern region, will complement work done by the first centre in Baghdad.

US president Barack Obama has ruled out returning troops to Iraq but has said the US might conduct air strikes on ISIS targets. General Dempsey also appeared to open the door to more direct action by US soldiers against ISIS.

"If the assessment comes back and reveals that it would be beneficial to this effort and to our national security interests to put [US] advisers [now in Iraq] in a different role, I will first consult with the secretary," he said.

"We will consult with the president. We'll provide that option and we'll move ahead."

Iraq risks 'Syria-like chaos': United Nations

Meanwhile, the United Nations has warned Iraq risks descending into "Syria-like chaos" if its political class fails to unite and agree on a government.

The UN envoy to Baghdad, Nickolay Mladenov, urged Iraq's leaders to press on with a political process that involves selecting a parliament speaker, a president and finally a prime minister, but admitted that tensions were worse than during the peak of the country's all-out sectarian war in 2006.

"If Iraq does not follow its constitutional political process, what is the alternative?" Mr Mladenov told AFP.

"It risks descending into a Syria-like chaos. And that is what people really need to understand, very, very quickly."

Iraq will never be the same as before Mosul. There is no way that this country can go back.

United Nations Baghdad envoy Nickolay Mladenov

The Bulgarian former foreign and defence minister said that if Iraq's leaders did not stick to established political processes, they were in "uncharted territories".

ISIS militants overran the main northern city of Mosul on June 10, and then took control of several other towns and cities as the Iraqi security forces wilted.

Soldiers and policemen have since performed more capably, albeit with mixed results on offensive operations.

"Iraq will never be the same as before Mosul," Mr Mladenov said.

"There is no way that this country can go back."

Addressing the country's politicians, he said: "The writing is on the wall, so put your differences aside, your personal ambitions. There will be a time to deal with those later. Now is the time in which you need to figure out how to save the country."

The UN envoy's comments came just days after a farcical opening session of parliament following April elections, which included lawmakers threatening each other, several walk-outs and confusion over key constitutional rules.

The session ended in disarray without MPs selecting a parliament speaker. A new meeting is scheduled for July 8.