A dozen passengers were in the carriage when the shooting began, with 137 passengers and 11 crew were evacuated from the train.
A routine sweep for drugs and weapons on an Amtrak train ended with two dead and two injured after passengers opened fire on federal agents from the Drug Enforcement Administration (DEA).
The gunfight broke out after agents from the DEA and Tucson Police Department boarded the train in Arizona, authorities said. One DEA agent and the suspected shooter were killed, while another DEA agent and a Tucson police officer were injured.
Tucson Police Chief Chris Magnus said officers from the regional task force were in the middle of detaining a man on the upper level of the double-decker train when a second man pulled a handgun and began firing.
After exchanging several rounds of fire with police, the gunman barricaded himself in a bathroom on the lower level where he was later found dead. The other passenger was arrested, but it was unclear if he had any connections to the dead shooter.
The second DEA agent was in critical condition while the Tucson police officer, who ran toward the train from the platform after the shots began, remained stable.
Dramatic video footage from the assault was captured on live webcams surrounding the train station. In one, a law enforcement officer with a canine unit can be seen running towards the carriage. He can then be seen running from gunfire appearing to come from within the train.
Another video shows at least a dozen shots being fired as two officers on the platform crouch behind a box for cover.
Passengers and staff fled the Sunset Limited Train 2 after the gunfire broke out about 8 am local time on Monday. The train had stopped in Tucson at about 7.40 am on its journey from New Orleans to Los Angeles. Evan Courtney was in a lounge car when people suddenly came running in yelling: “Shots fired!”
“I grabbed my backpack and ran,” Mr Courtney said via Twitter direct messaging.
He huddled with other passengers while several tactical police officers with assault rifles behind barricades. After 15 minutes, “police ran to us and told us to get out of the car and run in the opposite direction.”
Mr Magnus said there were about a dozen passengers in the car at the time of the shooting, while an Amtrak spokesman said a total of 137 passengers and 11 crew were on the train.
“It’s very horrific and we’re all just coming to terms with just how terrible a loss this is,” Mr Magnus said. “But I also want to reflect on the really heroic actions of the officers at the scene. They literally ran towards the danger, into the car, where there was an active shooting situation going on.”
The Associated Press contributed to this report.