No, the problem the U.S. faced, both in Vietnam and Iraq, was that while the U.S. believed it was there to rescue the country and its people, a fair chunk of those people regarded the U.S. as an enemy. And when it’s next to impossible to tell the people you’re trying to rescue from the ones who are trying to kill you, you’re screwed.
Simply being at war is much easier than nation building. We can kick everyone’s ass in flat-out war; it’s just that the time when that ability was important has mostly passed. And neither the U.S. nor anyone else has figured out how to do nation-building in a nation that doesn’t want to be ‘built’ by us. Part of the problem may be that we’re doing nation-building in parts of the world we understand poorly. But hell, we couldn’t even manage it within our own borders, after the Civil War. The South lost the war, but won the peace.