MOGADISHU - Somalia's president nominated on Wednesday Hamza Abdi Barre, a former chairman of the Jubbaland state election commission, as prime minister.

"I ask the parliament to approve him as soon as possible. I ask the prime minister to fulfill the work before him like tackling insecurity, drought, climate change and good relations with all countries," President Hassan Sheikh Mohamud said on state television.

Last month Mohamud won the presidency for the second time, having previously served from 2012 to 2017, after a long-delayed election that took place against a backdrop of the worst drought in 40 years and a bloody Islamist insurgency.

"I thank God for making Somalia hold a fair election after a period of such uncertainty," said Barre, a lawmaker elected in December last year for the city of Kismayo, where he co-founded a university.

"I assure you I will work day and night, and I will put together the best cabinet," Barre said.

Barre's nomination comes after a bitter rift between former President Mohamed Abdullahi Mohamed, who attempted to extend his presidency, and former Prime Minister Mohamed Hussein Roble, with security forces splintering into factions supporting either of the men.

The rivalry triggered gunbattles between different security organs and distracted them from the fight against al Qaeda-linked al Shabaab militants, who control large swathes of the country and have killed tens of thousands of people in bombings.

The political crisis also diverted attention from a growing humanitarian emergency forcing more than six million Somalis to depend on food aid.

"I congratulate the new Prime Minister Hamza Abdi Barre and wish him success," Roble said in a comment shared on the state radio's Twitter account.

(Reporting by Abdi Sheikh; Writing by Hereward Holland; Editing by Estelle Shirbon and Toby Chopra)