Three jailers were involved in the incident that happened about April 9, said Southwest Virginia Regional Jail Superintendent Lee Noble.
Noble said Duffield Jail Administrator George Hembree dismissed the jailers after learning about the incident.
The jailers restrained the inmates and put hair gel and grape jelly on the inmates' backsides, Noble said.
"That was enough to terminate the officers for clear violations of policies," Noble said.
Noble said Hembree's investigation was "very quick, very thorough and he acted on it immediately."
Noble said the situation did not call for the jail administration to press charges against the former employees. "But it is fully within their rights for the inmates' families to do so," he said.
The jailers had not been served with papers as of Tuesday.