Well, keeping the players entertained and having fun is the "big picture" job of the DM, but what does that mean? (I'm sure tap dancing, joke telling, and juggling orc minis might keep them entertained.) I'm actually a little more concerned with engaging them rather than entertaining them. If they're engaged in the game, then they're entertaining themselves and me too.
How to engage them depends on the group. With my current group, they need varied encounters, a storyline that can be followed easily from week to week, good tactical combat, memorable NPCs, and a villain they can hate. They also need me to know the rules without the game grinding to a halt while I look one up. (that one is a biggie)
So with an eye on engaging my particular group, I know my job descriptions are thus: (In no particular order)
1. Interesting and varied encounters. This means using different types of terrain and opponents with varying types of attack and modes of defense. Also means knowing how it all works with a minimum of page flipping.
2. Story. At its root, make it simple enough that it can be remembered from week to week. (I don't do too many convoluted plots...if there's a twist, its usually a major one) I don't want to have to keep constant email contact just to keep the players up to speed.
3. Memorable NPCs.This basically means putting enough thought into portraying them that the players will remember. That means a good voice, enough telling detail, and a name they can say and will remember.
4. Good Villains, though most of this goes with job 3. In most of my stories, the villain makes him/herself known fairly early on, so the PCs can start hating him immediately. I've found that the Shadowy Puppet Master with Mysterious Motives that Stays in the Background, gets a little tiresome.
5. Know the rules. I know its "role-playing", but its still a game. If I'm pitting them up against a creature that can "cast color spray as a 10th level sorceror" You can be damned sure that by the time the encounter happens, I'll know what that means without needing to stop the game.
Those are basically what I see as my job description as a DM.