Okay, I admit it: I'm not going to be writing any dirty limericks, though I'm sure you've all heard a few in your time. And I can't really stop anyone from sharing one or two below in the comments (that's what they're there for, I guess--that is, for dirty limericks).
The origin of the limerick is shrouded in some mystery, but most sources seem to point to the early 18th century--one theory being that soldiers returning from France to the Irish town of Limerick started the form, the other theory pointing to the 1719 publication of Mother Goose Melodies for Children. Either way, Edward Lear popularized the form in the mid-19th century.
Basically, the limerick is a five-line poem consisting of a triplet split by a couplet. That is, lines 1, 2, and 5 are a bit longer and rhyme, while the shorter lines of 3 and 4 rhyme. After studying many effective limericks, there is not a precise syllable count per line, but the norm is about 8-10 syllables in the longer lines and around 6 syllables in the shorter lines.
Here's one of my basic examples:
My eldest son's scared of small flames,
and I know just what is to blame:
those Frankenstein movies,
though they can be goofy,
burn monster and my son the same.
Here are some other resources related to the limerick: