General David Petraeus, who commanded US forces in Iraq and does so now in Afghanistan, argues the two conflicts differ in key respects. But it was plain from Barack Obama's Oval office speech yesterday that, in the president's mind at least, there are some basic similarities. That's a shift from his 2008 campaign when he contrasted Afghanistan, the "necessary war", with Iraq – George Bush's "war of choice".

Announcing an end to combat operations in Iraq, Obama reiterated his determination to end "open-ended war" in Afghanistan too, by beginning a troop drawdown next summer. "As was the case in Iraq, we can't do for Afghans what they must ultimately do for themselves. That's why we're training Afghan security forces and supporting a political resolution," he said.

Obama drew a parallel with Petraeus's successful 2007 Iraq surge – he gave no credit to Bush – and his own decision to send reinforcements to Afghanistan. "I've ordered the deployment of additional troops ... who are fighting to break the Taliban's momentum. As with the surge in Iraq, these forces will be in place for a limited time to provide space for the Afghans to ... secure their own future."

Politically speaking, these foreign entanglements formed part of Bush's unlovely, unavoidable legacy. But Obama's uneasiness, some would say queasiness, over this poisoned inheritance was evident from the start. Mounting domestic and financial problems, plus public pressure to extricate American forces, further dimmed his ardour. Last year's Afghan strategy review and this year's sacking of General Stanley McChrystal helped produce a more pragmatic approach.

While insisting the goal of defeating al-Qaida and denying sanctuary to terrorists in Afghanistan remained paramount, Obama has deliberately lowered expectations and limited US ambitions there – provoking, for example, the recent outcry – typified by a searing commentary from Judy Bachrach in World Affairs Journal, over the prospective abandonment of Afghan women to the Taliban.

Talk of creating new beacons of freedom and democracy wholly disappeared. Instead, a new willingness to talk to the bad guys, or some of them at least, as in the Sunni Triangle in 2006-7, illustrated this shifting perspective. So, too, did a new political and diplomatic push launched at July's Kabul conference by secretary of state Hillary Clinton.

"We are matching our military efforts with an unprecedented civilian surge to help create stronger institutions and economic development," Clinton said, while claiming to discern progress towards good governance and curbing corruption. Her speech, and numerous other American statements about building up indigenous security capacity, mirrored the US approach in Iraq.

Problem is, as reports from Baghdad have made abundantly clear this week, key elements of Washington's Iraq handover strategy, and particularly the transition to local political control – policies that are now being replicated in Kabul – have worked only in part or not at all. There is little reason to believe they will work better in Afghanistan in Obama's circumscribed timeframe.

Petraeus said this week that he has completed new guidelines for turning over some security duties to Afghan forces. But senior Nato officers told Thom Shanker of the New York Times that "Afghan forces are nowhere near ready to take over the mission across the country". Progress has certainly been made – but the leadership, capability and, occasionally, loyalty of Afghan police and army forces remain questionable.

As with Iraq, Afghanistan still lacks legitimate, effective, democratic governance, despite exhaustive and expensive western institution building. Parliamentary elections this month, already dogged by Taliban intimidation, are likely to highlight the democratic deficit, as a new dispatch by Bahman Boman and Shahpoor Saber for the Institute for War and Peace Reporting makes clear.

As in Iraq, Petraeus's famed counter-insurgency rulebook, which calls for decades of persistent nation-building, is flouted for lack of time and political will. As with Iraq, political machinations in Washington disrupt the military-civilian strategy. These turf wars are only too familiar, said Alan Philps in The National newspaper. "We can already see the military pushing back against Obama's plans to start withdrawing troops next year in time for his 2012 re-elections campaign," he said. As with Iraq, the proposed "conditions-based" switch to Afghan control may encourage meddling neighbours, Iran included. Like Iraq, but more so, essential infrastructure for a successful economy is largely lacking in Afghanistan. Like Iraq, unresolved disputes over vastly lucrative mineral resources may trigger new conflicts. Yet like Iraq, with eyes shut to the possible consequences and insecurity still rife, Washington's divided Nato allies want out, and some like the Dutch have already left.

In short, what the history of the Iraq imbroglio says about what is likely to happen in Afghanistan is deeply dismaying. And the two conflicts have something yet more fundamental in common: even after the last foreign troops have ostensibly departed, that will not be an end to it. In Afghanistan, like Iraq, it's not over just because Obama says it is.