Two passengers aboard an Aeromexico plane that sat on the tarmac at Oakland International Airport for four hours were arrested Thursday after desperately trying to find a way off, authorities said.

The international flight from Guadalajara, Mexico, was originally destined for San Francisco, but was diverted to Oakland due to fog, the Alameda County Sheriff's Office said. As upset passengers waited hours without food, water or air conditioning to deplane, an “unruly” man threatened to open the aircraft doors to escape, the East BaysiteTimes reported.

FIVE AMERICAN AIRLINES STAFFERS HOSPITALIZED AFTER NOTICING 'ODOR' ON PLANE

“Babies were crying, people were passing out,” passenger Arnie Zavala told the paper.

CLICK HERE TO GET THE FOX NEWS APP

A second “upset” male passenger was arrested after police boarded the plane, and both men were taken into federal custody, the San Francisco Chronicle reported. The men were later released after speaking with authorities.

Police said at least one passenger on the plane had difficulty breathing and was treated after requesting medical assistance. Other passengers placed calls for help to 911, passenger rights activists and the local media, the East Bay Times reported.

The airline could have allowed the passengers off, but for some reason decided not to, police told the Chronicle.

ALASKA AIRLINES PASSENGERS ENDURE 30-HOUR ORDEAL TO GET FROM BOSTON TO LA

Aeromexico released a statement saying it didn’t have operations set up at the Oakland airport and had to request special authorization from authorities to disembark passengers.

When passengers were finally allowed to leave the plane, they were given the options of either flying out of Oakland to San Francisco or taking alternative transportation provided by Aeromexico — but some still expressed dissatisfaction.

When the East Bay Times asked passenger Ivan Garcia if he’d fly Aeromexico again, his reply was simple: “Hell no!”