Greenspan wrote: "Whatever their publicised angst over Saddam Hussein's 'weapons of mass destruction,' American and British authorities were also concerned about violence in an area that harbours a resource indispensable for the functioning of the world economy.
"I'm saddened that it is politically inconvenient to acknowledge what everyone knows: The Iraq war is largely about oil.
Greenspan retired in January 2006 after more than 18 years leading the Federal Reserve, the nation's central bank, which regulates monetary policy.
Appearing on ABC's This Week, Gates said: "I have a lot of respect for Mr Greenspan."
But he disagreed with his comment about oil being a leading motivating factor in the war. "I wasn't here for the decision-making process that initiated it, that started the war," Gates said.
He added: "I know the same allegation was made about the Gulf war in 1991, and I just don't believe it's true.
"I think that it's really about stability in the Gulf. It's about rogue regimes trying to develop weapons of mass destruction. It's about aggressive dictators.
"After all, Saddam Hussein launched wars against several of his neighbours.
"He was trying to develop weapons of mass destruction, certainly when we went in, in 1991."
Bush last week ordered gradual troop reductions in Iraq into next summer, but refused to change course, saying that the US military role there will stretch beyond his presidency.
Gates said he would urge Bush to veto a proposal by Democratic Senator James Webb of Virginia that would require US troops to spend as much time at home as their previous tour in Iraq.