Hundreds of inmates — some armed with baseball bats and iron pipes — rioted at an Oklahoma federal prison for about eight hours, taking two guards hostage and refusing to return to their cells before they were finally corralled by law enforcement officers, authorities said Monday.

The riot started late Sunday at the Great Plains Correctional Facility in Hinton after a fight broke out in the prison yard, and rapidly escalated from there, said Caddo County Sheriff Lennis Miller. Miller said the inmates refused to return to their cells and at one point occupied one building in the complex located about 55 miles (90 kilometers) west of Oklahoma City.

"It was a full-fledged riot," Miller said.

Oklahoma Prison Riot 1

A GEO corrections vehicle drives past the front gate of the Great Plains Correctional Facility in Hinton, Okla, Monday, July 10, 2017. (AP Photo/Sue Ogrocki)

Miller said about 150 inmates were involved, but The GEO Group Inc., the Florida-based operator of the private prison, estimated Monday that about 400 inmates caused the disturbance in two recreation yards. Miller said prisoners, some toting bats and pipes, took two guards hostage at the outset of the riot, but that both were freed and uninjured. It wasn't immediately clear how the inmates got the weapons, how they were able to get inside one of the buildings or what prompted the riot.

Miller said authorities used pepper spray and stun grenades to corral inmates into a soccer field and an exercise yard. The riot ended early Monday after roughly eight hours, authorities said.

Pablo Paez, a spokesman for The GEO Group, said in a statement Monday that the prison was secured without serious injury to staff, inmates or law officers. He said the Federal Bureau of Prisons and other agencies are reviewing the incident. The prison houses about 1,900 inmates.

Oklahoma Prison Riot 2

Chairs and debris in the prison yard are pictured through layers of wire at the Great Plains Correctional Facility in Hinton, Okla, Monday, July 10, 2017. (AP Photo/Sue Ogrocki)

Miller says no officers were hurt, but that some inmates were taken to hospitals with unspecified injuries.

Oklahoma's prison directors have been warning for years about potential problems inside the state's overcrowded and underfunded correctional facilities, many of which are old state schools or hospitals that have been converted into prisons. Inside most facilities, recreation rooms, classrooms and other program space have all been converted into makeshift housing units to accompany more inmates.

In a presentation to the prison system's governing board last month, Director Joe Allbaugh said state prisons have a rated operating capacity of 17,902 but were currently housing more than 26,000 inmates.

Oklahoma Prison Riot 4

A GEO corrections vehicle patrols outside of the Great Plains Correctional Facility in Hinton, Okla, Monday, July 10, 2017. (AP Photo/Sue Ogrocki)

"You can only push this balloon so far," Allbaugh warned the panel during the presentation. "Something is going to pop."

In September 2015, four inmates were stabbed to death at a private prison in Cushing in a fight between rival prison gangs that left three other inmates wounded.

Last year, a knife fight among inmates at a crowded housing unit at the Mack Alford Correctional Center in southeast Oklahoma left one inmate dead and three others wounded.

A correctional officer suffered minor injuries in December after a fight broke out among a small group of inmates at the North Fork Correctional Facility in western Oklahoma. A riot at the same facility in 2011 resulted in 46 inmates being sent to the infirmary or hospitals after fighting erupted among black and Hispanic inmates.