George Friedman has a good short analysis of what happened in South Ossetia from the Russian perspective. He doesn’t have an explanation from the U.S. perspective, and I don’t either. It seems possible that Saakashvili ordered the invasion of South Ossetia without any support from the U.S., and that the U.S. felt obliged to support him after the fact. It would have been very irresponsible for the U.S. to encourage his attack, given that 1) it predictably led directly to a confrontation with Russia, and 2) the U.S. could not militarily support the move even if they wanted to.
Given that the U.S. supported an independence referendum for Kosovo, they should have supported one for South Ossetia as well. I see no principled difference there, just that Georgia is an ally and Serbia is not. With Russia now occupying South Ossetia (and Abkhazia) the chances of a real independence referendum seem low.
The only reason the small war is of any interest to the U.S. is, of course, oil. The Baku-Tbilisi-Ceyhan pipeline was designed to get oil from the Caspian Sea to the West while avoiding Russia and Iran. It runs through Georgia. This is the pipeline featured in the James Bond film “The World is Not Enough,” though the real one is presumably more prosaic.