It's a traditional song about the treasure of the Lonely Mountain and the dragon Smaug, which was sung by the ancestors of the men of Dale before Smaug destroyed their town. It's significant in the story because it helps Bard, the bowman of Lake-town, learn the history of the dragon and its weakness.