MIAMI — Guards clashed Saturday with prisoners at the Guantanamo Bay prison as the military sought to move hunger strikers out of a communal section of the detention center on the US base in Cuba, officials said.

The confrontation occurred after the commander decided to move prisoners into single, solid-walled cells so that prison authorities could monitor them more closely during a hunger strike, the military said in a statement.

The statement from the Miami-based US Southern Command, which oversees the prison on the base in Cuba, said prisoners fought back with improvised weapons and guards fired four “less-than-lethal rounds,” to quell the disturbance. The military said there were no major injuries.

Lawyers for detainees denounced the action, saying the prison commander should have sought to negotiate an end to the hunger strike, which the men began in February to protest their indefinite confinement and what they said were intrusive searches of their Qurans.

“This is exactly the opposite of what they should be doing,” said Carlos Warner, a federal public defender in Ohio. “Instead, the military is escalating the conflict.”

The military has said it used Muslim translators to search the Qurans for contraband and would not allow them to be surrendered, which officials had said would amount to conceding that they had been improperly treated in the first place.

The prison at the U.S. base in Cuba holds 166 detainees. The military said that as of Friday, 43 were on hunger strike to protest their confinement. Lawyers for the men say the figure is higher and involves a majority of the men held there.