A gunman has opened fire with an assault rifle at Los Angeles International Airport, killing a security officer and injuring at least six others, authorities say.

The gunfire on, in LAX Terminal 3 on Friday (local time), touched off panic and chaos at one of the world's busiest airports as passengers fled or dove for cover behind racks of luggage as police shouted warnings to travellers to evacuate.

The Transport Security Administration said in an emailed statement that one of its agents had been killed, the first in the line of duty, and several others shot.

An FBI spokeswoman identified the suspect as 23-year-old Paul Anthony Ciancia, a resident of the Los Angeles area.

Patrick Gannon, chief of the Los Angeles Airport Police, said at a press conference: "An individual came into Terminal 3 of this airport, pulled an assault rifle out of a bag and began to open fire in the terminal."

"They went after this individual and they confronted this individual in our airport, and unfortunately it involved an officer ... but that's what needed to be done in that particular situation, and that was heroic."

One traveller told a local CBS affiliate that airport security agents had come through the terminal shouting that a man had a gun.

"I heard popping and everybody dropped to the ground," he said.

The shooting prompted scenes of chaos at the airport, with departing flights grounded and the terminal evacuated.

Streets surrounding the airport were also shut down, and passengers crowded onto the footpaths with their bags as the authorities began telling people not to turn up for flights.

Los Angeles police spokeswoman officer Norma Eisenman said a suspect, who they believed to have acted alone, had been taken into custody.

Three male victims hurt in the incident were taken to Ronald Reagan UCLA Medical Center, where one was listed in critical condition and two others in fair condition, said Mark Wheeler, a spokesman for the hospital.

The motive for the shooting was unclear, but the Federal Bureau of Investigation said it could not rule out terrorism.

President Barack Obama, speaking to reporters in the Oval Office after meeting with Iraqi prime minister Nuri al-Maliki, said: "We're concerned about it, but I'll let law enforcement folks talk about it directly."

'I heard popping and everybody dropped to the ground'

One traveller at the airport, Robert Perez, told a local CBS affiliate that airport security agents had come through the terminal shouting that a man had a gun.

"I heard popping and everybody dropped to the ground," Mr Perez said.

Alex Neumann told cable network CNN that he was in an area inside the airport past a security checkpoint when he heard loud noises and screaming and saw people running in a scene that amounted to mayhem.

"We were at the food court and all of a sudden I hear a big commotion and people started running. People were running and people getting knocked down," Mr Neumann said, adding that he heard screams. "Mayhem is the best way of describing it."

Jose Mares, who was catching a flight back to his home in Oklahoma with his wife, said he was about 20 metres away from a man with a gun on the second level of Terminal 3 when the man opened fire.

Mr Mares, 31, said he used his own body to shield his wife from the bullets.

"As I'm getting on top of her I'm reaching for more luggage and that's when I stacked luggage like two high and then made a row of luggage," he said.

"I was in the corner and I'm looking at the guy just shooting randomly, like I saw a TSA [agent] go down."

Mr Mares said when the shooter looked and pointed in his direction and appeared headed toward them, he told his wife: "Once I say three you better run. Once I had the opportunity as he is looking down the escalator, that's when I told her 'OK, let's go. Let's run.'"

Alex Neumann, meanwhile, told cable network CNN that he was in an area inside the airport past a security checkpoint when he heard loud noises and screaming and saw people running in a scene that amounted to mayhem.

"We were at the food court and all of a sudden I hear a big commotion and people started running. People were running and people (were) getting knocked down," Neumann said, adding that he heard screams. "Mayhem is the best way of describing it."

Television images on cable network CNN showed at least one person being loaded into one of several ambulances at the scene, and passengers were seen being evacuated from the area.

Footage showed emergency responders setting up what appeared to be a triage area outside an airport terminal, and outgoing flights were halted.

Flights delayed, cancelled and diverted, stranding thousands

Los Angeles International Airport (LAX) is the world's sixth busiest, handling over 63 million passengers in 2012, according to its website.

After the shooting, dozens of flights were cancelled and more than 100 delayed considerably, while arriving planes were diverted elsewhere.

Passengers still in the airport were told the Red Cross would bring in food, and many were told they were not to leave the airport or move around.

Gina Marie Lindsey, LAX executive director, warned that it could take some time for the airport to resume normal operations.

"Understand that will take quite a deal of time; it's going to be a logistics, carefully orchestrated logistical ballet to ensure that we can get people reprocessed and back on their flights," she said.

"I think it's fair to say that almost every flight out of LAX today will be significantly late."