A number of prison staff were also injured during the melee at California State Prison-Sacramento in Folsom, also known as Folsom State Prison. The prison was locked down as a result.
The large riot happened just beyond a security checkpoint. It broke out around 12:30 p.m. in the exercise yard of the Level 4 maximum security area. That's where the serious inmates are: murderers and gang members, many of them incarcerated for life.
While investigators will have to look back on the security footage, they believe about 50 inmates were involved. There are 2,800 inmates at the prison.
Some inmates here were transferred to this facility because the other prisons said they were too difficult to manage, so there was an indication of behavioral problems to begin with.
Correctional officers had to use pepper spray, rubber bullets and seven rounds of real bullets from their Mini 14 semi-automatic rifles to quell the situation.
They only use lethal rounds when someone's life is at risk.
Once things were under control and under lockdown, the guards had prisoners sit in the yard so they could search for weapons by patting them down.
At least nine inmates were taken to area hospitals, some of them with stab wounds from inmate-on-inmate fights. According to a prison official, four inmates were released from the hospital and sent back to the prison.
It was important that officers find the weapons used in Wednesday's riot to prevent further attacks.
Five weapons were found, not considered a lot by prison officials. They believe the riot was not planned.
"In a maximum security, inmates commonly make inmate-manufactured weapons, as we call them," said Folsom State Prison Sgt. Tony Quinn. "It takes a matter of minutes to make a weapon. You can take a common toothbrush, heat the toothbrush up until the plastic is softened, slide a razorblade in there and you have a weapon in a second."
A few prison guards suffered minor injuries.
Back in May, there was a riot at the prison. It was unclear whether that one is related to Wednesday's.
Investigators are still looking into what cause Wednesday's outburst. They say there's always tension here. Among the reasons, it could be due to debt or gang rivalry.
The inmates involved could face charges from participation in a riot to attempted murder.
That security video will help officials sort it out.