Somalia's defence minister, who is leading the fight against Islamist insurgents, has resigned from the embattled transitional government.
Yusuf Mohammed Siad, a close ally of Islamist President Sheikh Sharif Sheikh Ahmed, said he was leaving as the government had failed to restore order.
Two other ministers tendered their resignation letters from London and another from neighbouring Kenya.
Much of southern Somalia is under the control of al-Qaeda inspired militants.
The country has not had a unified functioning government since 1991.
BBC Somali Service analyst Mohamed Mohamed says it is a major blow to President Ahmed, a moderate Islamist who came to power 18 months ago heading a UN-backed unity government.
Like the president, Mr Siad was a leader of the Union of Islamic Courts, which controlled most of southern Somalia for six months in 2006, and was spearheading the fight about the militants, he says.
"Everyone has to evaluate himself before others judge his failure, and that is what I did before resigning," Mr Siad told Reuters news agency after he announced his resignation in Mogadishu.
"I realised that my government cannot do its job."
The other ministers who resigned are:
- Mohamed Abdullahi Omaar - responsible for higher education
- Hassan Moalim - state minister for the presidency
- Abdirahman Abdishakur Warsame - minister of international co-operation.
The government rules only a few strategic square kilometres of the capital - with the help of a 5,000-strong African Union peacekeeping force.
Correspondents says the president has become increasingly unpopular, amid charges his government has been corrupt and ineffective.
Meanwhile, his introduction of Sharia law to the Muslim country has not appeased the Islamist militias fighting the government.
Hundreds of thousands of people have fled their homes in two decades of conflict that has created one of the world's worst humanitarian emergencies.