BALAD AIR BASE, Iraq - Iraq's foreign minister said Tuesday the risks of civil war have been averted after five years of "tears and blood." But he warned an abrupt withdrawal of U.S. troops would wipe away the security gains and other achievements and have disastrous consequences.

With the war entering its sixth year, Foreign Minister Hoshyar Zebari acknowledged mistakes by all sides. But he insisted that Iraqis have made remarkable progress despite the violence that has killed tens of thousands of Iraqis and nearly 4,000 U.S. troops.

Zebari, a Kurd who spent years opposing Saddam Hussein in exile, said the Iraqis had cautioned that overthrowing the dictator would be "the easiest part" but "the day after would be far more difficult unless there was some planning, some preparation ... and some real participation by the Iraqi leaders."

"Mistakes were made by all, by the American military, by the British, by the coalition, by us, but this is water under the bridge now," he told The Associated Press in an interview in an ornate reception room at the Foreign Ministry building in central Baghdad.

Zebari, who spoke English during the interview, is the only Cabinet member to have held his post in each successive Iraqi administration since the U.S.-led invasion on March 20, 2003.

He singled out the May 2003 UN Security Council resolution that authorized the U.S.-led occupation as "the mother of all mistakes" because "it changed the mission from liberating the people into occupying the country."

"We had to struggle for almost a year to reverse that mistake," he recalled, saying the decision had fueled the anti-U.S. insurgency among Sunnis who felt disenfranchised after Saddam's ouster.

He noted, though, that the Iraqis still managed to establish a government and ratify a constitution after regaining sovereignty in June 2004, and that Iraqis enjoy freedoms that were absent under nearly three decades of Saddam's brutal rule.

"These past five years, I think, were full of hopes and promises but also of tears and blood ... and we've gone through a very, very difficult transformation," Zebari said. "What we the Iraqis have achieved over the last five years since liberation has been remarkable."

"At the same time divisions have deepened unfortunately," he added. "But ... I think we averted a sectarian war. We passed the possibility of a civil war."

Zebari's comments came a day after presumptive Republican presidential nominee Sen. John McCain and Vice President Dick Cheney stressed the need for a sustained U.S. commitment in Iraq during parallel visits to Baghdad.

The Iraqi foreign minister expressed concern about growing weariness by the American public about the war and promises by rival Democratic presidential hopefuls Sens. Hillary Rodham Clinton and Barack Obama to begin withdrawing forces quickly if elected.

Clinton has not given a specific time for a pullout but said as recently as Monday that the United States must get out of Iraq because the battered American economy "cannot afford" the war. Obama has said he'll end the war in 2009.

Zebari urged patience, saying it was premature to set a timeframe for a U.S. withdrawal as negotiations on a long-term security agreement with the United States had just begun. He said the Iraqis hoped to finalize the deal by July.

The foreign minister said adjustments could be made, but that the consequences of a premature withdrawal would be "disastrous" and all the security gains from a U.S. troop buildup "would evaporate."

He was optimistic that the threats to pull out were empty campaign rhetoric.

"We are in an election season, and many candidates will say things that appeal to the public. But when the real national interests of the United States, of the nation, confront them, I think they have to make hard decisions," Zebari said of the candidates.

"I think now American interests in this part of the world are as important as they were in Germany during the World War so it will not be easy for any administration, Republican or Democrat, just to wash off their hands and walk away," he said. "There is a certain responsibility, an international and moral responsibility, to help the people of Iraq to reach a stable form of governance."

Zebari conceded that the Iraqi leadership needs to make more progress toward political reconciliation, warning that failure to achieve democracy would have wide-ranging consequences for the region and leave Iraq vulnerable to outside influence.

Cheney, rallying troops on a U.S. base north of Baghdad, echoed concerns that Iraq's failure would have regional consequences.

"We're helping them fight back because it's the right thing to do and because it's important to our own long-term security," Cheney said Tuesday. "As President Bush has said, the war on terror is an ideological struggle and as long as this part of the world remains a place where freedom does not flourish, it will remain a place of stagnation, resentment and violence ready for export."