RIO DE JANEIRO — Six cabinet members are out. The military’s top leaders are also gone. And it’s only Tuesday.

First came the Monday morning exit of Brazil’s foreign minister, a right-wing ideologue blamed for failing to secure enough coronavirus vaccines. Then the defense minister was gone. Then the justice minister was replaced. Tuesday morning brought still more tumult: the departures of the navy, army and air force chiefs.

The exits have sent political shock waves across Latin America’s largest country, precipitating the most politically uncertain moment of President Jair Bolsonaro’s two-year-plus tenure. Brazil must now face what public health analysts say could be the darkest weeks of the pandemic with a raft of new officials and an incoherent national strategy.

The sudden moves — some expected, others not — suggested mounting political desperation in the presidential palace. Health systems have collapsed. Some 2,600 people are dying of the coronavirus every day. And Brazilians are increasingly looking to blame the failures of the pandemic on Bolsonaro, who has never appeared more vulnerable. Earlier this month, the leader of the congress implied the president may face impeachment.

“These are defensive actions,” said Ricardo Ismael, a political scientist at the Catholic Pontifical University in Rio de Janeiro. “There is a fragility to him.”

That impression has only deepened since the political revival of Bolsonaro’s greatest political rival, former president Luiz Inácio Lula da Silva, out of prison and now cleared by the supreme court to run in the 2022 presidential election. If Bolsonaro is to have any shot at maintaining power, quieting calls for impeachment and eventually winning reelection, he has to start making changes, analysts said.

“He’s feeling the heat,” said Matias Spektor, an associate professor of international relations at Fundação Getúlio Vargas in São Paulo. “He knows things will get worse in the next months, and he needs to prepare for that and get ready for the next election.”

Bolsonaro has somewhat moderated his messaging on the virus, which he earlier dismissed as little more than an annoyance Brazilians had to work around. Long a mask skeptic, he began wearing one. He also embraced vaccines, which he previously fretted could turn people into alligators. He dismissed his health minister, a military general, and replaced him with a cardiologist. And finally, he booted the foreign minister, the right-wing hard-liner castigated by the powerful center bloc of congress for not wrangling enough vaccines from foreign powers.

Those moves were expected. Then came ones that weren’t.

Bolsonaro replaced the justice minister with a close family ally. Then he sacked the defense minister, Fernando Azevedo e Silva, who had taken the virus more seriously and had reportedly chafed under the president’s leadership. Bolsonaro, a former army captain, has repeatedly said the military was on his side in political disputes. Earlier this month, he called it “my military.”

Azevedo e Silva disagreed — and was gone by the end of Monday.

“During this time, I preserved the Armed Forces as institutions of state,” Azevedo e Silva wrote in his departure statement. “I leave in the certainty of a mission accomplished.”

On Tuesday morning, the three top commanders of the armed forces — who had joined Azevedo e Silva in a November statement reinforcing the separation of military and politics — also announced they were leaving. It’s unclear whether they resigned or were forced out.

In a country that spent decades under a military dictatorship — and is now led by a president who has frequently lamented its collapse — the departure of the top military officials has caused widespread consternation and fanned fears about Bolsonaro’s authoritarian impulses.

“He has the idea that, as soon as he was elected, he is the state,” said Carlos Melo, a professor at São Paulo University’s Insper education and research school. “That the institutions are subordinate to him and not to the state.”

Politicians and former allies across the country echoed the concerns about the strength of Brazilian democracy.

“Bolsonaro is increasingly similar to Chávez and Maduro,” said Rodrigo Maia, a former congressional president, referring to past and current Venezuelan presidents. “An authoritarian will always be an authoritarian.”

McCoy reported from Madison, Wis.