Two other people, one of them a security agent, were shot and at least four others were injured in the melee.
The Newyork Times reports that the gunman entered Terminal 3 just before 9:30 a.m., pulled a weapon from a bag and began firing as he forced his way through a security checkpoint, officials said. Airport police officers chased him through the bustling terminal as he continued to fire, before shooting him near a departure gate and arresting him.
The T.S.A. agent who was killed was the first to die in the line of duty since the agency was created in the aftermath of the Sept. 11 terrorist attacks, officials said.
Thousands of travelers throughout the airport were evacuated and flights were grounded for hours, with some incoming flights diverted to nearby airports and others held on the tarmac while the shooting unfolded. Passengers spent hours in waiting areas, parking lots and nearby hotels as they waited for flights to resume. Air traffic across the country was stalled in a ripple effect from the shutdown.
Federal officials identified the gunman as Paul Ciancia of Los Angeles, who had previously lived in New Jersey. A senior federal official said that he had a note with "antigovernment and anti-T.S.A. ramblings." Mr. Ciancia was being treated at a Los Angeles hospital, officials said.
Former classmates at the Salesianum School, a private boys' school in Wilmington, Del., said Mr. Ciancia was a quiet student. He played the tuba in the school band for all four years he attended, 2004 to 2008, said Jesse Sooy, 23.
"He was a really quiet kid," Mr. Sooy said, describing a slight young man, no taller than 5-foot-7, with dark brown hair, who rarely spoke unless spoken to. "His dream was to work in his dad's collision company," Mr. Sooy said, naming it as Salem County Collision, an auto repair shop in Pennsville, N.J. "I was so shocked that he was even at LAX."
In Pennsville, neighbors of the Ciancia family described them as hard-working people who had lived in the community for at least 20 years and kept to themselves.
"Paul, the father, has been a well-respected businessman here for many years, and has always taken care of people well," said Gary Hankins, who lives across the wooded street in the suburban South Jersey community of about 14,000.
Rich Garry, 68, of Fullerton, Calif., said he had been at Terminal 3 on Friday morning headed for a flight to New York to visit family members. He said that a security officer had just checked his boarding pass and that he was waiting in line at the security checkpoint when he heard two shots.
"I heard a ‘pop-pop' and I looked down a floor below, and the T.S.A. guy was on the floor," he said. "He had been shot."
Mr. Garry said he believed it was the same security officer who had inspected his boarding pass.
As the gunman moved through the terminal, Mr. Garry said, "he was very calm. When he got to the top of the stairs where the security checkpoints are, he looked around. If he would have come up the ramp, he would have had a field day with all the people lying on the ground, like me."
Mr. Garry said he and several others crawled to a nearby elevator and went to the ground floor. Once there, he saw police officers for the first time, and told them to go to the second floor.
Joseph James, 32, who said he had just gotten off a flight in Terminal 3 and was leaving the building when he heard several shots behind him, said, "Several people were yelling, ‘Bomb! Bomb!' and that's what terrified me the most."
Leon Saryan, a traveler from Milwaukee, told the Milwaukee radio station WTMJ: "I was in the hallway cowering when the guy came through. And he had a rifle in his hand and he looked at me and he said ‘T.S.A.?' And I shook my head and he just kept going."
Many passengers dropped their bags as they rushed away from the terminal, leaving police officers with hundreds, if not thousands, of bags that they needed to screen.
At a news conference on Friday evening, Mayor Eric Garcetti of Los Angeles said
The gunman had 100 rounds that could have killed everyone in the terminal
A spokeswoman at Ronald Reagan U.C.L.A. Medical Center said that the hospital had admitted three male patients, two with gunshot wounds. One of the men who had been shot was in critical condition and the two others were in fair condition.
The T.S.A. identified the slain agent as Gerardo I. Hernandez, 39. Officials said he was working as a behavior detection officer, responsible for spotting suspicious activity.
Airport officials said 746 flights were affected by the shutdown and 46 flights were diverted to other airports. They said the backups would not be resolved quickly and advised passengers using Terminal 3 to check with their airlines on Saturday to see if operations had resumed.
The shooting was bound to raise new questions about security procedures at the nation's airports.