Donald Trump has been accused by a leading Democratic presidential candidate of losing control of US foreign policy as the country lurches towards conflict with Iran – despite both sides saying they don’t want war.

Pete Buttigieg, a former Navy officer who served in Afghanistan, also rounded on the US president for appointing John Bolton as his administration's national security adviser.

"Look, Iran is a problematic actor, there is no question about that,” Mr Buttigieg told The National at a campaign rally in Exeter, New Hampshire. “What we are seeing right now is a set of escalations, which could very quickly get away from this president.”

The mayor of South Bend, Indiana has electrified the early stages of the Democratic race. He voiced his concerns as Mr Trump announced an increased US military presence in the region with the deployment of an aircraft carrier, 1,500 extra troops, additional Patriot missile defence systems and B-52 bombers.

"I am very worried because we have stepped towards confrontation with Iran which almost makes it seem as if we have learned nothing from the experience with Iraq," he added.

"He's not even in control of the dynamics, just as he has lost control of relationships when it comes to trade.”

Mr Bolton, an unapologetic foreign policy hawk, has made little secret of his desire for regime change in Iran, taking a tougher line than Mr Trump himself. Mr Buttigieg said Mr Bolton’s role in the build-up to the Iraq war in 2003 is of particular concern. The then US Department of State under-secretary for arms control helped compile the intelligence case that Saddam Hussein possessed weapons of mass destruction that turned out to be wrong.

"I am particularly troubled to see one of the primary architects of the disastrous Iraq war driving a lot of the policy on that and it raises the question why a president who says he was against the Iraq war all along would pick one of its architects as his national security adviser."

During the 2016 election campaign, Mr Trump was fiercely critical of the Bush administration for going to war with Iraq.

It made his decision in April to appoint Mr Bolton, in succession to the more measured retired general H.R McMaster, something of a surprise.

In recent weeks, the US president seems to have sought to distance himself from Mr Bolton, trying to dampen fears that the country was heading towards war with Iran.

Not many of those jostling to be the Democratic presidential candidate have thus far highlighted foreign policy as a campaign issue.

Significantly, those who have spoken out are also military veterans. Tulsi Gabbard, a contentious Hawaii congresswoman who served in Iraq and Kuwait, said a war with Iran would be devastating.

"I know where this path leads us and I'm concerned because the American people don't seem to be prepared for how devastating and costly such a war would be," she said on Fox News last week.

Ms Gabbard has caused controversy with her foreign policy stances, especially on Syria having met President Bashar Al Assad in 2017 and praised Russian intervention that is believed to have killed thousands of civilians.

Seth Moulton, a Massachusetts congressman and recent entrant to the race, has been scathing about Mr Bolton and his allies.

"I fought Iranians in Najaf," he said of the important Shiite southern Iraqi city.

"We won. I'd fight them again if necessary. But this is not necessary. This is chicken hawks trying to drag us into a war with Iran just like they did 15 years ago in Iraq. This is why we need to make national security front and centre at the Democratic debates."