First of all I am sorry to hear that you have developed an ear infection
. To understand why ear infections are so painful, you must first know some general information about anatomy and pathophysiology. There are two very braod catergories of ear infections that are relatively common; otitis exterma (outer ear infections) and otitis media (middle ear infections). The thing that determines whether the infection is an outer vs middle ear infection is the tympanic membrane (ear drum). The ear canal that goes down to the ear drum is the outer ear, and everything medial to the drum is the middle ear.
This is important from a pathophysiologic standpoint, because there are different processes and bacteria that are common in each type separately. There is significant sensory innervation of the ear canal, which is redundant in areas which may contribute to the significant pain that people feel with ear infections. There are branches from cranial nerve 5, 7, 9, and 10 that all contribute to sensory innervation of the ear. With otitis externa (swimmers ear), bacteria can infect the skin of the ear canal, and if it is bad enough it can affect the bone as well. This is usually very painful and associated with drainage. With otitis media the infection builds up in the middle ear causing pain from mucosal irritation, and also pressure on the ear drum. There is usually no drainage unless there is a perforation int he ear drum. I hope that this helps. If you haven't seen anyone for your ear infection, I would recommend making an appointment with your primary care physician