Media playback is unsupported on your device Media caption "Students started screaming and running"

Two people have been killed and 17 injured in a high school shooting in the US state of Kentucky.

A 15-year-old girl died at the scene at Marshall County High School in the town of Benton and a 15-year-old boy died in hospital, said Kentucky's governor.

The attacker, a 15-year-old male student, was arrested in "a non-violent apprehension", officials said.

State police said the unidentified boy was held about 15 minutes after opening fire at 08:00 local time on Tuesday.

Image copyright CBS Image caption Parents rushed to the school to pick up their children

The lone attacker opened fire with a handgun apparently at random in a common area before classes started, according to local media.

He will be charged with murder and attempted murder, said officials. The FBI was assisting in the investigation.

Police named the two students who died as Bailey Holt, pronounced dead at the school, and Preston Cope, who succumbed to his injuries in hospital.

Image copyright Tracy Tubbs Facebook Image caption Fifteen-year-old Bailey Holt was shot and killed at school

Fourteen students were hit by gunfire, including the two who died.

Another five students suffered non-gunshot injuries while trying to escape the gunfire.

Image copyright CBS Image caption The scene at the Marshall County High School

Jason Hall, a student at the school of nearly 1,150, described the stampede for the exits.

"I saw people getting shoved down," he said. "There was a lot of blood everywhere. It was horrible."

The attack shocked the small farming town of 4,500 people, situated about 130 miles (210km) north-west of Nashville, Tennessee.

"To walk in, the backpacks laying around, the phones laying around, going off, it's indescribable," Marshall County Attorney Jeffery Edwards told reports the Louisville Courier-Journal.

"I've been doing this for 25 years. It's not like anything I've experienced in my life."

Media playback is unsupported on your device Media caption A guide to the weapons available in the US and the rate at which they fire

Governor Matt Bevin called the attack a "tremendous tragedy" in a statement posted on Twitter.

"It is unbelievable that this would happen in a small, close-knit community like Marshall County," he said.

"As there is still much unknown, I encourage people to love on each other at this time.

"Do not speculate, but come alongside each other in support and allow the facts to come out."

In Washington, Kentucky Senator Mitch McConnell took to the Senate floor to send "prayers of comfort" to the community.

Several nearby churches and schools were holding vigils for the victims.

Wednesday's classes at the school have been cancelled.

It is at least the second gun attack in an American high school in as many days.

A 15-year-old girl was shot by a 16-year-old classmate in the cafeteria on Monday in the small Texas town of Italy.

The girl is recovering in hospital; her attacker fled but was later arrested.