Updated

Uganda's government says its troops have started withdrawing from South Sudan to comply with a peace deal between South Sudan's warring factions.

Ugandan military chief Gen. Katumba Wamala told reporters Monday that he believes all Ugandan forces, estimated at between 2,000 to 3,000, will have withdrawn from South Sudan by the first week of November.

He said Ugandan troops, deployed at the request of South Sudanese President Salva Kiir, prevented the rebels from taking South Sudan's capital, Juba, in December 2013. He said there was a risk of genocide when the Ugandans deployed.

South Sudan erupted into violence in mid-December 2013 when some security forces in Juba appeared to splinter along ethnic lines.

Kiir belongs to the Dinka ethnic group while rebel leader Riek Machar is an ethnic Nuer.