Three inmates were killed during a riot at a Mexico prison, which broke out following a mass escape of prisoners from the facility through a 40-meter-long tunnel, which they dug five meters underground.

Twenty-nine inmates escaped Ciudad Victoria Sanctions Execution Center in Tamaulipas, Thursday, by tunnelling beneath the prison wall. The incident was confirmed by the Security Ministry of Tamaulipas, which warned people to avoid the area of the prison, and suspended visits to the facility.

La fuga de reos en Cedes Victoria fue a través de túnel de 5 metros de profundidad por 40 de largo. Sigue búsqueda externa — VoceriaSeguridadTam (@VoceriaSegTAM) March 23, 2017

A motorist was reportedly killed in an apparent carjacking as part of the escape. Thirteen of the prisoners have since been recaptured, while 16 remain at large, according to authorities.

Fue capturado en Ciudad Victoria otro reo fugado con apoyo de Fuerzas Armadas federales, gracias a la coordinación. Faltan 16. — VoceriaSeguridadTam (@VoceriaSegTAM) March 25, 2017

READ MORE: 60 dead, hundreds escape in Brazil prison riot

The overcrowded prison dates back to the 1940s, and has been dominated for years by the fragmented Zetas cartel, AP reports.

Tamaulipas state security spokesman Luis Alberto Rodriguez said that the tunnel opening was hidden in a hut constructed by prisoners. That hut has since been destroyed by prison authorities, along with a number of other similar structures, Milenio reports.

During the clampdown, a riot broke out at the prison Friday night. Three prisoners were stabbed to death in the incident.

3 muertos y 1 lesionado grave por riña entre reos. Penal bajo medidas d control.Situación es resultado d acciones para restablecer orden — VoceriaSeguridadTam (@VoceriaSegTAM) March 25, 2017

Prisoners also burned fabric, wood, and cardboard, Noticieros Televisa reported. The fire was reportedly brought under control within an hour.

Identifican a los tres reos que perdieron la vida tras riña en penal de Ciudad Victoria https://t.co/vZZrnWkBRnpic.twitter.com/go3xlUMLWA — 24 HORAS (@diario24horas) March 26, 2017

Reportan un incendio en el penal de Ciudad Victoria, Tamaulipas, de donde se fugaron 29 reos esta semana. pic.twitter.com/IgOMKsQnnJ — AnimalPolitico.com (@Pajaropolitico) March 25, 2017

Saldo: 3 muertos y 10 heridos en tercer día d violencia en el CEDES d @cd_victoria #CiudadVictoria#Tamaulipas #México 1 grave y encarcelado pic.twitter.com/6v5ng3wJYL — Freelance para AP (@FrepeMtz) March 25, 2017

#Video 📹 Así se ve el fuego que internos prendieron al interior del penal de Ciudad Victoria, Tamaulipas https://t.co/NEIbCzXgPDpic.twitter.com/yvtQFSa32h — El Universal (@El_Universal_Mx) March 25, 2017

The tunnel has now been sealed with concrete and family visits to the prison have resumed.

Se lleva a cabo el sellado del túnel pic.twitter.com/zV7H36f0Hf — VoceriaSeguridadTam (@VoceriaSegTAM) March 25, 2017

Rodriguez said about 30 guards at the facility are under investigation, and appealed to neighboring states for assistance in capturing the remaining escapees.

READ MORE: Mexico captures fugitive drug lord ‘El Chapo’ Guzman – president