Keith Olbermann was fired by MSNBC sources tell TMZ, and we're told it had everything to do with Comcast's acquisition of NBC.

Sources connected with the network tell us ... Comcast honchos did not like Keith's defiance and the way he played in the sandbox.

Our sources say Keith has around two years left on his contract, and he'll be paid his salary -- around $7 million a year.

We don't know if Comcast will let Keith make a deal with another network as part of an exit agreement, but it's a good bet he'll be benched for a minimum of 6 months, and probably longer.