Some agents said the facility in Clint was so filthy that a stench would seep into their clothing and follow them home after they left work, causing friends and family to scrunch their noses when the agents approached. According to lawyers who visited the station and interviewed children who were being held there, some children as young as 7 were caring for infants they had only just met. The children were being overseen by armed guards, the lawyers said, but many of the children were sick, and adult caretakers who could provide treatment were nowhere to be found.

NBC News, which first reported the news about the sector chief’s transfer, obtained a draft report prepared in May by the D.H.S. Office of Inspector General detailing “dangerous overcrowding” at two other facilities overseen by Mr. Hull in the El Paso sector — the El Paso Border Patrol Station 1 and the Paso Del Norte Border Patrol Station.

Investigators found hundreds of adult migrants in the facilities crammed into small cells that were meant to hold only a few dozen. Some of the migrants had gone without sleep because they were left in places where there was standing room only.

Sanitation was also a problem. “With limited access to showers and clean clothing, detainees were wearing soiled clothing for days or weeks,” the report said. There was a “high incidence of illness among staff,” and guards were armed and wore masks because of “concerns with the overcrowding that potentially could result in volatile situations,” such as riots.

The situation was “not sustainable,” the report warned.

In a media tour of the Clint Border Patrol facility in June, Mr. Hull said his agents were doing the best they could with the overwhelming numbers of migrants arriving over the spring, despite being understaffed and underfunded. He said the new arrivals were being processed out of border facilities as quickly as possible.

“When we catch more aliens than we can turn over, they tend to build up here in the station,” he said.

Though the agency did not refer to it as such, Mr. Hull’s move to Detroit was widely viewed as a demotion. It takes him from the El Paso sector, one of the agency’s highest-profile assignments — in part because it is the birthplace of the Border Patrol — to the northern border with Canada, where the pace of activity is much slower.