Well, as a current college student (and moderately recent high school student), I've thought quite a bit about what should be done in such an event.
Personally, I don't much care what the teacher/professor says, and didn't in high school, either. If something is happening, I'm bugging out ASAP, and whoever wants to come along is welcome (and if they want to hide under their desks, then luck to 'em).
I was in high school during the Columbine incident, and even before that the idea of a shooting rampage was not foreign to me. I decided that the staff and faculty could say what they will, but my life is my own; they can expel me if I live, but in the mean time I'm looking out for number 1. I more or less assumed that whoever was "in charge" of the students would be ordering them to stay put, "duck and cover", or whatever. Hunkering down in a classroom waiting for either the situation to resolve itself, or to be gunned down, is not my idea of a good idea. I may be more vulnerable outside to a degree, but at least I can try to see danger coming and run away, or take cover and evade, or even see if I can't get in close enough to grapple with a gunman. I reached my current height of about 6 feet when I was 13, in late 8th grade, so it wasn't too ridiculous a thought, if I were desperate enough.
Now that I'm in college, the plan hasn't changed much. If I could arm myself, then I might feel better about staying put, or actually shepherding the students in my class and maybe nearby classes to safety, as at least I could offer some protection. However, since my armament at school is limited to a folding knife and, sometimes, OC, there's little I can do against a gunman except die, unless I can get really close. So the plan now is pretty much to book out to wherever I parked (usually across a few hundred yards of mostly open ground). I don't like it much, but there aren't many options.
On a more general level, I have a few ideas of what the response ought to be, assuming that the schools don't actually do anything helpful like let us carry or post armed, roving patrols (the latter is not my idea of conducive to an institution of learning, anyway).
Lockdowns, as has been said by others, would be a good start. The problem is that, in any such situation, it's highly doubtful that anyone will know what's going on until it's all over, if then. Even in the classrooms that have working intercoms or wall phones (about even up in high school; probably 10% or less in my college), I'd bet $20 to your dollar that there isn't a protocol in my school, or most schools, for contacting individual classrooms or using the PA system for instruction. Similarly, I would bet that in most schools there is either no functioning alarm, or a single alarm system for everything; drill, fire, earthquake, nuclear strike, or terrorist incident. The most that I could really hope for is to hear an alarm, that could mean anything.
Naturally, my personal response to any such alarm, drill or no, is high-tail it to my car and drive on home, and then have a drink to steady my nerves while I see if the local news says anything about it.
I've heard of some schools using automated calls to a list of student cell phones, warning them of the incident. Or even e-mails. I doubt either solution is at all effective. Personally, I don't even carry my cell phone to class. Most probably do, but during class they're going to be shut off. Similarly, e-mails are only going to warn those that haven't come in yet, and that happen to check their e-mail before doing so. Either is almost totally useless.
The only thing I can realistically see schools doing is putting in better communications and instituting emergency protocols, and I doubt they'll do that.
So, as I was saying, lockdowns would be a good start, except that it's doubtful any information will be forthcoming. So, I would think that an orderly evacuation protocol would be superior. Better still would be a general order to "Get out and go home"; orderly columns make wonderful targets, as several hundred years of Napoleonic infantry tactics has proven. A fleeing mob is less orderly, and therefore (ironically) safer. However, for pre-teen students and younger, an orderly evacuation is probably the better bet, so kids don't go wandering off (I likely would have anyway, but I'm contrary like that).
Not that it matters much to me, as I'll be out the door and down the street before the professor can say "We're going to head outside to our designated evacuation site in an orderly fashion." No thanks, I'll be in my car.