What can you do about boredom? Obviously, there are times when you are stuck. If you are listening to a lecture that you cannot leave, then you just need to find a way to get through it. When you have some control, though, use your understanding of boredom to help you out. If you can, try to do a meditation exercise to lower your arousal level. Also, keep some music handy. Music you enjoy can crowd out distractions in the environment. It can also influence your mood in positive ways to counteract the pain of being bored.  
“When I have neither pleasure nor pain and have been breathing for a while the lukewarm insipid air of these so called good and tolerable days, I feel so bad in my childish soul that I smash my moldering lyre of thanksgiving in the face of the slumbering god of contentment and would rather feel the very devil burn in me than this warmth of a well-heated room. A wild longing for strong emotions and sensations seethes in me, a rage against this toneless, flat, normal and sterile life. I have a mad impulse to smash something, a warehouse, perhaps, or a cathedral, or myself, to commit outrages, to pull off the wigs of a few revered idols...”
The French term for boredom, ennui, is sometimes used in English as well, at least since 1778. The term ennui was first used "as a French word in English;" in the 1660s and it was "nativized by 1758".[7] The term ennui comes "from French ennui, from Old French enui "annoyance" (13c.), [a] back-formation from enoiier, anuier.[7] "The German word for "boredom" expresses this: Langeweile, a compound made of lange "long" and Weile "while", which is in line with the common perception that when one is bored, time passes "tortuously" slowly.[8]
These authors suggest that attention plays an important role in creating boredom. In particular, there are a few conditions that need to be met for people to feel bored. First, people need to have a reasonable level of psychological energy or arousal to feel bored. When people have low arousal and there is not much happening in the world, then they often feel relaxed. When they have high arousal, though, they have energy they would like to devote to something, but they cannot find anything engaging.
The French loanword ennui comes from the very same Late Latin word that gave us annoy — inodiare ("to make loathsome"). We borrowed ennui several centuries after absorbing annoy into the language. Ennui deals more with boredom than irritation - and a somewhat specific sort of boredom at that. It generally refers to the feeling of jadedness that can result from living a life of too much ease. The poet Charles Lloyd described it well in his 1823 Stanzas to Ennui when he referred to that world-weary sensation as a "soul-destroying fiend" which visits with its "pale unrest / The chambers of the human breast / Where too much happiness hath fixed its home."
×