Thrain is the son of Thror and the father of Thorin, Frerin, and Dis. Did you notice him in the prologue of TH:AUJ? Better go back and watch it.
As Tumblr put it, he completes the trinity of nobility, inheritance, and PAIN. They may be angsty, they may be stubborn, they may make us want to pull our hair out and hate them to the depths of Angband and back, but we love these sons of Durin anyway.
In the book, Thrain lost his eye at Azanulbizar, and didn't disappear for a few years later. In the movie, he has already lost it, apparently through burning, and he disappears during or right after the Battle of Azanulbizar. But there is more you need to know about Thrain, other than appreciating him as the father of Thorin and the grandfather of Fili and Kili.
Guess what? He watched his father go mad with gold. He saw his kingdom be ravaged in the span of a few hours by a dragon. He saw his father beheaded at Azanulbizar. He saw his younger son, Frerin, also die at Azanulbizar. And then he was dragged off to the dungeons of the Necromance (a.k.a., Sauron) and tortured for literally decades.
Now, while you might believe Sauron did it just for the fun of it, he didn't. Thrain had the key to Erebor and the map. Sauron wanted it. Why? His Dark Tower, Barad-dur (yes, that is literally what that means in Sindarin) is in Mordor. There are basically two things blocking Mordor's access to the rest of Middle-earth: Gondor and Erebor.
Erebor is a fortress-kingdom in a huge mountain (personally, I believe it is an extinct volcano), and there IS no Minas Tirith, no Tower of Guard, no defense between it and Mordor. It guards the North against Sauron - it guards or guarded Laketown, Dale, the Beornings, Mirkwood, the northern Misty Mountains, Rivendell, and so forth.
Sauron wanted to destroy Erebor. As Gandalf worried, he could have used Smaug to destroy Rivendell, the Shire, and so forth. But he didn't. Gandalf helped orchestrate the Quest for Erebor and got the dragon killed.
But Gandalf would never have been able to get that to happen if he hadn't had the map and key.
Where did he get the map and key?
While investigating Dol Guldur, he found a mad Dwarf.
Remember this guy from the trailer?
The ninja dwarf jumping Gandalf here is Thrain. Thorin's dad. His sanity was so far gone he could not remember his own name or the name of his son, but he could pass on the map and key to Gandalf. His endurance saved everyone in Middle-earth, and he never got any songs or tales in his honor. he died in that rank, dark dungeon, and no one remembers him now.
How do you feel about yourself now?
In Pace Christi,