Lt. Greg Gallant, of the Methuen, Mass. police department

Lt. Greg Gallant, of the Methuen, Mass. police department, portrays an active shooter as he roams the halls of a school with an assault rifle, loaded with dummy rounds, during a demonstration in Methuen, Mass., Tuesday, Nov. 11, 2014. AP / CHARLES KRUPA

With students off for the Veterans Day holiday, a simulated school shooting at Methuen grammar school Tuesday showed what “active shooter” technology could do to help police catch a gunman if the horrible threat ever strikes as it has at other schools across the country.

In the live demonstration, the “gunman” entered the school armed with an assault rifle, opening fire with dummy rounds first in the school library then rampaging through hallways and classrooms.

But he had only a few minutes to wreak havoc.

Smoke alarm-sized sensors installed in classrooms, hallways and other points throughout the building were activated by the sounds of gunfire, and police officers immediately were able to track his movements and quickly subdue him.

Nearly 100 people, including U.S. Rep. Nikki Tsongas and regional law enforcement officers, gathered in the school to view the demonstration of what the school district bills as the first such system operating in a public school in the U.S.