The Doctor defends Earth so much because he has to.
Just about every human companion the Doctor has ever had has saved his life at least once. Therefore, he has to maintain the history of Earth to ensure these companions are still born at the right time and end up in the right place to meet him. Otherwise, he’ll disappear in a puff of logic. And the more he defends Earth’s history, the more times his life gets saved by humans, so the more he has to defend Earth’s history. As part of this strategy, he keeps a copy of the Complete Works of Shakespeare in the TARDIS, and consults it frequently. If “Troilus and Cressida” goes missing, that means the timeline is broken at some point before Vicki is due to be born, and he has to go and fix it. If the entire book disappears, Shakespeare needs rescuing.
The Master is compelled to see the Doctor as his enemy because he has No Fourth Wall.
The drumming sound in his head? It’s actually the bass line for the Doctor Who theme. He is subconsciously aware that he is a fictional character in a fictional universe and meant to be a Designated Villain for the series, which the constant theme stuck in his head keeps reminding him of, and it compels him to fight against The Doctor and be evil. How did he get this way? By seeing into the rift that all Time Lords look into as kids, in reality a rip in their fictional dimension into ours; those who look into it either run away in denial of seeing “the real world”, go mad upon realizing they’re nothing but fictional constructs, or become Dangerously Genre Savvy (AKA “inspired”) as a result.
When the Master looked into the vortex as a kid, he saw the Doctor Who opening credits, and it drove him mad. Imagine looking through a rift in time and space and seeing Colin Baker’s terrifying disembodied head flying toward you. You’d vow to kill that guy, too!
I don’t think that would make much sense, but it’s a kind of awesome theory.