South Africa has deployed troops to help the country’s embattled police force as unrest and violence spread after last week’s jailing of Jacob Zuma, the former president, for contempt of court.

At least six people have been killed and hundreds arrested in recent days. Police struggled to contain rising violence in cities including Durban and Johannesburg on Monday after a weekend of looting and riots. Protesters have blocked main roads and trucks have been burnt.

The deployment will “provide safety and a safe working environment for members of the [police] and other law enforcement agencies whilst they carry out their constitutionally mandated law and order duties”, South Africa’s defence forces said in a statement on Monday. Troops were used to enforce the first coronavirus lockdown but it is rare for them to be deployed in response to unrest. It is not clear how many troops will be sent to the hardest-hit provinces of Gauteng, the nation’s economic hub, and KwaZulu-Natal, where Zuma began his sentence on Thursday.

Zuma was sentenced to 15 months in prison after defying an inquiry into corruption during his nine-year rule. Zuma’s lawyers made a last-ditch attempt on Monday to persuade the constitutional court to rescind its sentence on the grounds that the 79-year-old is too weak to survive prison. Legal experts say that the attempt is unlikely to succeed.

President Cyril Ramaphosa, who succeeded Zuma in 2018 and has sought to battle endemic corruption, on Sunday condemned the “sporadic but increasingly violent protests”. Ramaphosa promised that “we will not tolerate acts of criminality” but rioting continued overnight.

“While there are those who may be hurt and angry at this moment, there can never be any justification for such violent, destructive and disruptive actions,” Ramaphosa said on Sunday.

Zuma was imprisoned on the orders of South Africa’s constitutional court, which last month found him guilty of defiance over his refusal to answer to claims of systematic corruption during his presidency. The sentence was hailed as a victory for the rule of law in Africa’s most industrial nation, after Zuma repeatedly attacked courts and predicted a popular uprising against judges. Zuma denies all wrongdoing.

The violence and anger of his supporters has exposed tensions in the ruling African National Congress, with many looters invoking Zuma’s name in footage online. “It is a matter of concern to all South Africans that some of these acts of violence are based on ethnic mobilisation,” Ramaphosa added, a veiled reference to attempts to stir up Zulu nationalist anger over the jailing of Zuma.

South Africa’s national joint operational and intelligence structure, a body coordinating law enforcement agencies, said on Sunday that hundreds of people had barricaded a major road and attacked police in Johannesburg in “opportunistic criminality emanating from violent protests”. Gunshots rang out and courts were forced to close on Monday in Durban, KwaZulu-Natal’s biggest city, while a shopping mall was set on fire in Pietermaritzburg, the provincial capital.

Zuma’s foundation last week described the unrest as the “reactive righteous anger of the people . . . which others have characterised as violence”. The disturbances were responding to the “violent provocation” of Zuma’s jail sentence, it added.

KwaZulu-Natal, Zuma’s power base, has a long history of political violence, including killings and truck burnings. South Africa’s high levels of inequality and poverty also mean protests can lead to looting, say analysts.

South Africa’s main opposition party, the Democratic Alliance, said that Ramaphosa “should have acknowledged the ANC’s role in this crisis, as this is essentially their internal war being waged on our streets”.