Why dogs sniff each other's tails

Once upon a time, when dogs ruled the earth, a gala dog ball was organised and all the dogs in the world were invited.When the dogs arrived at the ball they checked their tails in at the cloak room, as was the custom in those happy, far-off days.It was a wonderful, glittering occasion and all the dogs, regardless of breed or background, danced the night away and were thoroughly enjoying themselves until suddenly the fire alarm sounded.
The ballroom was alight and an uproarious panic broke out. The vast yelping pack stampeded to the cloak room and in the confusion the tails were mixed up.To this day you will see them sniffing each other's tails as they go about their forlorn search for their proper tails. This is the eternal aftermath of the night that THE DOG BALL CAUGHT FIRE...

This is the text begins this collection of Michael Leunig's cartoons, after a 'self portrait' from 1972 (which is a cartoon of a man urinating into the wind off the bow of a ship). Those who are familiar with Leunig will know what to expect; the big-nosed characters, presence of animals, and critiques and observations of social life pretty much make up this book. Sex, love, and human interaction are the themes Leunig explores in this collection (not that he has deviated much from those themes in his forty-year career), and like most of his other work it aims to please by presenting emotions and situations with his instantly recognizable figures. Some cartoons are single cell, while some are elaborate stories (such as 'Why Dogs sniff each other's Tails', which is included in the collection). Some have his characters conversing in recognisable enviroments (the bedroom, a park, the beach), while others are quite surreal. Most of the work in this collection is quite refined in both humour and draftsmanship compared to the material in The Penguin Leunig, even the early drawings. In short if you like Leunig's work you will like this, if you dislike his cartoons this is not going to sway your opinions. For someone who has not been introduced or is unfamiliar with his 'folk art', I can recommend this as a good introduction.

In North America, you can find this story in the oral tradition of various indigenous peoples, but with a significant difference: the mix-up with the coats was intentional. Someone had a motive for setting fire to the house where the dogs were gathered.

When he asked, the dogs refused him.
You are unclean, they told Coyote,
you are not a dog.
So the dogs undressed for their sweatbath
and entered the sweat lodge without him."Why Dogs Smell Each Other's Butts," Lowell Jaeger

Yes, one of the native canids, Coyote, was there. But he was not invited inside to sweat with the dogs. He could have stolen their coats, then. But he didn't. He mixed up the pile of fur coats, muddied them so they were unrecognizable. And only then did he set fire to the roof, getting the dogs to race outside. Hearing Coyote's laughter, the dogs grabbed the first available coat they could find, thinking Coyote might have stolen some, and there might not be enough now to go around.

Years later, as the story goes,
with every dog zipped in someone else's fur,
dogs smell each other's butts,
looking for their own.

Both domesticated dogs, and the coyote (Canis latrans) have anal glands used to mark territory and identify individuals. The glands are located beneath the tails, so if you're a dog, and you need to check out another dog's scent, the anal/tail area is where you need to sniff.
Sources:
Jaeger, Lowell. "Why Dogs Smell Each Other's Butts." Coyote's Journal. Berkeley: Wingbow Press, 1982.
MacCarter, Jane S. "The Coyote." Mountain Times. <http://www.mountaintimes.net/F-W-Coyote.htm> (25 February 2003)
"What are the Anal Glands?" PetsPlace.com 2001. <http://petplace.netscape.com/articles/artShow.asp?artID=3399> (25 February 2003)
"Why Dogs Sniff Each Other's Butts." ShadowWoman's Forum. 7 July 1999. <http://www.walkingant.com/discus/messages/48/346.html> (25 February 2003)