It's Easier Than It Looks, Actually
Anyone that's studied a martial art that includes a form of grappling has learned about pressure points and the weaknesses that every human body shares. When it comes to quick knock outs though there are only three things that you can do; great harm to the head, interrupt the flow of oxygen to the brain, or cut off the supply of blood to the same, very-necessary organ. All of these are risky moves, but when they work they are fight enders. The infamous Sleeper Hold uses the third strategy, and once you know that it's a fairly simple thing to execute.
Get Into Position
Start off by getting behind your opponent. You want to bring your dominant arm (left or right, whichever is more comfortable for you) around his throat. Ideally the crook of your elbow should be sitting right against the Adam's apple or the trachea. Rest the elbow of your other arm against your opponent's opposite shoulder, and using your dominant hand, grab your opposite bicep. You now have a hard, firm grip on your opponent, and the sides of his neck should be pressing against the bicep and forearm of the arm you have around his throat.
The next step is to reach down with your non-dominant hand and grab the back of your opponent's head, pushing it down into your arm. Lastly, and here's where the tricky part comes in, flex the forearm and the bicep of your dominant arm so that you're squeezing the sides of your opponent's neck. If you did this right he'll pass out in less than a minute, and probably closer to 15 seconds. 10 seconds if you're lucky and he's really winded.
Also, if you have problems getting into position (usually because your opponent is taller than you are) then kick the back of the leg to bring your opponent down to one knee, or hit him hard in the lower back so that he'll arch up. This will give you a great opportunity to get a better hold that can be just the opportunity you need.
How Does It Knock People Out, Though?
Why does the Sleeper Hold work? That's a good question, and astute readers or those that paid attention in biology already know.
The simple explanation is that when you squeeze your arm against the sides of your opponent's neck you are cutting off blood to the brain by clamping down on the arteries in the sides of the neck. Without a steady flow of blood to the brain he'll begin to pass out, and within less than half a minute your opponent goes down, no muss, no fuss. Of course if you get the timing wrong, of if you maintain the hold past the point of unconsciousness it's entirely possible to kill someone. This is why whenever you perform the Sleeper Hold you should be very careful and, if possible, have supervision from someone with experience in this and other, similar martial arts techniques.