The Mexican man and the others in his group then hiked through the South Texas brush until the next day, when they were picked up by a vehicle and driven to the trailer. Another immigrant described waiting in a stash house in Laredo for 11 days with 23 other people before being loaded into the trailer.

A third survivor, who was identified in the complaint by the initials H.L.-C. and was headed to Minnesota, told investigators that he and his brother crossed through in Laredo. “He stated he thought there were approximately 180 to 200 people in the tractor-trailer when he got in,” the complaint said.

By the time the police came to the truck Sunday morning, alerted by a Walmart employee, a number of immigrants had already fled, either in vehicles that picked them up before the police arrived or on foot.

The bodies of the 10 dead, all adult men, have been taken to the Bexar County Medical Examiner’s Office, which is working with other agencies to determine their identities, a spokeswoman said. Officials with the Mexican Consulate are also assisting. The men’s bodies will be returned to their families once their identities are established, a process involving fingerprint and DNA checks and other forensic tools that could take considerable time.

One man was a Guatemalan who had previously lived in the United States as a so-called Dreamer, one of the young immigrants protected from deportation by an Obama administration policy. But he had lost his protection because of a conviction for larceny and aggravated assault, said Silvia Mintz, a lawyer working for the Guatemalan Consulate in Houston.

How the survivors’ immigration status will be handled in the coming weeks remained unclear. All were in custody of Immigration and Customs Enforcement. Immigration lawyers said they should be regarded as crime victims, and as witnesses to a crime, which in some cases can protect them from deportation.

“We are exploring every avenue, and hopefully we can get them some immigration relief,” Ms. Mintz said.