State Department of Education spokeswoman Donalyn Dela Cruz said the boy showed up at Roosevelt High School near downtown Honolulu, and officials there recognized him as a runaway and called police. The boy had been a student at the public school before, but wasn't registered for classes there this semester, she said.
Honolulu police Maj. Richard Robinson said officers arrived at the school and tried to take the boy into custody, but he lunged at them in a small office.
The teen punched two officers, then attacked a third with a kitchen knife, leaving him with a minor cut on his torso, Robinson said.
One of the officers then fired two shots, hitting the boy once in the wrist. The teen hospitalized in serious condition, EMS spokeswoman Shayne Enright said. His injuries were not life-threatening, and the officers' injuries were not serious, authorities said.
"The suspect was taken into custody and walked out of the school," Robinson said. He added the boy was arrested on suspicion of three counts of attempted murder.
The incident prompted a lockdown at Roosevelt, which has an enrollment of nearly 1,400. Several parents gathered outside, with many calling and texting their children for updates.
Dela Cruz said an adult and student in the office fled when the scuffle began, leaving police alone in the room with the boy when the shots were fired. Dela Cruz said the school was informed Monday by adults responsible for the teen that he was a runaway. The boy was not being disruptive before officers arrived, she said.
A spokesman for the prosecuting attorney's office in Honolulu said the boy had not yet been charged, and the case would remain private in family court unless the court waives jurisdiction and the boy is tried as an adult.
Police and school officials withheld his name, citing his age and privacy rules for students and minors who are arrested.
The officer who fired is on administrative leave during an investigation, Robinson said.
It wasn't immediately clear if he aimed for the boy's arm or another part of his body. Those details are part of the ongoing investigation, Robinson said.
Tenari Maafala, president of the statewide police officers union, said the knife posed a clear threat and officers are trained to stop a threat, regardless of the suspect's age.
"They didn't come here looking to shoot somebody," said Maafala, who went to the school as part of the Honolulu police peer support unit.
Noah Powell, a 16-year-old junior, said the shooting happened in a school counselor's office. Powell said he was in a nearby office and heard the struggle and shots but didn't see the 17-year-old or know who he was.
Kealii Akiona-Soares, a junior, was in a social studies class when he heard a faint shot at about 8:20 a.m.
Then a school bell sounded and students were kept in their classrooms, the 17-year-old said. He said his class continued with a politics lesson, and everyone kept mostly calm.
"I guess it happens a lot in mainland schools, so it's not surprising," Akiona-Soares said.
Carolyn Richardson was among the parents who rushed to Roosevelt after word of the shooting spread.
"This is really freaking me out," she said.
Richardson learned of the shooting around 9 a.m. through a message from her son CarDarow.
The sophomore texted her that he heard shots had been fired but that he was all right. Richardson then used her cellphone to video chat with her son, screaming: "I gotta hear your voice!"
Faith Kalamau said she went to the school as soon as she got an automated call saying the campus was on lockdown.
"I'm very worried," she said. "I heard on the news there were some people shot."
Kalamau eventually reunited with her son, freshman Kahaku King, but she said officials took too long to provide details about what happened.
"I was frustrated," she said. "I thought maybe more information should have been told to the parents or at least to the media. This is the first time I've been in this situation."
School was let out at about 10 a.m., and a steady stream of students filed off the campus, near the National Memorial Cemetery of the Pacific known as Punchbowl. Classes were to resume Wednesday.
"Incidents like this are very rare in Hawaii; however, our partnership with the Honolulu Police Department on safety drills played a major role in the success of today's lockdown," Schools Superintendent Kathryn Matayoshi said. She commended staff and students for following safety protocols and thanked parents for their patience and understanding.
Hawaii is one of 12 states that have not had someone enter a campus with the intent to shoot, state Education Department officials said.
In 2011, a handgun that a 14-year-old student brought to Highlands Intermediate School in Pearl City went off, narrowly missing one student and leaving another with minor injuries.
"I'm really shocked it happened here in Hawaii of all places," said Angie Estrella as she picked up her freshman son and senior daughter.