The inner stories are told either simply to entertain or more usually to act as an example to the other characters. In either case the story often has symbolic and psychological significance for the characters in the outer story. There is often some parallel between the two stories, and the fiction of the inner story is used to reveal the truth in the outer story.
I've got a scene in Hostile Planet where I do this "story within a story" thing, and I'm writing one now in Neutral Ground. A few characters are telling stories around the campfire. (Yes, they're literally in the woods and sitting around a fire.)
It's a cool device, and it's fun. I just hope it works. Only my beta readers know for sure, so we'll just have to wait and see.
Neutral Ground currently stands at 37,000 words. My goal was to finish the first draft by Thanksgiving, and I'm still confident I can do that.